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

aroben at apple.com aroben at apple.com
Thu Oct 29 20:41:49 UTC 2009


The following commit has been merged in the webkit-1.1 branch:
commit 6adc5ded372fac8656992ffd29e99200d14ad074
Author: aroben at apple.com <aroben at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Oct 8 16:11:08 2009 +0000

    Make IWebInspectorPrivate be accessed in a more standard way
    
    Fixes <http://webkit.org/b/30215> Make IWebInspectorPrivate be
    accessed in a more standard way
    
    Reviewed by John Sullivan and Tim Hatcher.
    
    WebKit/win:
    
    IWebViewPrivate::inspectorPrivate has been removed. Callers should
    instead use IWebViewPrivate::inspector and then use QueryInterface to
    get the IWebInspectorPrivate interface. This matches how our other COM
    classes work.
    
    * Interfaces/IWebViewPrivate.idl: Removed inspectorPrivate.
    
    * WebInspector.cpp:
    (WebInspector::QueryInterface): Support querying to
    IWebInspectorPrivate.
    
    * WebView.cpp:
    * WebView.h:
    Removed inspectorPrivate.
    
    WebKitTools:
    
    Use QueryInterface to get IWebInspectorPrivate
    
    * DumpRenderTree/win/LayoutTestControllerWin.cpp:
    (LayoutTestController::evaluateInWebInspector): Get the IWebInspector
    by calling IWebViewPrivate::inspector, then use QueryInterface to get
    to the IWebInspectorPrivate interface.
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@49305 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/win/ChangeLog b/WebKit/win/ChangeLog
index 656f224..354f82f 100644
--- a/WebKit/win/ChangeLog
+++ b/WebKit/win/ChangeLog
@@ -1,5 +1,29 @@
 2009-10-08  Adam Roben  <aroben at apple.com>
 
+        Make IWebInspectorPrivate be accessed in a more standard way
+
+        IWebViewPrivate::inspectorPrivate has been removed. Callers should
+        instead use IWebViewPrivate::inspector and then use QueryInterface to
+        get the IWebInspectorPrivate interface. This matches how our other COM
+        classes work.
+
+        Fixes <http://webkit.org/b/30215> Make IWebInspectorPrivate be
+        accessed in a more standard way
+
+        Reviewed by John Sullivan and Tim Hatcher.
+
+        * Interfaces/IWebViewPrivate.idl: Removed inspectorPrivate.
+
+        * WebInspector.cpp:
+        (WebInspector::QueryInterface): Support querying to
+        IWebInspectorPrivate.
+
+        * WebView.cpp:
+        * WebView.h:
+        Removed inspectorPrivate.
+
+2009-10-08  Adam Roben  <aroben at apple.com>
+
         Move the new IWebViewPrivate::inspectorPrivate function after all
         functions that existed when Safari 4.0.3 was released
 
diff --git a/WebKit/win/Interfaces/IWebViewPrivate.idl b/WebKit/win/Interfaces/IWebViewPrivate.idl
index e0b4f8e..465d804 100644
--- a/WebKit/win/Interfaces/IWebViewPrivate.idl
+++ b/WebKit/win/Interfaces/IWebViewPrivate.idl
@@ -208,6 +208,4 @@ interface IWebViewPrivate : IUnknown
 
     // Removes all white list entries created with whiteListAccessFromOrigin.
     HRESULT resetOriginAccessWhiteLists();
-
-    HRESULT inspectorPrivate([out, retval] IWebInspectorPrivate**);
 }
