Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2734)

Unified Diff: Source/web/WebPopupMenuImpl.h

Issue 132173005: Use compositor with select popups. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/web/WebPopupMenuImpl.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/WebPopupMenuImpl.h
diff --git a/Source/web/WebPopupMenuImpl.h b/Source/web/WebPopupMenuImpl.h
index 7a4594f3e8752c9f5e591b94d30b668f09f054ad..66219b5be5ed16160db5ea344cd4be56dbb667b7 100644
--- a/Source/web/WebPopupMenuImpl.h
+++ b/Source/web/WebPopupMenuImpl.h
@@ -33,6 +33,7 @@
#include "WebPopupMenu.h"
#include "platform/scroll/FramelessScrollViewClient.h"
+#include "public/platform/WebContentLayerClient.h"
#include "public/platform/WebPoint.h"
#include "public/platform/WebSize.h"
#include "wtf/OwnPtr.h"
@@ -49,17 +50,17 @@ class Widget;
}
namespace blink {
+class WebContentLayer;
class WebGestureEvent;
class WebKeyboardEvent;
+class WebLayerTreeView;
class WebMouseEvent;
class WebMouseWheelEvent;
class WebRange;
struct WebRect;
class WebTouchEvent;
-class WebPopupMenuImpl : public WebPopupMenu,
- public WebCore::FramelessScrollViewClient,
- public RefCounted<WebPopupMenuImpl> {
+class WebPopupMenuImpl : public WebPopupMenu, public WebCore::FramelessScrollViewClient, public WebContentLayerClient, public RefCounted<WebPopupMenuImpl> {
WTF_MAKE_FAST_ALLOCATED;
public:
// WebWidget functions:
@@ -70,6 +71,8 @@ public:
virtual void willEndLiveResize() OVERRIDE FINAL;
virtual void animate(double frameBeginTime) OVERRIDE FINAL;
virtual void layout() OVERRIDE FINAL;
+ virtual void enterForceCompositingMode(bool enable) OVERRIDE FINAL;
+ virtual void didExitCompositingMode() OVERRIDE FINAL;
virtual void paint(WebCanvas*, const WebRect&, PaintOptions = ReadbackFromCompositorIfAvailable) OVERRIDE FINAL;
virtual void themeChanged() OVERRIDE FINAL;
virtual bool handleInputEvent(const WebInputEvent&) OVERRIDE FINAL;
@@ -87,6 +90,10 @@ public:
virtual void setTextDirection(WebTextDirection) OVERRIDE FINAL;
virtual bool isAcceleratedCompositingActive() const OVERRIDE FINAL { return false; }
virtual bool isPopupMenu() const OVERRIDE FINAL { return true; }
+ virtual void willCloseLayerTreeView() OVERRIDE FINAL;
+
+ // WebContentLayerClient
+ virtual void paintContents(WebCanvas*, const WebRect& clip, bool canPaintLCDTest, WebFloatRect& opaque) OVERRIDE FINAL;
// WebPopupMenuImpl
void initialize(WebCore::FramelessScrollView* widget, const WebRect& bounds);
@@ -127,6 +134,10 @@ public:
WebWidgetClient* m_client;
WebSize m_size;
+ WebLayerTreeView* m_layerTreeView;
+ OwnPtr<WebContentLayer> m_rootLayer;
+ bool m_isAcceleratedCompositingActive;
+
WebPoint m_lastMousePosition;
// This is a non-owning ref. The popup will notify us via popupClosed()
« no previous file with comments | « no previous file | Source/web/WebPopupMenuImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698