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

Unified Diff: android_webview/browser/child_frame.h

Issue 2480203002: ui: Cleanup class/struct forward declarations (Closed)
Patch Set: Sync CL to position 430550 Created 4 years, 1 month 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 | « android_webview/browser/browser_view_renderer.cc ('k') | android_webview/browser/child_frame.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/browser/child_frame.h
diff --git a/android_webview/browser/child_frame.h b/android_webview/browser/child_frame.h
index c0f9a71911ce06e02a06d6b38ad07bb7b6bc4d8f..13ce37960904357ae130be264634120ca8738fd2 100644
--- a/android_webview/browser/child_frame.h
+++ b/android_webview/browser/child_frame.h
@@ -9,6 +9,7 @@
#include "android_webview/browser/compositor_id.h"
#include "base/macros.h"
+#include "content/public/browser/android/synchronous_compositor.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/gfx/geometry/size.h"
#include "ui/gfx/transform.h"
@@ -21,15 +22,23 @@ namespace android_webview {
class ChildFrame {
public:
- ChildFrame(uint32_t compositor_frame_sink_id,
- std::unique_ptr<cc::CompositorFrame> frame,
- const CompositorID& compositor_id,
- bool viewport_rect_for_tile_priority_empty,
- const gfx::Transform& transform_for_tile_priority,
- bool offscreen_pre_raster,
- bool is_layer);
+ ChildFrame(
+ scoped_refptr<content::SynchronousCompositor::FrameFuture> frame_future,
+ uint32_t compositor_frame_sink_id,
+ std::unique_ptr<cc::CompositorFrame> frame,
+ const CompositorID& compositor_id,
+ bool viewport_rect_for_tile_priority_empty,
+ const gfx::Transform& transform_for_tile_priority,
+ bool offscreen_pre_raster,
+ bool is_layer);
~ChildFrame();
+ // Helper to move frame from |frame_future| to |frame|.
+ void WaitOnFutureIfNeeded();
+
+ // This is used in async ondraw path. The frame is either in |frame_future|
+ // or |frame|. It's illegal if both are non-null.
+ scoped_refptr<content::SynchronousCompositor::FrameFuture> frame_future;
// These two fields are not const to make async path easier.
uint32_t compositor_frame_sink_id;
std::unique_ptr<cc::CompositorFrame> frame;
« no previous file with comments | « android_webview/browser/browser_view_renderer.cc ('k') | android_webview/browser/child_frame.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698