[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.2.2-27-g91dab87

Gustavo Noronha Silva gns at gnome.org
Thu Jul 15 21:13:37 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit 66918166375e8be9ec4d263d7591201f36c7254a
Author: steveblock at google.com <steveblock at google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu May 20 20:10:12 2010 +0000

    2010-05-20  Marcus Bulach  <bulach at chromium.org>
    
            Reviewed by Steve Block.
    
            Ensure timers are stopped on Geolocation::disconnectFrame()
            https://bugs.webkit.org/show_bug.cgi?id=39388
    
            fast/dom/Geolocation/notimer-after-unload.html, plus it should be possible to re-enable Gtk LayoutTests.
    
            * page/Geolocation.cpp:
            (WebCore::Geolocation::disconnectFrame):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@59859 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/fast/dom/Geolocation/notimer-after-unload-expected.txt b/LayoutTests/fast/dom/Geolocation/notimer-after-unload-expected.txt
new file mode 100644
index 0000000..4dbf1b5
--- /dev/null
+++ b/LayoutTests/fast/dom/Geolocation/notimer-after-unload-expected.txt
@@ -0,0 +1,3 @@
+main frame - has 1 onunload handler(s)
+ALERT: unload-called
+You should have seen one unload alert appear.
diff --git a/LayoutTests/fast/dom/Geolocation/notimer-after-unload.html b/LayoutTests/fast/dom/Geolocation/notimer-after-unload.html
new file mode 100644
index 0000000..a2cb83f
--- /dev/null
+++ b/LayoutTests/fast/dom/Geolocation/notimer-after-unload.html
@@ -0,0 +1,13 @@
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="../../js/resources/js-test-style.css">
+<script src="../../js/resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/notimer-after-unload.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
+</html>
diff --git a/LayoutTests/fast/dom/Geolocation/resources/notimer-after-unload.js b/LayoutTests/fast/dom/Geolocation/resources/notimer-after-unload.js
new file mode 100644
index 0000000..28da5aa
--- /dev/null
+++ b/LayoutTests/fast/dom/Geolocation/resources/notimer-after-unload.js
@@ -0,0 +1,21 @@
+description("Tests that no timers will trigger for navigator.geolocation object after onunload.");
+
+if (window.layoutTestController) layoutTestController.setGeolocationPermission(true);
+
+document.body.onload = function() {
+    location = "data:text/html,You should have seen one unload alert appear.<script>window.setTimeout('if (window.layoutTestController) layoutTestController.notifyDone();', 100);</" + "script>";
+}
+
+document.body.onunload = function() {
+    navigator.geolocation.getCurrentPosition(
+        function(p) {alert('FAIL: Unexpected Geolocation success callback.');},
+        function(e) {alert('FAIL: Unexpected Geolocation error callback.' + e.code + e.message);},
+        {timeout: 0, maximumAge:0}
+    );
+    alert("unload-called");
+}
+
+var isAsynchronous = true;
+var successfullyParsed = true;
+
+if (window.layoutTestController) layoutTestController.waitUntilDone();
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 24d4b23..7d8ca7e 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,15 @@
+2010-05-20  Marcus Bulach  <bulach at chromium.org>
+
+        Reviewed by Steve Block.
+
+        Ensure timers are stopped on Geolocation::disconnectFrame()
+        https://bugs.webkit.org/show_bug.cgi?id=39388
+
+        fast/dom/Geolocation/notimer-after-unload.html, plus it should be possible to re-enable Gtk LayoutTests.
+
+        * page/Geolocation.cpp:
+        (WebCore::Geolocation::disconnectFrame):
+
 2010-03-22  Darin Adler  <darin at apple.com>
 
         Reviewed by Dan Bernstein.
diff --git a/WebCore/page/Geolocation.cpp b/WebCore/page/Geolocation.cpp
index d0b0b79..9acbc7f 100644
--- a/WebCore/page/Geolocation.cpp
+++ b/WebCore/page/Geolocation.cpp
@@ -219,6 +219,7 @@ Geolocation::~Geolocation()
 
 void Geolocation::disconnectFrame()
 {
+    stopTimers();
     stopUpdating();
     if (m_frame) {
         if (m_frame->document())

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list