[SCM] WebKit Debian packaging branch, webkit-1.1, updated. upstream/1.1.15.1-1414-gc69ee75

pfeldman at chromium.org pfeldman at chromium.org
Thu Oct 29 20:34:48 UTC 2009


The following commit has been merged in the webkit-1.1 branch:
commit 89f7ae77ada4e3593f94901ca068fb9f4ab74785
Author: pfeldman at chromium.org <pfeldman at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Sun Sep 27 07:08:10 2009 +0000

    2009-09-26  Pavel Feldman  <pfeldman at chromium.org>
    
            Reviewed by Timothy Hatcher.
    
            Web Inspector: [REGRESSION] Double Clicking Resources Fails to Open in New Window
    
            https://bugs.webkit.org/show_bug.cgi?id=29762
    
            * inspector/front-end/InjectedScript.js:
            (InjectedScript.setStyleText):
            (InjectedScript.openInInspectedWindow):
            * inspector/front-end/InjectedScriptAccess.js:
            * inspector/front-end/ResourcesPanel.js:
            (WebInspector.ResourceSidebarTreeElement.prototype.ondblclick):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@48797 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 5af0a34..b75d5de 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,18 @@
+2009-09-26  Pavel Feldman  <pfeldman at chromium.org>
+
+        Reviewed by Timothy Hatcher.
+
+        Web Inspector: [REGRESSION] Double Clicking Resources Fails to Open in New Window
+
+        https://bugs.webkit.org/show_bug.cgi?id=29762
+
+        * inspector/front-end/InjectedScript.js:
+        (InjectedScript.setStyleText):
+        (InjectedScript.openInInspectedWindow):
+        * inspector/front-end/InjectedScriptAccess.js:
+        * inspector/front-end/ResourcesPanel.js:
+        (WebInspector.ResourceSidebarTreeElement.prototype.ondblclick):
+
 2009-09-26  David Kilzer  <ddkilzer at apple.com>
 
         Part 2 of 2: <http://webkit.org/b/29753> DerivedSources.make broken for non-Mac targets
diff --git a/WebCore/inspector/front-end/InjectedScript.js b/WebCore/inspector/front-end/InjectedScript.js
index 0603b33..87293b8 100644
--- a/WebCore/inspector/front-end/InjectedScript.js
+++ b/WebCore/inspector/front-end/InjectedScript.js
@@ -44,6 +44,10 @@ InjectedScript.reset();
 InjectedScript.dispatch = function(methodName, args)
 {
     var result = InjectedScript[methodName].apply(InjectedScript, JSON.parse(args));
+    if (typeof result === "undefined") {
+        InjectedScript._window().console.error("Web Inspector error: InjectedScript.%s returns undefined", methodName);
+        result = null;
+    }
     return JSON.stringify(result);
 }
 
@@ -150,6 +154,7 @@ InjectedScript.applyStyleText = function(styleId, styleText, propertyName)
 InjectedScript.setStyleText = function(style, cssText)
 {
     style.cssText = cssText;
+    return true;
 }
 
 InjectedScript.toggleStyleEnabled = function(styleId, propertyName, disabled)
@@ -812,7 +817,10 @@ InjectedScript.searchCanceled = function()
 
 InjectedScript.openInInspectedWindow = function(url)
 {
-    InjectedScript._window().open(url);
+    // Don't call window.open on wrapper - popup blocker mutes it.
+    // URIs should have no double quotes.
+    InjectedScript._window().eval("window.open(\"" + url + "\")");
+    return true;
 }
 
 InjectedScript.getCallFrames = function()
diff --git a/WebCore/inspector/front-end/InjectedScriptAccess.js b/WebCore/inspector/front-end/InjectedScriptAccess.js
index da85d03..67312f7 100644
--- a/WebCore/inspector/front-end/InjectedScriptAccess.js
+++ b/WebCore/inspector/front-end/InjectedScriptAccess.js
@@ -51,6 +51,9 @@ InjectedScriptAccess._installHandler = function(methodName)
     };
 }
 
+// InjectedScriptAccess message forwarding puts some constraints on the way methods are imlpemented and called:
+// - Make sure corresponding methods in InjectedScript return non-null and non-undefined values,
+// - Make sure last parameter of all the InjectedSriptAccess.* calls is a callback function.
 InjectedScriptAccess._installHandler("getStyles");
 InjectedScriptAccess._installHandler("getComputedStyle");
 InjectedScriptAccess._installHandler("getInlineStyle");
diff --git a/WebCore/inspector/front-end/ResourcesPanel.js b/WebCore/inspector/front-end/ResourcesPanel.js
index 680f66c..2c96974 100644
--- a/WebCore/inspector/front-end/ResourcesPanel.js
+++ b/WebCore/inspector/front-end/ResourcesPanel.js
@@ -1209,7 +1209,7 @@ WebInspector.ResourceSidebarTreeElement.prototype = {
     
     ondblclick: function(treeElement, event)
     {
-        InjectedScriptAccess.openInInspectedWindow(this.resource.url);
+        InjectedScriptAccess.openInInspectedWindow(this.resource.url, function() {});
     },
 
     get mainTitle()

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list