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

jnd at chromium.org jnd at chromium.org
Wed Dec 22 17:55:37 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit ae563165d2afd566b29b19ff66a7c27f7fe4e415
Author: jnd at chromium.org <jnd at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Dec 2 20:17:06 2010 +0000

    2010-12-02  Johnny Ding  <jnd at chromium.org>
    
            Reviewed by Adam Barth.
    
            Set the right gesture status for URL redirections.
            https://bugs.webkit.org/show_bug.cgi?id=47817
    
            * fast/frames/location-redirect-user-gesture-expected.txt: Added.
            * fast/frames/location-redirect-user-gesture.html: Added.
            * fast/frames/meta-refresh-user-gesture-expected.txt: Added.
            * fast/frames/meta-refresh-user-gesture.html: Added.
            * fast/frames/resources/meta-refresh-target.html: Added.
            * platform/gtk/Skipped:
            * platform/win/Skipped:
    2010-12-02  Johnny Ding  <jnd at chromium.org>
    
            Reviewed by Adam Barth.
    
            Set the right gesture status for URL redirections.
            https://bugs.webkit.org/show_bug.cgi?id=47817
    
            Tests: fast/frames/location-redirect-user-gesture.html
                   fast/frames/meta-refresh-user-gesture.html
    
            * loader/NavigationScheduler.cpp:
            (WebCore::ScheduledNavigation::clearUserGesture):
            (WebCore::ScheduledRedirect::ScheduledRedirect):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@73181 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index ad4a78d..bb27f58 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,18 @@
+2010-12-02  Johnny Ding  <jnd at chromium.org>
+
+        Reviewed by Adam Barth.
+
+        Set the right gesture status for URL redirections.
+        https://bugs.webkit.org/show_bug.cgi?id=47817
+
+        * fast/frames/location-redirect-user-gesture-expected.txt: Added.
+        * fast/frames/location-redirect-user-gesture.html: Added.
+        * fast/frames/meta-refresh-user-gesture-expected.txt: Added.
+        * fast/frames/meta-refresh-user-gesture.html: Added.
+        * fast/frames/resources/meta-refresh-target.html: Added.
+        * platform/gtk/Skipped:
+        * platform/win/Skipped:
+
 2010-12-02  Eric Seidel  <eric at webkit.org>
 
         Unreviewed.
diff --git a/LayoutTests/fast/frames/location-redirect-user-gesture-expected.txt b/LayoutTests/fast/frames/location-redirect-user-gesture-expected.txt
new file mode 100644
index 0000000..142a05f
--- /dev/null
+++ b/LayoutTests/fast/frames/location-redirect-user-gesture-expected.txt
@@ -0,0 +1,2 @@
+Frame with user gesture "false" - in didStartProvisionalLoadForFrame
+
diff --git a/LayoutTests/fast/frames/location-redirect-user-gesture.html b/LayoutTests/fast/frames/location-redirect-user-gesture.html
new file mode 100644
index 0000000..a019f9c
--- /dev/null
+++ b/LayoutTests/fast/frames/location-redirect-user-gesture.html
@@ -0,0 +1,19 @@
+<html>
+<head>
+<script>      
+    function runTests() {
+        if (window.layoutTestController) {
+            layoutTestController.dumpAsText();
+            layoutTestController.dumpUserGestureInFrameLoadCallbacks();
+            layoutTestController.waitUntilDone();
+        }
+
+        setTimeout("location.href='data:text/html,<script>layoutTestController.notifyDone()</" + "script>'", 1000);
+    }
+    </script>
+</head>
+<body onload="runTests();">
+Some WebKit ports send the user gesture to the embedders in didStartProvisionalLoad callback. The embedders use it to judge whether the navigation is user-initiated or not. In location change redirection, the user gesture status in didStartProvisionalLoad callback should be false. For more details, please refer to https://bugs.webkit.org/show_bug.cgi?id=47817.
+</div>
+</body>
+</html>
diff --git a/LayoutTests/fast/frames/meta-refresh-user-gesture-expected.txt b/LayoutTests/fast/frames/meta-refresh-user-gesture-expected.txt
new file mode 100644
index 0000000..142a05f
--- /dev/null
+++ b/LayoutTests/fast/frames/meta-refresh-user-gesture-expected.txt
@@ -0,0 +1,2 @@
+Frame with user gesture "false" - in didStartProvisionalLoadForFrame
+
diff --git a/LayoutTests/fast/frames/meta-refresh-user-gesture.html b/LayoutTests/fast/frames/meta-refresh-user-gesture.html
new file mode 100644
index 0000000..8c98986
--- /dev/null
+++ b/LayoutTests/fast/frames/meta-refresh-user-gesture.html
@@ -0,0 +1,15 @@
+<html>
+<head>
+<meta http-equiv="refresh" content="2;./resources/meta-refresh-target.html">
+<script>      
+if (window.layoutTestController) {
+    layoutTestController.dumpAsText();
+    layoutTestController.dumpUserGestureInFrameLoadCallbacks();
+    layoutTestController.waitUntilDone();
+}
+</script>
+</head>
+<body>
+Some WebKit ports send the user gesture to the embedders in didStartProvisionalLoad callback. The embedders use it to judge whether the navigation is user-initiated or not. In meta refresh redirection, the user gesture status in didStartProvisionalLoad callback should be false. For more details, please refer to https://bugs.webkit.org/show_bug.cgi?id=47817.
+</body>
+</html>
diff --git a/LayoutTests/fast/frames/resources/meta-refresh-target.html b/LayoutTests/fast/frames/resources/meta-refresh-target.html
new file mode 100644
index 0000000..f2099c3
--- /dev/null
+++ b/LayoutTests/fast/frames/resources/meta-refresh-target.html
@@ -0,0 +1,8 @@
+<html>
+<head>
+<script>
+if (layoutTestController)
+    layoutTestController.notifyDone();
+</script>
+</head>
+</html>
diff --git a/LayoutTests/platform/gtk/Skipped b/LayoutTests/platform/gtk/Skipped
index e680aac..8ad41cd 100644
--- a/LayoutTests/platform/gtk/Skipped
+++ b/LayoutTests/platform/gtk/Skipped
@@ -5540,6 +5540,13 @@ fast/images/webp-image-decoding.html
 # https://bugs.webkit.org/show_bug.cgi?id=47832
 http/tests/inspector/console-xhr-logging.html
 
