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

Unified Diff: third_party/WebKit/Source/devtools/front_end/persistence/FileSystemWorkspaceBinding.js

Issue 2889013002: DevTools: introduce uiSourceCode.mimeType() method (Closed)
Patch Set: address comments Created 3 years, 7 months 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
Index: third_party/WebKit/Source/devtools/front_end/persistence/FileSystemWorkspaceBinding.js
diff --git a/third_party/WebKit/Source/devtools/front_end/persistence/FileSystemWorkspaceBinding.js b/third_party/WebKit/Source/devtools/front_end/persistence/FileSystemWorkspaceBinding.js
index 08a881e539a6fb65a90391ee96cd8144cb48e4d4..90c9904a5083de4f78378c5877000349367abf7c 100644
--- a/third_party/WebKit/Source/devtools/front_end/persistence/FileSystemWorkspaceBinding.js
+++ b/third_party/WebKit/Source/devtools/front_end/persistence/FileSystemWorkspaceBinding.js
@@ -237,6 +237,15 @@ Persistence.FileSystemWorkspaceBinding.FileSystem = class extends Workspace.Proj
}
/**
+ * @override
+ * @param {!Workspace.UISourceCode} uiSourceCode
+ * @return {string}
+ */
+ mimeType(uiSourceCode) {
+ return Common.ResourceType.mimeFromURL(uiSourceCode.url()) || 'text/plain';
+ }
+
+ /**
* @return {!Array<string>}
*/
initialGitFolders() {

Powered by Google App Engine
This is Rietveld 408576698