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

Unified Diff: android_webview/browser/hardware_renderer_proxy.h

Issue 655813004: Part 1: Refactor Android WebView graphics code (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@refactor
Patch Set: rebase Created 6 years, 2 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/hardware_renderer_proxy.h
diff --git a/android_webview/browser/hardware_renderer_proxy.h b/android_webview/browser/hardware_renderer_proxy.h
new file mode 100644
index 0000000000000000000000000000000000000000..ee30c31581d1a4ad93413798961d6a826d5ed4cd
--- /dev/null
+++ b/android_webview/browser/hardware_renderer_proxy.h
@@ -0,0 +1,32 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef ANDROID_WEBVIEW_BROWSER_HARDWARE_RENDERER_PROXY_H_
+#define ANDROID_WEBVIEW_BROWSER_HARDWARE_RENDERER_PROXY_H_
+#include "android_webview/browser/parent_compositor_draw_constraints.h"
+#include "base/memory/scoped_ptr.h"
+#include "cc/output/compositor_frame.h"
+#include "cc/resources/returned_resource.h"
+#include "ui/gfx/geometry/vector2d_f.h"
+
+namespace android_webview {
+
+class HardwareRendererProxy {
boliu 2014/10/23 16:40:05 virtual destructor
+ public:
+ virtual gfx::Vector2d GetScrollOffset() = 0;
boliu 2014/10/23 16:40:05 nit, can we add OnRT to the end of all these funct
+ virtual scoped_ptr<cc::CompositorFrame> PassCompositorFrame() = 0;
+ // Returns true if the draw constraints are updated.
+ virtual bool SetParentCompositorDrawConstraints(
+ const ParentCompositorDrawConstraints& draw_constraints) = 0;
+ virtual void PostExternalDrawConstraintsToChildCompositor(
+ const ParentCompositorDrawConstraints& draw_constraints) = 0;
+ virtual void InsertReturnedResources(
+ const cc::ReturnedResourceArray& resources) = 0;
+ virtual void DidSkipCommitFrame() = 0;
+ virtual bool ForceCommit() const = 0;
+};
+
+} // namespace android_webview
+
+#endif // ANDROID_WEBVIEW_BROWSER_HARDWARE_RENDERER_PROXY_H_

Powered by Google App Engine
This is Rietveld 408576698