+# The following tests requires the DRT's dumpUserGestureInFrameLoadCallbacks
+# method. But that method is not implemented in gtk port since gtk port can't
+# not get user gesture in frameload callbacks.
+# The related bugs are https://bugs.webkit.org/show_bug.cgi?id=47849/47817.
+fast/frames/location-redirect-user-gesture.html
+fast/frames/meta-refresh-user-gesture.html
+
 # This test passes locally, but does not pass on the bots. Perhaps
 # it is an issue with the version of Cairo on the bots.
 # https://bugs.webkit.org/show_bug.cgi?id=49052
diff --git a/LayoutTests/platform/win/Skipped b/LayoutTests/platform/win/Skipped
index 3b17130..82bd9b7 100644
--- a/LayoutTests/platform/win/Skipped
+++ b/LayoutTests/platform/win/Skipped
@@ -1072,3 +1072,10 @@ fast/images/webp-image-decoding.html
 
 # Missing layoutTestController.findString() http://webkit.org/b/50234
 editing/text-iterator/findString.html
+ 
+# The following tests requires the DRT's dumpUserGestureInFrameLoadCallbacks
+# method. But that method is not implemented in win port since win port can't
+# not get user gesture in frameload callbacks.
+# The relevant bugs are https://bugs.webkit.org/show_bug.cgi?id=47849/47817.
+fast/frames/location-redirect-user-gesture.html
+fast/frames/meta-refresh-user-gesture.html
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 499de2b..4f1b676 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,17 @@
+2010-12-02  Johnny Ding  <jnd at chromium.org>
+
+        Reviewed by Adam Barth.
+
+        Set the right gesture status for URL redirections.
+        https://bugs.webkit.org/show_bug.cgi?id=47817
+
+        Tests: fast/frames/location-redirect-user-gesture.html
+               fast/frames/meta-refresh-user-gesture.html
+
+        * loader/NavigationScheduler.cpp:
+        (WebCore::ScheduledNavigation::clearUserGesture):
+        (WebCore::ScheduledRedirect::ScheduledRedirect):
+
 2010-12-02  Chris Rogers  <crogers at google.com>
 
         Reviewed by Kenneth Russell.
diff --git a/WebCore/loader/NavigationScheduler.cpp b/WebCore/loader/NavigationScheduler.cpp
index 28fda9a..7c691ae 100644
--- a/WebCore/loader/NavigationScheduler.cpp
+++ b/WebCore/loader/NavigationScheduler.cpp
@@ -77,6 +77,9 @@ public:
     bool isLocationChange() const { return m_isLocationChange; }
     bool wasUserGesture() const { return m_wasUserGesture; }
 
+protected:
+    void clearUserGesture() { m_wasUserGesture = false; }
+
 private:
     double m_delay;
     bool m_lockHistory;
@@ -131,6 +134,7 @@ public:
     ScheduledRedirect(double delay, const String& url, bool lockHistory, bool lockBackForwardList)
         : ScheduledURLNavigation(delay, url, String(), lockHistory, lockBackForwardList, false, false)
     {
+        clearUserGesture();
     }
 
     virtual bool shouldStartTimer(Frame* frame) { return frame->loader()->allAncestorsAreComplete(); }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list