diff --git a/WebKit/win/WebInspector.cpp b/WebKit/win/WebInspector.cpp
index dcef248..97587f9 100644
--- a/WebKit/win/WebInspector.cpp
+++ b/WebKit/win/WebInspector.cpp
@@ -72,6 +72,8 @@ HRESULT STDMETHODCALLTYPE WebInspector::QueryInterface(REFIID riid, void** ppvOb
     *ppvObject = 0;
     if (IsEqualGUID(riid, IID_IWebInspector))
         *ppvObject = static_cast<IWebInspector*>(this);
+    else if (IsEqualGUID(riid, IID_IWebInspectorPrivate))
+        *ppvObject = static_cast<IWebInspectorPrivate*>(this);
     else if (IsEqualGUID(riid, IID_IUnknown))
         *ppvObject = static_cast<IWebInspector*>(this);
     else
diff --git a/WebKit/win/WebView.cpp b/WebKit/win/WebView.cpp
index 82e63f0..85b2ac2 100644
--- a/WebKit/win/WebView.cpp
+++ b/WebKit/win/WebView.cpp
@@ -5177,14 +5177,6 @@ HRESULT STDMETHODCALLTYPE WebView::inspector(IWebInspector** inspector)
     return m_webInspector.copyRefTo(inspector);
 }
 
-HRESULT STDMETHODCALLTYPE WebView::inspectorPrivate(IWebInspectorPrivate** inspector)
-{
-    if (!m_webInspector)
-        m_webInspector.adoptRef(WebInspector::createInstance(this));
-
-    return m_webInspector.copyRefTo(inspector);
-}
-
 HRESULT STDMETHODCALLTYPE WebView::windowAncestryDidChange()
 {
     HWND newParent = findTopLevelParent(m_hostWindow);
diff --git a/WebKit/win/WebView.h b/WebKit/win/WebView.h
index 8d66c16..3f20c69 100644
--- a/WebKit/win/WebView.h
+++ b/WebKit/win/WebView.h
@@ -673,9 +673,6 @@ public:
     virtual HRESULT STDMETHODCALLTYPE inspector(
         /* [retval][out] */ IWebInspector**);
 
-    virtual HRESULT STDMETHODCALLTYPE inspectorPrivate(
-        /* [retval][out] */ IWebInspectorPrivate**);
-
     virtual HRESULT STDMETHODCALLTYPE clearUndoRedoOperations( void);
     virtual HRESULT STDMETHODCALLTYPE shouldClose( 
         /* [retval][out] */ BOOL* result);
diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index d8baaa7..6a8a912 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,3 +1,17 @@
+2009-10-08  Adam Roben  <aroben at apple.com>
+
+        Use QueryInterface to get IWebInspectorPrivate
+
+        Fixes <http://webkit.org/b/30215> Make IWebInspectorPrivate be
+        accessed in a more standard way
+
+        Reviewed by John Sullivan and Tim Hatcher.
+
+        * DumpRenderTree/win/LayoutTestControllerWin.cpp:
+        (LayoutTestController::evaluateInWebInspector): Get the IWebInspector
+        by calling IWebViewPrivate::inspector, then use QueryInterface to get
+        to the IWebInspectorPrivate interface.
+
 2009-10-07  Adam Roben  <aroben at apple.com>
 
         Implement DRT support for origin whitelisting
diff --git a/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp b/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp
index ede71dc..cf3ac85 100644
--- a/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp
+++ b/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp
@@ -902,7 +902,13 @@ void LayoutTestController::evaluateInWebInspector(long callId, JSStringRef scrip
     if (FAILED(WebKitCreateInstance(__uuidof(WebView), 0, __uuidof(webView), reinterpret_cast<void**>(&webView))))
         return;
 
-    COMPtr<IWebInspectorPrivate> inspector;
-    if (SUCCEEDED(webView->inspectorPrivate(&inspector)))
-        inspector->evaluateInFrontend(callId, bstrT(script).GetBSTR());
+    COMPtr<IWebInspector> inspector;
+    if (FAILED(webView->inspector(&inspector)))
+        return;
+
+    COMPtr<IWebInspectorPrivate> inspectorPrivate(Query, inspector);
+    if (!inspectorPrivate)
+        return;
+
+    inspectorPrivate->evaluateInFrontend(callId, bstrT(script).GetBSTR());
 }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list