[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

bweinstein at apple.com bweinstein at apple.com
Wed Dec 22 16:09:17 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 65ac115fbd40575e3953508d7380c0e8ea4565f0
Author: bweinstein at apple.com <bweinstein at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Nov 19 01:11:27 2010 +0000

     WebKit2: Safari shouldn't auto-activate plug-ins in background tabs.
     https://bugs.webkit.org/show_bug.cgi?id=49770
     <rdar://problem/8482424>
    
    Reviewed by Adam Roben.
    
     Add an API on Windows to call setIsInWindow, which calls through to WebPage::setIsInWindow.
     Remove the !PLATFORM(WIN) check in WebPage, so we don't automatically start plugins that are
     loaded in background tabs.
    
    * UIProcess/API/C/win/WKView.cpp:
    (WKViewSetIsInWindow): Call through to WebView::setIsInWindow.
    * UIProcess/API/C/win/WKView.h:
    * UIProcess/win/WebView.cpp:
    (WebKit::WebView::setIsInWindow): Call through to WebPage::setIsInWindow.
    * UIProcess/win/WebView.h:
    * WebProcess/WebPage/WebPage.cpp:
    (WebKit::WebPage::WebPage): Remove the !PLATFORM(WIN) check and update the comment.
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@72352 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index a225e41..d59a143 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,3 +1,24 @@
+2010-11-18  Brian Weinstein  <bweinstein at apple.com>
+
+        Reviewed by Adam Roben.
+
+         WebKit2: Safari shouldn't auto-activate plug-ins in background tabs.
+         https://bugs.webkit.org/show_bug.cgi?id=49770
+         <rdar://problem/8482424>
+         
+         Add an API on Windows to call setIsInWindow, which calls through to WebPage::setIsInWindow.
+         Remove the !PLATFORM(WIN) check in WebPage, so we don't automatically start plugins that are
+         loaded in background tabs.
+
+        * UIProcess/API/C/win/WKView.cpp:
+        (WKViewSetIsInWindow): Call through to WebView::setIsInWindow.
+        * UIProcess/API/C/win/WKView.h:
+        * UIProcess/win/WebView.cpp:
+        (WebKit::WebView::setIsInWindow): Call through to WebPage::setIsInWindow.
+        * UIProcess/win/WebView.h:
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::WebPage): Remove the !PLATFORM(WIN) check and update the comment.
+
 2010-11-18  Darin Adler  <darin at apple.com>
 
         * WebProcess/WebPage/WebPage.cpp: Fix build by rolling out a change.
diff --git a/WebKit2/UIProcess/API/C/win/WKView.cpp b/WebKit2/UIProcess/API/C/win/WKView.cpp
index 95df964..947ea77 100644
--- a/WebKit2/UIProcess/API/C/win/WKView.cpp
+++ b/WebKit2/UIProcess/API/C/win/WKView.cpp
@@ -60,3 +60,8 @@ void WKViewWindowAncestryDidChange(WKViewRef viewRef)
 {
     toImpl(viewRef)->windowAncestryDidChange();
 }
+
+void WKViewSetIsInWindow(WKViewRef viewRef, bool isInWindow)
+{
+    toImpl(viewRef)->setIsInWindow(isInWindow);
+}
diff --git a/WebKit2/UIProcess/API/C/win/WKView.h b/WebKit2/UIProcess/API/C/win/WKView.h
index 817cc4c..043f486 100644
--- a/WebKit2/UIProcess/API/C/win/WKView.h
+++ b/WebKit2/UIProcess/API/C/win/WKView.h
@@ -43,6 +43,7 @@ WK_EXPORT WKPageRef WKViewGetPage(WKViewRef view);
 
 WK_EXPORT void WKViewSetParentWindow(WKViewRef view, HWND parentWindow);
 WK_EXPORT void WKViewWindowAncestryDidChange(WKViewRef view);
+WK_EXPORT void WKViewSetIsInWindow(WKViewRef view, bool isInWindow);
 
 #ifdef __cplusplus
 }
diff --git a/WebKit2/UIProcess/win/WebView.cpp b/WebKit2/UIProcess/win/WebView.cpp
index c26eeed..fa6d37c 100644
--- a/WebKit2/UIProcess/win/WebView.cpp
+++ b/WebKit2/UIProcess/win/WebView.cpp
@@ -643,7 +643,13 @@ void WebView::setFindIndicator(PassRefPtr<FindIndicator>, bool fadeOut)
     // FIXME: Implement.
 }
 
+void WebView::setIsInWindow(bool isInWindow)
+{
+    m_page->setIsInWindow(isInWindow);
+}
+
 #if USE(ACCELERATED_COMPOSITING)
+
 void WebView::pageDidEnterAcceleratedCompositing()
 {
     switchToDrawingAreaTypeIfNecessary(DrawingAreaProxy::LayerBackedDrawingAreaType);
diff --git a/WebKit2/UIProcess/win/WebView.h b/WebKit2/UIProcess/win/WebView.h
index ae5a833..ca76779 100644
--- a/WebKit2/UIProcess/win/WebView.h
+++ b/WebKit2/UIProcess/win/WebView.h
@@ -57,6 +57,7 @@ public:
     HWND window() const { return m_window; }
     void setParentWindow(HWND);
     void windowAncestryDidChange();
+    void setIsInWindow(bool);
     void setOverrideCursor(HCURSOR overrideCursor);
 
     WebPageProxy* page() const { return m_page.get(); }
diff --git a/WebKit2/WebProcess/WebPage/WebPage.cpp b/WebKit2/WebProcess/WebPage/WebPage.cpp
index 03ff299..146df97 100644
--- a/WebKit2/WebProcess/WebPage/WebPage.cpp
+++ b/WebKit2/WebProcess/WebPage/WebPage.cpp
@@ -131,11 +131,11 @@ WebPage::WebPage(uint64_t pageID, const WebPageCreationParameters& parameters)
     pageClients.backForwardClient = WebBackForwardListProxy::create(this);
     m_page = adoptPtr(new Page(pageClients));
 
-    // Windows and Qt do not yet call setIsInWindow. Until they do, just leave
+    // Qt does not yet call setIsInWindow. Until it does, just leave
     // this line out so plug-ins and video will work. Eventually all platforms
     // should call setIsInWindow and this comment and #if should be removed,
     // leaving behind the setCanStartMedia call.
-#if !PLATFORM(WIN) && !PLATFORM(QT)
+#if !PLATFORM(QT)
     m_page->setCanStartMedia(false);
 #endif
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list