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

steveblock at google.com steveblock at google.com
Wed Dec 22 13:36:40 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit eca09110415f0d0a9f771809593a965a8d813804
Author: steveblock at google.com <steveblock at google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Sep 21 14:03:28 2010 +0000

    2010-09-21  Steve Block  <steveblock at google.com>
    
            Reviewed by Jeremy Orlow.
    
            DeviceOrientationClient and DeviceMotionClient should have controllerDestroyed() methods
            https://bugs.webkit.org/show_bug.cgi?id=45891
    
            Tested by existing DeviceOrientation tests.
    
            * dom/DeviceMotionClient.h:
            * dom/DeviceMotionController.cpp:
            (WebCore::DeviceMotionController::~DeviceMotionController):
            * dom/DeviceMotionController.h:
            * dom/DeviceOrientationClient.h:
            * dom/DeviceOrientationController.cpp:
            (WebCore::DeviceOrientationController::~DeviceOrientationController):
            * dom/DeviceOrientationController.h:
            * loader/EmptyClients.h:
            (WebCore::EmptyDeviceMotionClient::deviceOrientationControllerDestroyed):
            (WebCore::EmptyDeviceOrientationClient::deviceOrientationControllerDestroyed):
            * platform/mock/DeviceOrientationClientMock.h:
            (WebCore::DeviceOrientationClientMock::deviceOrientationControllerDestroyed):
    2010-09-21  Steve Block  <steveblock at google.com>
    
            Reviewed by Jeremy Orlow.
    
            DeviceOrientationClient and DeviceMotionClient should have controllerDestroyed() methods
            https://bugs.webkit.org/show_bug.cgi?id=45891
    
            Implements DeviceOrientationClientProxy::deviceOrientationControllerDestroyed() as a no-op,
            as the client's lifetime is determined by the WebViewImpl.
    
            * src/DeviceOrientationClientProxy.cpp:
            (WebKit::DeviceOrientationClientProxy::deviceOrientationControllerDestroyed):
            * src/DeviceOrientationClientProxy.h:
    2010-09-21  Steve Block  <steveblock at google.com>
    
            Reviewed by Jeremy Orlow.
    
            DeviceOrientationClient and DeviceMotionClient should have controllerDestroyed() methods
            https://bugs.webkit.org/show_bug.cgi?id=45891
    
            Implements WebDeviceOrientationClient::deviceOrientationControllerDestroyed to delete the client.
    
            * WebCoreSupport/WebDeviceOrientationClient.h:
            * WebCoreSupport/WebDeviceOrientationClient.mm:
            (WebDeviceOrientationClient::deviceOrientationControllerDestroyed):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@67949 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index caccb9f..fc79393 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,26 @@
+2010-09-21  Steve Block  <steveblock at google.com>
+
+        Reviewed by Jeremy Orlow.
+
+        DeviceOrientationClient and DeviceMotionClient should have controllerDestroyed() methods
+        https://bugs.webkit.org/show_bug.cgi?id=45891
+
+        Tested by existing DeviceOrientation tests.
+
+        * dom/DeviceMotionClient.h:
+        * dom/DeviceMotionController.cpp:
+        (WebCore::DeviceMotionController::~DeviceMotionController):
+        * dom/DeviceMotionController.h:
+        * dom/DeviceOrientationClient.h:
+        * dom/DeviceOrientationController.cpp:
+        (WebCore::DeviceOrientationController::~DeviceOrientationController):
+        * dom/DeviceOrientationController.h:
+        * loader/EmptyClients.h:
+        (WebCore::EmptyDeviceMotionClient::deviceOrientationControllerDestroyed):
+        (WebCore::EmptyDeviceOrientationClient::deviceOrientationControllerDestroyed):
+        * platform/mock/DeviceOrientationClientMock.h:
+        (WebCore::DeviceOrientationClientMock::deviceOrientationControllerDestroyed):
+
 2010-09-21  Jochen Eisinger  <jochen at chromium.org>
 
         Reviewed by Jeremy Orlow.
diff --git a/WebCore/dom/DeviceMotionClient.h b/WebCore/dom/DeviceMotionClient.h
index d19f92f..45bf11a 100644
--- a/WebCore/dom/DeviceMotionClient.h
+++ b/WebCore/dom/DeviceMotionClient.h
@@ -38,6 +38,7 @@ public:
     virtual void startUpdating() = 0;
     virtual void stopUpdating() = 0;
     virtual DeviceMotionData* currentDeviceMotion() const = 0;
+    virtual void deviceMotionControllerDestroyed() = 0;
 };
 
 } // namespace WebCore
