[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373

eric at webkit.org eric at webkit.org
Thu Apr 8 02:05:47 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit 869ecb03b8f6cbbe1ab954aa52ba340842af2399
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Mon Mar 1 22:51:25 2010 +0000

    2010-03-01  Thatcher Ulrich  <tulrich at google.com>
    
            Reviewed by Darin Fisher.
    
            Fix chromium iframe shims.  Add another test case to the
            iframes-shims test.  After r53637, the plugin widget doesn't get
            moved every paint.  This used to hide the bug that if an iframe
            gets added, the plugin's cutout rectangles don't get updated until
            a layout happens.
            https://bugs.webkit.org/show_bug.cgi?id=35184
    
            * plugins/iframe-shims.html: test case that adds an iframe shim dynamically
    2010-03-01  Thatcher Ulrich  <tulrich at google.com>
    
            Reviewed by Darin Fisher.
    
            Fix chromium iframe shims.  Add another test case to the
            iframes-shims test.  After r53637, the plugin widget doesn't get
            moved every paint.  This used to hide the bug that if an iframe
            gets added, the plugin's cutout rectangles don't get updated until
            a layout happens.
            https://bugs.webkit.org/show_bug.cgi?id=35184
    
            * platform/Widget.h:
            (WebCore::Widget::widgetPositionsUpdated): new virtual method
                widgetPositionsUpdated() to notify widgets when other widgets on
                the page have been repositioned.
            * rendering/RenderView.cpp:
            (WebCore::RenderView::updateWidgetPositions): call widgetPositionsUpdated() on the widgets
            * rendering/RenderWidget.cpp:
            (WebCore::RenderWidget::widgetPositionsUpdated): call widgetPositionsUpdated() on the widget
            * rendering/RenderWidget.h:
    2010-03-01  Thatcher Ulrich  <tulrich at google.com>
    
            Reviewed by Darin Fisher.
    
            Fix chromium iframe shims.  Add another test case to the
            iframes-shims test.  After r53637, the plugin widget doesn't get
            moved every paint.  This used to hide the bug that if an iframe
            gets added, the plugin's cutout rectangles don't get updated until
            a layout happens.
            https://bugs.webkit.org/show_bug.cgi?id=35184
    
            * src/WebPluginContainerImpl.cpp:
            (WebKit::WebPluginContainerImpl::widgetPositionsUpdated): do reportGeometry() to ensure that
                the plugin is aware of the positions of cutouts on the page (for iframe shim behavior).
            * src/WebPluginContainerImpl.h:
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@55381 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 36f68d9..95f5989 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,16 @@
+2010-03-01  Thatcher Ulrich  <tulrich at google.com>
+
+        Reviewed by Darin Fisher.
+
+        Fix chromium iframe shims.  Add another test case to the
+        iframes-shims test.  After r53637, the plugin widget doesn't get
+        moved every paint.  This used to hide the bug that if an iframe
+        gets added, the plugin's cutout rectangles don't get updated until
+        a layout happens.
+        https://bugs.webkit.org/show_bug.cgi?id=35184
+
+        * plugins/iframe-shims.html: test case that adds an iframe shim dynamically
+
 2010-03-01  Gavin Barraclough  <barraclough at apple.com>
 
         Reviewed by Oliver Hunt.
diff --git a/LayoutTests/plugins/iframe-shims-expected.txt b/LayoutTests/plugins/iframe-shims-expected.txt
index 8ac528c..90637a4 100644
--- a/LayoutTests/plugins/iframe-shims-expected.txt
+++ b/LayoutTests/plugins/iframe-shims-expected.txt
@@ -20,3 +20,5 @@ SUCCESS
 
 
 
+
+
diff --git a/LayoutTests/plugins/iframe-shims.html b/LayoutTests/plugins/iframe-shims.html
index e4be006..f76fd78 100644
--- a/LayoutTests/plugins/iframe-shims.html
+++ b/LayoutTests/plugins/iframe-shims.html
@@ -48,6 +48,35 @@
             ');" value="clickme" style="position: absolute; top: 10; left: 10; width: 60px; height: 60px;"/>';
         return o;
     }
