OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 649 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
660 * @param {number} lineNumber | 660 * @param {number} lineNumber |
661 * @param {number} columnNumber | 661 * @param {number} columnNumber |
662 */ | 662 */ |
663 constructor(uiSourceCode, lineNumber, columnNumber) { | 663 constructor(uiSourceCode, lineNumber, columnNumber) { |
664 this.uiSourceCode = uiSourceCode; | 664 this.uiSourceCode = uiSourceCode; |
665 this.lineNumber = lineNumber; | 665 this.lineNumber = lineNumber; |
666 this.columnNumber = columnNumber; | 666 this.columnNumber = columnNumber; |
667 } | 667 } |
668 | 668 |
669 /** | 669 /** |
| 670 * @param {boolean=} skipTrim |
670 * @return {string} | 671 * @return {string} |
671 */ | 672 */ |
672 linkText() { | 673 linkText(skipTrim) { |
673 var linkText = this.uiSourceCode.displayName(); | 674 var linkText = this.uiSourceCode.displayName(skipTrim); |
674 if (typeof this.lineNumber === 'number') | 675 if (typeof this.lineNumber === 'number') |
675 linkText += ':' + (this.lineNumber + 1); | 676 linkText += ':' + (this.lineNumber + 1); |
676 return linkText; | 677 return linkText; |
677 } | 678 } |
678 | 679 |
679 /** | 680 /** |
680 * @return {string} | 681 * @return {string} |
681 */ | 682 */ |
682 id() { | 683 id() { |
683 return this.uiSourceCode.project().id() + ':' + this.uiSourceCode.url() + ':
' + this.lineNumber + ':' + | 684 return this.uiSourceCode.project().id() + ':' + this.uiSourceCode.url() + ':
' + this.lineNumber + ':' + |
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
926 Workspace.UISourceCodeMetadata = class { | 927 Workspace.UISourceCodeMetadata = class { |
927 /** | 928 /** |
928 * @param {?Date} modificationTime | 929 * @param {?Date} modificationTime |
929 * @param {?number} contentSize | 930 * @param {?number} contentSize |
930 */ | 931 */ |
931 constructor(modificationTime, contentSize) { | 932 constructor(modificationTime, contentSize) { |
932 this.modificationTime = modificationTime; | 933 this.modificationTime = modificationTime; |
933 this.contentSize = contentSize; | 934 this.contentSize = contentSize; |
934 } | 935 } |
935 }; | 936 }; |
OLD | NEW |