Remove dead context menu code
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 26 Oct 2015 19:01:28 +0000 (19:01 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 26 Oct 2015 19:01:28 +0000 (19:01 +0000)
https://bugs.webkit.org/show_bug.cgi?id=150567

Reviewed by Tim Horton.

Source/WebCore:

* loader/EmptyClients.h:
* page/ContextMenuClient.h:
* page/ContextMenuController.cpp:
(WebCore::ContextMenuController::showContextMenu): Deleted.

Source/WebKit/mac:

* WebCoreSupport/WebContextMenuClient.h:
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::getCustomMenuFromDefaultItems): Deleted.

Source/WebKit2:

* WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
(WebKit::WebContextMenuClient::getCustomMenuFromDefaultItems): Deleted.
* WebProcess/WebCoreSupport/WebContextMenuClient.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@191591 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/loader/EmptyClients.h
Source/WebCore/page/ContextMenuClient.h
Source/WebCore/page/ContextMenuController.cpp
Source/WebKit/mac/ChangeLog
Source/WebKit/mac/WebCoreSupport/WebContextMenuClient.h
Source/WebKit/mac/WebCoreSupport/WebContextMenuClient.mm
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/WebCoreSupport/WebContextMenuClient.cpp
Source/WebKit2/WebProcess/WebCoreSupport/WebContextMenuClient.h

index 3082c8d3994c31144be2f42ee5b10b78f074204b..d6d6a28a61f8d1933f88000012196e88584028e3 100644 (file)
@@ -1,3 +1,15 @@
+2015-10-26  Anders Carlsson  <andersca@apple.com>
+
+        Remove dead context menu code
+        https://bugs.webkit.org/show_bug.cgi?id=150567
+
+        Reviewed by Tim Horton.
+
+        * loader/EmptyClients.h:
+        * page/ContextMenuClient.h:
+        * page/ContextMenuController.cpp:
+        (WebCore::ContextMenuController::showContextMenu): Deleted.
+
 2015-10-26  Simon Fraser  <simon.fraser@apple.com>
 
         Implement 'round' and 'space' values for border-image
index ea01109b24c51f8c67a5750c77b11e59c4166d25..72cc8ab434c4d7e36c527c22836ccd0607584cef 100644 (file)
@@ -549,9 +549,6 @@ public:
     virtual ~EmptyContextMenuClient() {  }
     virtual void contextMenuDestroyed() override { }
 
-#if !USE(CROSS_PLATFORM_CONTEXT_MENUS)
-    virtual PlatformMenuDescription getCustomMenuFromDefaultItems(ContextMenu*) override { return nullptr; }
-#endif
     virtual void contextMenuItemSelected(ContextMenuItem*, const ContextMenu*) override { }
 
     virtual void downloadURL(const URL&) override { }
index 20a2f0b1844351fdba91a90e17ef3e2bc556ea5d..667bc5812445874e104c0b90da817593a6e97786 100644 (file)
@@ -43,10 +43,6 @@ namespace WebCore {
         virtual ~ContextMenuClient() {  }
         virtual void contextMenuDestroyed() = 0;
         
-#if !USE(CROSS_PLATFORM_CONTEXT_MENUS)
-        virtual PlatformMenuDescription getCustomMenuFromDefaultItems(ContextMenu*) = 0;
-#endif
-
         virtual void contextMenuItemSelected(ContextMenuItem*, const ContextMenu*) = 0;
 
         virtual void downloadURL(const URL& url) = 0;
index 499bcb9d2487bc2ad4981cb03e469eb10a1c7886..a2c6effee87b397f907552e0ae98e29535df1058 100644 (file)
@@ -181,10 +181,6 @@ void ContextMenuController::showContextMenu(Event* event)
     if (m_page.inspectorController().enabled())
         addInspectElementItem();
 
-#if !USE(CROSS_PLATFORM_CONTEXT_MENUS)
-    PlatformMenuDescription customMenu = m_client.getCustomMenuFromDefaultItems(m_contextMenu.get());
-    m_contextMenu->setPlatformDescription(customMenu);
-#endif
     event->setDefaultHandled();
 }
 
