Index: content/browser/renderer_host/render_widget_host_view_aura.h |
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.h b/content/browser/renderer_host/render_widget_host_view_aura.h |
index c418b50a2da96acb88cf7b4aa27e818c419e260b..64541f0d18cc97b2c2b7cfd2653c79b1e7b59866 100644 |
--- a/content/browser/renderer_host/render_widget_host_view_aura.h |
+++ b/content/browser/renderer_host/render_widget_host_view_aura.h |
@@ -28,6 +28,7 @@ |
#include "ui/aura/client/focus_change_observer.h" |
#include "ui/aura/window_delegate.h" |
#include "ui/aura/window_tree_host_observer.h" |
+#include "ui/base/compositor/begin_frame_manager.h" |
#include "ui/base/ime/text_input_client.h" |
#include "ui/gfx/display_observer.h" |
#include "ui/gfx/insets.h" |
@@ -88,6 +89,7 @@ class CONTENT_EXPORT RenderWidgetHostViewAura |
public aura::client::ActivationChangeObserver, |
public aura::client::FocusChangeObserver, |
public aura::client::CursorClientObserver, |
+ public ui::BeginFrameManager::Observer, |
brianderson
2014/08/21 00:14:00
Is the plan to land this first as Aura-only and th
simonhong
2014/08/26 08:24:48
I'll implement mac and android also in this CL,
th
|
public base::SupportsWeakPtr<RenderWidgetHostViewAura> { |
public: |
// Displays and controls touch editing elements such as selection handles. |
@@ -150,6 +152,7 @@ class CONTENT_EXPORT RenderWidgetHostViewAura |
virtual void SetInsets(const gfx::Insets& insets) OVERRIDE; |
// Overridden from RenderWidgetHostViewBase: |
+ virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; |
virtual void InitAsPopup(RenderWidgetHostView* parent_host_view, |
const gfx::Rect& pos) OVERRIDE; |
virtual void InitAsFullscreen( |
@@ -319,6 +322,9 @@ class CONTENT_EXPORT RenderWidgetHostViewAura |
virtual void OnHostMoved(const aura::WindowTreeHost* host, |
const gfx::Point& new_origin) OVERRIDE; |
+ // Overridden from ui::BeginFrameManager::Observer: |
+ virtual void OnSendBeginFrame(const cc::BeginFrameArgs& args) OVERRIDE; |
+ |
#if defined(OS_WIN) |
// Sets the cutout rects from constrained windows. These are rectangles that |
// windowed NPAPI plugins shouldn't paint in. Overwrites any previous cutout |
@@ -346,6 +352,9 @@ class CONTENT_EXPORT RenderWidgetHostViewAura |
return overscroll_controller_.get(); |
} |
+ // Request next BeginFrame to compositor. |
+ void RequestBeginFrame() const; |
+ |
protected: |
virtual ~RenderWidgetHostViewAura(); |
@@ -463,6 +472,8 @@ class CONTENT_EXPORT RenderWidgetHostViewAura |
// Helper function to set keyboard focus to the main window. |
void SetKeyboardFocus(); |
+ void OnSetNeedsBeginFrame(bool enabled); |
+ |
RenderFrameHostImpl* GetFocusedFrame(); |
// The model object. |
@@ -596,6 +607,9 @@ class CONTENT_EXPORT RenderWidgetHostViewAura |
TouchEditingClient* touch_editing_client_; |
+ // true when RenderWidget needs a BeginFrame. |
+ bool needs_begin_frame_; |
+ |
scoped_ptr<OverscrollController> overscroll_controller_; |
gfx::Insets insets_; |