OSDN Git Service

Merge WebKit at r73109: Initial merge by git.
[android-x86/external-webkit.git] / WebKit / chromium / src / js / DevTools.js
index f55be4e..5bb150c 100644 (file)
@@ -45,7 +45,10 @@ var context = {};  // Used by WebCore's inspector routines.
     Preferences.profilerAlwaysEnabled = true;
     Preferences.canEditScriptSource = true;
     Preferences.onlineDetectionEnabled = false;
-    Preferences.domBreakpointsEnabled = true;
+    Preferences.nativeInstrumentationEnabled = true;
+    Preferences.fileSystemEnabled = false;
+    Preferences.showTimingTab = true;
+    Preferences.showCookiesTab = true;
 })();
 
 var devtools = devtools || {};
@@ -162,7 +165,25 @@ WebInspector.resetToolbarColors = function()
 
 }
 
-// TODO(yurys): should be removed when eclipse debugger stops using it.
-if (window.RemoteDebuggerAgent) {
-    RemoteDebuggerAgent.setContextId = function() {};
+////////////////////////////////////////////////////////
+// Platform-specific WebInspector extensions support. //
+////////////////////////////////////////////////////////
+
+WebInspector.platformExtensionAPI = function(tabId)
+{
+    function getTabId()
+    {
+        return tabId;
+    }
+    webInspector.inspectedWindow.__proto__.__defineGetter__("tabId", getTabId);
+}
+
+WebInspector.buildPlatformExtensionAPI = function()
+{
+    return "(" + WebInspector.platformExtensionAPI + ")(" + WebInspector._inspectedTabId + ");";
+}
+
+WebInspector.setInspectedTabId = function(tabId)
+{
+    WebInspector._inspectedTabId = tabId;
 }