Changeset 147227 in webkit
- Timestamp:
- Mar 29, 2013 10:24:52 AM (11 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r147226 r147227 1 2013-03-29 Vsevolod Vlasov <vsevik@chromium.org> 2 3 Web Inspector: Content should not be lost when uiSourceCode's file was removed externally on file system. 4 https://bugs.webkit.org/show_bug.cgi?id=113581 5 6 Reviewed by Pavel Feldman. 7 8 * inspector/front-end/IsolatedFileSystem.js: 9 (WebInspector.IsolatedFileSystem.prototype.errorHandler): 10 (WebInspector.IsolatedFileSystem.prototype.requestFileContent): 11 (WebInspector.IsolatedFileSystem.prototype.fileSystemLoaded): 12 * inspector/front-end/UISourceCode.js: 13 (WebInspector.UISourceCode.prototype.checkContentUpdated.contentLoaded): 14 (WebInspector.UISourceCode.prototype.checkContentUpdated): 15 (WebInspector.UISourceCode.prototype._commitContent): 16 1 17 2013-03-29 Vsevolod Vlasov <vsevik@chromium.org> 2 18 -
trunk/Source/WebCore/inspector/front-end/IsolatedFileSystem.js
r145221 r147227 179 179 function errorHandler(error) 180 180 { 181 if (error.code === FileError.NOT_FOUND_ERR) { 182 callback(null); 183 return; 184 } 185 181 186 var errorMessage = WebInspector.IsolatedFileSystem.errorMessage(error); 182 187 console.error(errorMessage + " when getting content for file '" + (this._path + "/" + path) + "'"); … … 199 204 function fileSystemLoaded(domFileSystem) 200 205 { 201 domFileSystem.root.getFile(path, null, fileEntryLoaded, errorHandler);206 domFileSystem.root.getFile(path, { create: true }, fileEntryLoaded, errorHandler); 202 207 } 203 208 -
trunk/Source/WebCore/inspector/front-end/UISourceCode.js
r147226 r147227 226 226 function contentLoaded(updatedContent) 227 227 { 228 if (updatedContent === null) { 229 var workingCopy = this.workingCopy(); 230 this._commitContent("", false); 231 this.setWorkingCopy(workingCopy); 232 delete this._checkingContent; 233 return; 234 } 228 235 if (typeof this._lastAcceptedContent === "string" && this._lastAcceptedContent === updatedContent) { 229 236 delete this._checkingContent; … … 231 238 } 232 239 if (this._content === updatedContent) { 240 delete this._lastAcceptedContent; 233 241 delete this._checkingContent; 234 242 return; … … 264 272 _commitContent: function(content, shouldSetContentInProject) 265 273 { 274 delete this._lastAcceptedContent; 266 275 this._content = content; 267 276 this._contentLoaded = true;
Note: See TracChangeset
for help on using the changeset viewer.