| OLD | NEW |
| 1 var initialize_IsolatedFileSystemTest = function() { | 1 var initialize_IsolatedFileSystemTest = function() { |
| 2 | 2 |
| 3 InspectorFrontendHost.isolatedFileSystem = function(name) | 3 InspectorFrontendHost.isolatedFileSystem = function(name) |
| 4 { | 4 { |
| 5 return InspectorTest.TestFileSystem._instances[name]; | 5 return InspectorTest.TestFileSystem._instances[name]; |
| 6 } | 6 } |
| 7 | 7 |
| 8 InspectorTest.TestFileSystem = function(fileSystemPath) | 8 InspectorTest.TestFileSystem = function(fileSystemPath) |
| 9 { | 9 { |
| 10 this.root = new InspectorTest.TestFileSystem.Entry(this, "", true, null); | 10 this.root = new InspectorTest.TestFileSystem.Entry(this, "", true, null); |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 }, | 36 }, |
| 37 | 37 |
| 38 reportRemoved: function() | 38 reportRemoved: function() |
| 39 { | 39 { |
| 40 delete InspectorTest.TestFileSystem._instances[this.fileSystemPath]; | 40 delete InspectorTest.TestFileSystem._instances[this.fileSystemPath]; |
| 41 InspectorFrontendHost.events.dispatchEventToListeners(InspectorFrontendH
ostAPI.Events.FileSystemRemoved, this.fileSystemPath); | 41 InspectorFrontendHost.events.dispatchEventToListeners(InspectorFrontendH
ostAPI.Events.FileSystemRemoved, this.fileSystemPath); |
| 42 }, | 42 }, |
| 43 | 43 |
| 44 addFileMapping: function(urlPrefix, pathPrefix) | 44 addFileMapping: function(urlPrefix, pathPrefix) |
| 45 { | 45 { |
| 46 var fileSystemMapping = new Workspace.FileSystemMapping(); | 46 var fileSystemMapping = new Workspace.FileSystemMapping(Workspace.isolat
edFileSystemManager); |
| 47 fileSystemMapping.addFileSystem(this.fileSystemPath); | 47 fileSystemMapping.addFileSystem(this.fileSystemPath); |
| 48 fileSystemMapping.addFileMapping(this.fileSystemPath, urlPrefix, pathPre
fix); | 48 fileSystemMapping.addFileMapping(this.fileSystemPath, urlPrefix, pathPre
fix); |
| 49 fileSystemMapping.dispose(); |
| 49 Workspace.fileSystemMapping._loadFromSettings(); | 50 Workspace.fileSystemMapping._loadFromSettings(); |
| 50 }, | 51 }, |
| 51 | 52 |
| 52 /** | 53 /** |
| 53 * @param {string} path | 54 * @param {string} path |
| 54 * @param {string} content | 55 * @param {string} content |
| 55 * @param {number} lastModified | 56 * @param {number} lastModified |
| 56 */ | 57 */ |
| 57 addFile: function(path, content, lastModified) | 58 addFile: function(path, content, lastModified) |
| 58 { | 59 { |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 233 truncate: function(num) | 234 truncate: function(num) |
| 234 { | 235 { |
| 235 this._entry._timestamp += this._modificationTimesDelta; | 236 this._entry._timestamp += this._modificationTimesDelta; |
| 236 this._entry.content = this._entry.content.slice(0, num); | 237 this._entry.content = this._entry.content.slice(0, num); |
| 237 if (this.onwriteend) | 238 if (this.onwriteend) |
| 238 this.onwriteend(); | 239 this.onwriteend(); |
| 239 } | 240 } |
| 240 } | 241 } |
| 241 | 242 |
| 242 }; | 243 }; |
| OLD | NEW |