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

Unified Diff: android_webview/browser/browser_view_renderer.h

Issue 1816283005: Move SharedRendererState ownership to AwContents (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: All tests passing Created 4 years, 9 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
Index: android_webview/browser/browser_view_renderer.h
diff --git a/android_webview/browser/browser_view_renderer.h b/android_webview/browser/browser_view_renderer.h
index 60ba7022ef9eca48189e86e11bcd656e018c85c4..71054677c3a8adbe1b61d31eb5c4fb8247086fac 100644
--- a/android_webview/browser/browser_view_renderer.h
+++ b/android_webview/browser/browser_view_renderer.h
@@ -15,6 +15,7 @@
#include "base/cancelable_callback.h"
#include "base/macros.h"
#include "base/trace_event/trace_event.h"
+#include "cc/resources/returned_resource.h"
boliu 2016/03/30 16:12:13 header not needed by BVR. Is it used by aw_content
Tobias Sargeant 2016/03/30 17:17:16 Removed. Was a leftover from when AwContents used
#include "content/public/browser/android/synchronous_compositor.h"
#include "content/public/browser/android/synchronous_compositor_client.h"
#include "skia/ext/refptr.h"
@@ -50,9 +51,7 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
~BrowserViewRenderer() override;
void RegisterWithWebContents(content::WebContents* web_contents);
-
- SharedRendererState* GetAwDrawGLViewContext();
- bool RequestDrawGL(bool wait_for_completion);
+ void SetSharedRendererState(SharedRendererState* shared_renderer_state);
// Called before either OnDrawHardware or OnDrawSoftware to set the view
// state of this frame. |scroll| is the view's current scroll offset.
@@ -97,10 +96,9 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
bool attached_to_window() const { return attached_to_window_; }
bool hardware_enabled() const { return hardware_enabled_; }
gfx::Size size() const { return size_; }
- void ReleaseHardware();
bool IsClientVisible() const;
- void TrimMemory(const int level, const bool visible);
+ void TrimMemory();
// SynchronousCompositorClient overrides.
void DidInitializeCompositor(
@@ -120,7 +118,7 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
const gfx::Vector2dF& latest_overscroll_delta,
const gfx::Vector2dF& current_fling_velocity) override;
- void UpdateParentDrawConstraints();
+ void UpdateParentDrawConstraints(const ParentCompositorDrawConstraints&);
void DetachFunctorFromView();
private:
@@ -144,9 +142,9 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
// view renderer's state.
std::string ToString() const;
- BrowserViewRendererClient* client_;
- SharedRendererState shared_renderer_state_;
- scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner_;
+ BrowserViewRendererClient* const client_;
+ const scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner_;
+ SharedRendererState* shared_renderer_state_;
bool disable_page_visibility_;
// The current compositor that's owned by the current RVH.
@@ -193,6 +191,8 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
uint32_t next_compositor_id_;
+ ParentCompositorDrawConstraints external_draw_constraints_;
+
DISALLOW_COPY_AND_ASSIGN(BrowserViewRenderer);
};
« no previous file with comments | « no previous file | android_webview/browser/browser_view_renderer.cc » ('j') | android_webview/browser/browser_view_renderer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698