+    
+    function appendOverlay(overlayDivZIframe, overlayDivZOverlay, overlayInsideDiv, expectClickable, caseId)
+    {
+        var id = makeIframeDiv();
+        var root = document.getElementById(caseId);
+        if (overlayDivZIframe)
+            id.style.zIndex = overlayDivZIframe;
+
+        var od = makeOverlayDiv(expectClickable ? 'green' : 'red', caseId);
+        od.style.position = 'absolute';
+        if (overlayDivZOverlay)
+            od.style.zIndex = overlayDivZOverlay;
+
+        if (overlayInsideDiv) {
+            var parentdiv = document.createElement('div');
+            if (overlayDivZOverlay)
+                parentdiv.style.zIndex = overlayDivZOverlay;
+
+            parentdiv.style.position = 'absolute';
+            parentdiv.style.top = '0px';
+            parentdiv.style.left = '0px';
+            parentdiv.appendChild(id);
+            parentdiv.appendChild(od);
+            root.appendChild(parentdiv);
+        } else {
+            root.appendChild(id);
+            root.appendChild(od);
+        }
+    };
 
     function addCase(x, y, tags)
     {
@@ -62,6 +91,7 @@
         root.style.position = 'absolute';
         root.style.left = x * (width + 40) + 'px';
         root.style.top = y * (height + 20) + 'px';
+        root.id = caseId;
         container.appendChild(root);
 
         var pluginDivZ;
@@ -102,40 +132,16 @@
             }
         };
 
-        var appendOverlay = function()
-        {
-            var id = makeIframeDiv();
-            if (overlayDivZIframe)
-                id.style.zIndex = overlayDivZIframe;
-
-            var od = makeOverlayDiv(expectClickable ? 'green' : 'red', caseId);
-            od.style.position = 'absolute';
-            if (overlayDivZOverlay)
-                od.style.zIndex = overlayDivZOverlay;
-
-            if (tags.overlayInsideDiv) {
-                var parentdiv = document.createElement('div');
-                if (overlayDivZOverlay)
-                    parentdiv.style.zIndex = overlayDivZOverlay;
-
-                parentdiv.style.position = 'absolute';
-                parentdiv.style.top = '0px';
-                parentdiv.style.left = '0px';
-                parentdiv.appendChild(id);
-                parentdiv.appendChild(od);
-                root.appendChild(parentdiv);
-            } else {
-                root.appendChild(id);
-                root.appendChild(od);
-            }
-        };
-
         if (tags.overlayEarlier) {
-            appendOverlay();
+            appendOverlay(overlayDivZIframe, overlayDivZOverlay, tags.overlayInsideDiv, expectClickable, caseId);
             appendPlugin();
         } else {
             appendPlugin();
-            appendOverlay();
+            if (tags.overlayOnTimeout) {
+                setTimeout('appendOverlay('+overlayDivZIframe+', '+overlayDivZOverlay +', ' + tags.overlayInsideDiv + ', ' + expectClickable + ', ' + caseId + ')', 0);
+            } else {
+                appendOverlay(overlayDivZIframe, overlayDivZOverlay, tags.overlayInsideDiv, expectClickable, caseId);
+            }
         }
      }
 
@@ -177,6 +183,7 @@
         addCase(0, 3, {'pluginNorelative':1, expect:'overlay OVER'});
         addCase(1, 3, {'overlayEarlier':1, 'pluginNorelative':1, 'pluginInsideDiv':1, expect:'overlay OVER'});
         addCase(2, 3, {'pluginNorelative':1, 'pluginInsideDiv':1, expect:'overlay OVER'});
+        addCase(3, 3, {'pluginLowerz':1, 'overlayOnTimeout':1, expect:'overlay OVER'});
 
         runTest();
     }
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 813f40d..22cee78 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,24 @@
+2010-03-01  Thatcher Ulrich  <tulrich at google.com>
+
+        Reviewed by Darin Fisher.
+
+        Fix chromium iframe shims.  Add another test case to the
+        iframes-shims test.  After r53637, the plugin widget doesn't get
+        moved every paint.  This used to hide the bug that if an iframe
+        gets added, the plugin's cutout rectangles don't get updated until
+        a layout happens.
+        https://bugs.webkit.org/show_bug.cgi?id=35184
+
+        * platform/Widget.h:
+        (WebCore::Widget::widgetPositionsUpdated): new virtual method
+            widgetPositionsUpdated() to notify widgets when other widgets on
+            the page have been repositioned.
+        * rendering/RenderView.cpp:
+        (WebCore::RenderView::updateWidgetPositions): call widgetPositionsUpdated() on the widgets
+        * rendering/RenderWidget.cpp:
+        (WebCore::RenderWidget::widgetPositionsUpdated): call widgetPositionsUpdated() on the widget
+        * rendering/RenderWidget.h:
+
 2010-03-01  Fridrich Strba  <fridrich.strba at bluewin.ch>
 
         Reviewed by Holger Freyther.
diff --git a/WebCore/platform/Widget.h b/WebCore/platform/Widget.h
index a713afa..db91bbf 100644
--- a/WebCore/platform/Widget.h
+++ b/WebCore/platform/Widget.h
@@ -186,6 +186,9 @@ public:
 
     virtual void frameRectsChanged() {}
 