diff --git a/WebCore/dom/DeviceMotionController.cpp b/WebCore/dom/DeviceMotionController.cpp
index 73b948e..3385167 100644
--- a/WebCore/dom/DeviceMotionController.cpp
+++ b/WebCore/dom/DeviceMotionController.cpp
@@ -40,6 +40,11 @@ DeviceMotionController::DeviceMotionController(DeviceMotionClient* client)
     m_client->setController(this);
 }
 
+DeviceMotionController::~DeviceMotionController()
+{
+    m_client->deviceMotionControllerDestroyed();
+}
+
 void DeviceMotionController::timerFired(Timer<DeviceMotionController>* timer)
 {
     ASSERT_UNUSED(timer, timer == &m_timer);
diff --git a/WebCore/dom/DeviceMotionController.h b/WebCore/dom/DeviceMotionController.h
index 2670e04..422be73 100644
--- a/WebCore/dom/DeviceMotionController.h
+++ b/WebCore/dom/DeviceMotionController.h
@@ -38,6 +38,7 @@ class DeviceMotionClient;
 class DeviceMotionController {
 public:
     DeviceMotionController(DeviceMotionClient*);
+    ~DeviceMotionController();
 
     void addListener(DOMWindow*);
     void removeListener(DOMWindow*);
diff --git a/WebCore/dom/DeviceOrientationClient.h b/WebCore/dom/DeviceOrientationClient.h
index c969c95..347c3b3 100644
--- a/WebCore/dom/DeviceOrientationClient.h
+++ b/WebCore/dom/DeviceOrientationClient.h
@@ -39,6 +39,7 @@ public:
     virtual void startUpdating() = 0;
     virtual void stopUpdating() = 0;
     virtual DeviceOrientation* lastOrientation() const = 0;
+    virtual void deviceOrientationControllerDestroyed() = 0;
 };
 
 } // namespace WebCore
diff --git a/WebCore/dom/DeviceOrientationController.cpp b/WebCore/dom/DeviceOrientationController.cpp
index a744366..60fcf13 100644
--- a/WebCore/dom/DeviceOrientationController.cpp
+++ b/WebCore/dom/DeviceOrientationController.cpp
@@ -41,6 +41,11 @@ DeviceOrientationController::DeviceOrientationController(Page* page, DeviceOrien
     m_client->setController(this);
 }
 
+DeviceOrientationController::~DeviceOrientationController()
+{
+    m_client->deviceOrientationControllerDestroyed();
+}
+
 void DeviceOrientationController::timerFired(Timer<DeviceOrientationController>* timer)
 {
     ASSERT_UNUSED(timer, timer == &m_timer);
diff --git a/WebCore/dom/DeviceOrientationController.h b/WebCore/dom/DeviceOrientationController.h
index 9517791..53b80f8 100644
--- a/WebCore/dom/DeviceOrientationController.h
+++ b/WebCore/dom/DeviceOrientationController.h
@@ -40,6 +40,7 @@ class Page;
 class DeviceOrientationController {
 public:
     DeviceOrientationController(Page*, DeviceOrientationClient*);
+    ~DeviceOrientationController();
 
     void addListener(DOMWindow*);
     void removeListener(DOMWindow*);
diff --git a/WebCore/loader/EmptyClients.h b/WebCore/loader/EmptyClients.h
index 99c443a..65ba3b8 100644
--- a/WebCore/loader/EmptyClients.h
+++ b/WebCore/loader/EmptyClients.h
@@ -542,6 +542,7 @@ public:
     virtual void startUpdating() { }
     virtual void stopUpdating() { }
     virtual DeviceMotionData* currentDeviceMotion() const { return 0; }
+    virtual void deviceMotionControllerDestroyed() { }
 };
 
 class EmptyDeviceOrientationClient : public DeviceOrientationClient {
@@ -550,6 +551,7 @@ public:
     virtual void startUpdating() { }
     virtual void stopUpdating() { }
     virtual DeviceOrientation* lastOrientation() const { return 0; }
+    virtual void deviceOrientationControllerDestroyed() { }
 };
 
 }
diff --git a/WebCore/platform/mock/DeviceOrientationClientMock.h b/WebCore/platform/mock/DeviceOrientationClientMock.h
index 6691130..baa4245 100644
--- a/WebCore/platform/mock/DeviceOrientationClientMock.h
+++ b/WebCore/platform/mock/DeviceOrientationClientMock.h
@@ -49,6 +49,7 @@ public:
     virtual void startUpdating();
     virtual void stopUpdating();
     virtual DeviceOrientation* lastOrientation() const { return m_orientation.get(); }
+    virtual void deviceOrientationControllerDestroyed() { }
 
     void setOrientation(PassRefPtr<DeviceOrientation>);
 
