Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(922)

Unified Diff: third_party/WebKit/Source/devtools/front_end/workspace/Workspace.js

Issue 1422463007: DevTools: use inotify to pick changes on the filesystem. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: build fix Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/devtools/front_end/workspace/IsolatedFileSystemManager.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/devtools/front_end/workspace/Workspace.js
diff --git a/third_party/WebKit/Source/devtools/front_end/workspace/Workspace.js b/third_party/WebKit/Source/devtools/front_end/workspace/Workspace.js
index 9f0b8a9eb1394d3cccad48d5a22027050e83acca..10de8f594376a3ee5ce14d9fedb13f316372e1ff 100644
--- a/third_party/WebKit/Source/devtools/front_end/workspace/Workspace.js
+++ b/third_party/WebKit/Source/devtools/front_end/workspace/Workspace.js
@@ -85,6 +85,7 @@ WebInspector.ProjectDelegate = function() { }
WebInspector.ProjectDelegate.Events = {
FileAdded: "FileAdded",
FileRemoved: "FileRemoved",
+ FileChanged: "FileChanged"
}
WebInspector.ProjectDelegate.prototype = {
@@ -208,6 +209,7 @@ WebInspector.Project = function(workspace, projectId, projectDelegate)
this._displayName = this._projectDelegate.displayName();
projectDelegate.addEventListener(WebInspector.ProjectDelegate.Events.FileAdded, this._fileAdded, this);
projectDelegate.addEventListener(WebInspector.ProjectDelegate.Events.FileRemoved, this._fileRemoved, this);
+ projectDelegate.addEventListener(WebInspector.ProjectDelegate.Events.FileChanged, this._fileChanged, this);
}
/**
@@ -298,6 +300,17 @@ WebInspector.Project.prototype = {
},
/**
+ * @param {!WebInspector.Event} event
+ */
+ _fileChanged: function(event)
+ {
+ var path = /** @type {string} */ (event.data);
+ var uiSourceCode = this.uiSourceCode(path);
+ if (uiSourceCode && uiSourceCode.contentLoaded())
+ uiSourceCode.checkContentUpdated();
+ },
+
+ /**
* @param {string} path
*/
_removeFile: function(path)
« no previous file with comments | « third_party/WebKit/Source/devtools/front_end/workspace/IsolatedFileSystemManager.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698