+    // Notifies this widget that other widgets on the page have been repositioned.
+    virtual void widgetPositionsUpdated() {}
+
 #if PLATFORM(MAC)
     NSView* getOuterView() const;
     
diff --git a/WebCore/rendering/RenderView.cpp b/WebCore/rendering/RenderView.cpp
index 69a1173..4f76e80 100644
--- a/WebCore/rendering/RenderView.cpp
+++ b/WebCore/rendering/RenderView.cpp
@@ -541,6 +541,8 @@ void RenderView::updateWidgetPositions()
     RenderWidgetSet::iterator end = m_widgets.end();
     for (RenderWidgetSet::iterator it = m_widgets.begin(); it != end; ++it)
         (*it)->updateWidgetPosition();
+    for (RenderWidgetSet::iterator it = m_widgets.begin(); it != end; ++it)
+        (*it)->widgetPositionsUpdated();
 }
 
 void RenderView::addWidget(RenderWidget* o)
diff --git a/WebCore/rendering/RenderWidget.cpp b/WebCore/rendering/RenderWidget.cpp
index 4763309..96a2731 100644
--- a/WebCore/rendering/RenderWidget.cpp
+++ b/WebCore/rendering/RenderWidget.cpp
@@ -325,6 +325,13 @@ void RenderWidget::updateWidgetPosition()
     }
 }
 
+void RenderWidget::widgetPositionsUpdated()
+{
+    if (!m_widget)
+        return;
+    m_widget->widgetPositionsUpdated();
+}
+
 void RenderWidget::setSelectionState(SelectionState state)
 {
     if (selectionState() != state) {
diff --git a/WebCore/rendering/RenderWidget.h b/WebCore/rendering/RenderWidget.h
index 6cad04a..4076cc3 100644
--- a/WebCore/rendering/RenderWidget.h
+++ b/WebCore/rendering/RenderWidget.h
@@ -39,6 +39,7 @@ public:
     static RenderWidget* find(const Widget*);
 
     void updateWidgetPosition();
+    void widgetPositionsUpdated();
 
     void showSubstituteImage(PassRefPtr<Image>);
 
diff --git a/WebKit/chromium/ChangeLog b/WebKit/chromium/ChangeLog
index 398a8c6..b4cfaa9 100644
--- a/WebKit/chromium/ChangeLog
+++ b/WebKit/chromium/ChangeLog
@@ -1,3 +1,19 @@
+2010-03-01  Thatcher Ulrich  <tulrich at google.com>
+
+        Reviewed by Darin Fisher.
+
+        Fix chromium iframe shims.  Add another test case to the
+        iframes-shims test.  After r53637, the plugin widget doesn't get
+        moved every paint.  This used to hide the bug that if an iframe
+        gets added, the plugin's cutout rectangles don't get updated until
+        a layout happens.
+        https://bugs.webkit.org/show_bug.cgi?id=35184
+
+        * src/WebPluginContainerImpl.cpp:
+        (WebKit::WebPluginContainerImpl::widgetPositionsUpdated): do reportGeometry() to ensure that
+            the plugin is aware of the positions of cutouts on the page (for iframe shim behavior).
+        * src/WebPluginContainerImpl.h:
+
 2010-02-27  Pavel Feldman  <pfeldman at chromium.org>
 
         Reviewed by Timothy Hatcher.
diff --git a/WebKit/chromium/src/WebPluginContainerImpl.cpp b/WebKit/chromium/src/WebPluginContainerImpl.cpp
index 86cac26..c44434c 100644
--- a/WebKit/chromium/src/WebPluginContainerImpl.cpp
+++ b/WebKit/chromium/src/WebPluginContainerImpl.cpp
@@ -170,6 +170,12 @@ void WebPluginContainerImpl::frameRectsChanged()
     reportGeometry();
 }
 
+void WebPluginContainerImpl::widgetPositionsUpdated()
+{
+    Widget::widgetPositionsUpdated();
+    reportGeometry();
+}
+
 void WebPluginContainerImpl::setParentVisible(bool parentVisible)
 {
     // We override this function to make sure that geometry updates are sent
diff --git a/WebKit/chromium/src/WebPluginContainerImpl.h b/WebKit/chromium/src/WebPluginContainerImpl.h
index 00450bb..8e1b75a 100644
--- a/WebKit/chromium/src/WebPluginContainerImpl.h
+++ b/WebKit/chromium/src/WebPluginContainerImpl.h
@@ -73,6 +73,7 @@ public:
     virtual void frameRectsChanged();
     virtual void setParentVisible(bool);
     virtual void setParent(WebCore::ScrollView*);
+    virtual void widgetPositionsUpdated();
 
     // WebPluginContainer methods
     virtual void invalidate();

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list