| 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 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 try { | 128 try { |
| 129 name = decodeURI(name); | 129 name = decodeURI(name); |
| 130 } catch (e) { | 130 } catch (e) { |
| 131 } | 131 } |
| 132 return skipTrim ? name : name.trimEnd(100); | 132 return skipTrim ? name : name.trimEnd(100); |
| 133 } | 133 } |
| 134 | 134 |
| 135 /** | 135 /** |
| 136 * @return {boolean} | 136 * @return {boolean} |
| 137 */ | 137 */ |
| 138 isFromServiceProject() { | |
| 139 return Workspace.Project.isServiceProject(this._project); | |
| 140 } | |
| 141 | |
| 142 /** | |
| 143 * @return {boolean} | |
| 144 */ | |
| 145 canRename() { | 138 canRename() { |
| 146 return this._project.canRename(); | 139 return this._project.canRename(); |
| 147 } | 140 } |
| 148 | 141 |
| 149 /** | 142 /** |
| 150 * @param {string} newName | 143 * @param {string} newName |
| 151 * @param {function(boolean)} callback | 144 * @param {function(boolean)} callback |
| 152 */ | 145 */ |
| 153 rename(newName, callback) { | 146 rename(newName, callback) { |
| 154 this._project.rename(this, newName, innerCallback.bind(this)); | 147 this._project.rename(this, newName, innerCallback.bind(this)); |
| (...skipping 791 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 946 Workspace.UISourceCodeMetadata = class { | 939 Workspace.UISourceCodeMetadata = class { |
| 947 /** | 940 /** |
| 948 * @param {?Date} modificationTime | 941 * @param {?Date} modificationTime |
| 949 * @param {?number} contentSize | 942 * @param {?number} contentSize |
| 950 */ | 943 */ |
| 951 constructor(modificationTime, contentSize) { | 944 constructor(modificationTime, contentSize) { |
| 952 this.modificationTime = modificationTime; | 945 this.modificationTime = modificationTime; |
| 953 this.contentSize = contentSize; | 946 this.contentSize = contentSize; |
| 954 } | 947 } |
| 955 }; | 948 }; |
| OLD | NEW |