index 319162d9d0ed652b4a44eafb17921146f16ee4ec..c387da5c746c2a410eb406eda156a11fccee2662 100644 (file)
@@ -1,3 +1,14 @@
+2015-10-26  Anders Carlsson  <andersca@apple.com>
+
+        Remove dead context menu code
+        https://bugs.webkit.org/show_bug.cgi?id=150567
+
+        Reviewed by Tim Horton.
+
+        * WebCoreSupport/WebContextMenuClient.h:
+        * WebCoreSupport/WebContextMenuClient.mm:
+        (WebContextMenuClient::getCustomMenuFromDefaultItems): Deleted.
+
 2015-10-23  Anders Carlsson  <andersca@apple.com>
 
         Invoke the context menu delegate callback right before we return the menu
index 9500abb3459f6c6e185bcc0b5a0dd5b5c219eb8f..56d0518e94d525db14112d60af3a42a6ce597152 100644 (file)
@@ -50,7 +50,6 @@ public:
 
     virtual void contextMenuDestroyed() override;
     
-    virtual NSMutableArray* getCustomMenuFromDefaultItems(WebCore::ContextMenu*) override;
     virtual void contextMenuItemSelected(WebCore::ContextMenuItem*, const WebCore::ContextMenu*) override;
     
     virtual void downloadURL(const WebCore::URL&) override;
index 5e5c3da7244ee4ae028cd99740c15adfc2440171..7bdaa4e1899f0e2ad634aefc4bbe66168c17c8c4 100644 (file)
@@ -89,11 +89,6 @@ void WebContextMenuClient::contextMenuDestroyed()
     delete this;
 }
 
-NSMutableArray* WebContextMenuClient::getCustomMenuFromDefaultItems(ContextMenu* defaultMenu)
-{
-    return defaultMenu->platformDescription();
-}
-
 void WebContextMenuClient::contextMenuItemSelected(ContextMenuItem* item, const ContextMenu* parentMenu)
 {
     id delegate = [m_webView UIDelegate];
index a3f882aeb9333334fc5f1a0f4e1a61a3178e53e1..cb528c8dd8f145ed259001d3ce15e72d597490f3 100644 (file)
@@ -1,3 +1,14 @@
+2015-10-26  Anders Carlsson  <andersca@apple.com>
+
+        Remove dead context menu code
+        https://bugs.webkit.org/show_bug.cgi?id=150567
+
+        Reviewed by Tim Horton.
+
+        * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
+        (WebKit::WebContextMenuClient::getCustomMenuFromDefaultItems): Deleted.
+        * WebProcess/WebCoreSupport/WebContextMenuClient.h:
+
 2015-10-26  Tim Horton  <timothy_horton@apple.com>
 
         Don't expose the whitelist/blacklist in _WKUserStyleSheet
index 35919cff44fee4a58ae225ff954c94560e839ffa..a90cc3ab8d2ffc8304d28f0d2bbc9b54761ac922 100644 (file)
@@ -49,14 +49,6 @@ void WebContextMenuClient::contextMenuDestroyed()
     delete this;
 }
 
-#if !USE(CROSS_PLATFORM_CONTEXT_MENUS)
-PlatformMenuDescription WebContextMenuClient::getCustomMenuFromDefaultItems(ContextMenu* menu)
-{
-    // WebKit2 ignores this client callback and does context menu customization when it is told to show the menu.
-    return menu->platformDescription();
-}
-#endif
-
 void WebContextMenuClient::contextMenuItemSelected(ContextMenuItem*, const ContextMenu*)
 {
     notImplemented();
index c9c1f25856cc7bfd84fab721c77a1310e56cb9ec..d4878e2480117c9d5bedb425f283415b2e4c38b5 100644 (file)
@@ -44,9 +44,6 @@ public:
 private:
     virtual void contextMenuDestroyed() override;
 
-#if !USE(CROSS_PLATFORM_CONTEXT_MENUS)
-    virtual WebCore::PlatformMenuDescription getCustomMenuFromDefaultItems(WebCore::ContextMenu*) override;
-#endif
     virtual void contextMenuItemSelected(WebCore::ContextMenuItem*, const WebCore::ContextMenu*) override;
     
     virtual void downloadURL(const WebCore::URL&) override;