diff --git a/WebKit/chromium/ChangeLog b/WebKit/chromium/ChangeLog
index e376974..fc1b5f3 100644
--- a/WebKit/chromium/ChangeLog
+++ b/WebKit/chromium/ChangeLog
@@ -1,3 +1,17 @@
+2010-09-21  Steve Block  <steveblock at google.com>
+
+        Reviewed by Jeremy Orlow.
+
+        DeviceOrientationClient and DeviceMotionClient should have controllerDestroyed() methods
+        https://bugs.webkit.org/show_bug.cgi?id=45891
+
+        Implements DeviceOrientationClientProxy::deviceOrientationControllerDestroyed() as a no-op,
+        as the client's lifetime is determined by the WebViewImpl.
+
+        * src/DeviceOrientationClientProxy.cpp:
+        (WebKit::DeviceOrientationClientProxy::deviceOrientationControllerDestroyed):
+        * src/DeviceOrientationClientProxy.h:
+
 2010-09-21  Jochen Eisinger  <jochen at chromium.org>
 
         Reviewed by Jeremy Orlow.
diff --git a/WebKit/chromium/src/DeviceOrientationClientProxy.cpp b/WebKit/chromium/src/DeviceOrientationClientProxy.cpp
index f4a0dd9..29b43ba 100644
--- a/WebKit/chromium/src/DeviceOrientationClientProxy.cpp
+++ b/WebKit/chromium/src/DeviceOrientationClientProxy.cpp
@@ -71,4 +71,9 @@ WebCore::DeviceOrientation* DeviceOrientationClientProxy::lastOrientation() cons
     return m_lastOrientation.get();
 }
 
+void DeviceOrientationClientProxy::deviceOrientationControllerDestroyed()
+{
+    // Our lifetime is bound to the WebViewImpl.
+}
+
 } // namespace WebKit
diff --git a/WebKit/chromium/src/DeviceOrientationClientProxy.h b/WebKit/chromium/src/DeviceOrientationClientProxy.h
index 2d3a7dc..e90d77f 100644
--- a/WebKit/chromium/src/DeviceOrientationClientProxy.h
+++ b/WebKit/chromium/src/DeviceOrientationClientProxy.h
@@ -48,6 +48,7 @@ public:
     void startUpdating();
     void stopUpdating();
     WebCore::DeviceOrientation* lastOrientation() const;
+    virtual void deviceOrientationControllerDestroyed();
 
 private:
     WebDeviceOrientationClient* m_client;
diff --git a/WebKit/mac/ChangeLog b/WebKit/mac/ChangeLog
index c3b9f55..10d80ca 100644
--- a/WebKit/mac/ChangeLog
+++ b/WebKit/mac/ChangeLog
@@ -1,3 +1,16 @@
+2010-09-21  Steve Block  <steveblock at google.com>
+
+        Reviewed by Jeremy Orlow.
+
+        DeviceOrientationClient and DeviceMotionClient should have controllerDestroyed() methods
+        https://bugs.webkit.org/show_bug.cgi?id=45891
+
+        Implements WebDeviceOrientationClient::deviceOrientationControllerDestroyed to delete the client.
+
+        * WebCoreSupport/WebDeviceOrientationClient.h:
+        * WebCoreSupport/WebDeviceOrientationClient.mm:
+        (WebDeviceOrientationClient::deviceOrientationControllerDestroyed):
+
 2010-09-20  Philippe Normand  <pnormand at igalia.com>
 
         Reviewed by Eric Carlson.
diff --git a/WebKit/mac/WebCoreSupport/WebDeviceOrientationClient.h b/WebKit/mac/WebCoreSupport/WebDeviceOrientationClient.h
index 1cbc8e2..8e1c274 100644
--- a/WebKit/mac/WebCoreSupport/WebDeviceOrientationClient.h
+++ b/WebKit/mac/WebCoreSupport/WebDeviceOrientationClient.h
@@ -47,6 +47,7 @@ public:
     virtual void startUpdating();
     virtual void stopUpdating();
     virtual WebCore::DeviceOrientation* lastOrientation() const;
+    virtual void deviceOrientationControllerDestroyed();
 
 private:
     id<WebDeviceOrientationProvider> getProvider() const;
diff --git a/WebKit/mac/WebCoreSupport/WebDeviceOrientationClient.mm b/WebKit/mac/WebCoreSupport/WebDeviceOrientationClient.mm
index 278e835..f0c624d 100644
--- a/WebKit/mac/WebCoreSupport/WebDeviceOrientationClient.mm
+++ b/WebKit/mac/WebCoreSupport/WebDeviceOrientationClient.mm
@@ -60,6 +60,11 @@ DeviceOrientation* WebDeviceOrientationClient::lastOrientation() const
     return core([getProvider() lastOrientation]);
 }
 
+void WebDeviceOrientationClient::deviceOrientationControllerDestroyed()
+{
+      delete this;
+}
+
 id<WebDeviceOrientationProvider> WebDeviceOrientationClient::getProvider() const
 {
     if (!m_provider) {

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list