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

Side by Side Diff: content/browser/renderer_host/compositor_impl_android.h

Issue 599103008: Android: remove deprecated content API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/public/browser/android/compositor.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/cancelable_callback.h" 9 #include "base/cancelable_callback.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 static int CreateSurfaceTexture(int child_process_id); 54 static int CreateSurfaceTexture(int child_process_id);
55 55
56 // Destroy all surface textures associated with |child_process_id|. 56 // Destroy all surface textures associated with |child_process_id|.
57 static void DestroyAllSurfaceTextures(int child_process_id); 57 static void DestroyAllSurfaceTextures(int child_process_id);
58 58
59 void PopulateGpuCapabilities(gpu::Capabilities gpu_capabilities); 59 void PopulateGpuCapabilities(gpu::Capabilities gpu_capabilities);
60 60
61 private: 61 private:
62 // Compositor implementation. 62 // Compositor implementation.
63 virtual void SetRootLayer(scoped_refptr<cc::Layer> root) OVERRIDE; 63 virtual void SetRootLayer(scoped_refptr<cc::Layer> root) OVERRIDE;
64 virtual void SetWindowSurface(ANativeWindow* window) OVERRIDE;
65 virtual void SetSurface(jobject surface) OVERRIDE; 64 virtual void SetSurface(jobject surface) OVERRIDE;
66 virtual void SetVisible(bool visible) OVERRIDE; 65 virtual void SetVisible(bool visible) OVERRIDE;
67 virtual void setDeviceScaleFactor(float factor) OVERRIDE; 66 virtual void setDeviceScaleFactor(float factor) OVERRIDE;
68 virtual void SetWindowBounds(const gfx::Size& size) OVERRIDE; 67 virtual void SetWindowBounds(const gfx::Size& size) OVERRIDE;
69 virtual void SetHasTransparentBackground(bool flag) OVERRIDE; 68 virtual void SetHasTransparentBackground(bool flag) OVERRIDE;
70 virtual void SetNeedsComposite() OVERRIDE; 69 virtual void SetNeedsComposite() OVERRIDE;
71 virtual UIResourceProvider& GetUIResourceProvider() OVERRIDE; 70 virtual UIResourceProvider& GetUIResourceProvider() OVERRIDE;
72 71
73 // LayerTreeHostClient implementation. 72 // LayerTreeHostClient implementation.
74 virtual void WillBeginMainFrame(int frame_id) OVERRIDE {} 73 virtual void WillBeginMainFrame(int frame_id) OVERRIDE {}
(...skipping 23 matching lines...) Expand all
98 97
99 // WindowAndroidCompositor implementation. 98 // WindowAndroidCompositor implementation.
100 virtual void AttachLayerForReadback(scoped_refptr<cc::Layer> layer) OVERRIDE; 99 virtual void AttachLayerForReadback(scoped_refptr<cc::Layer> layer) OVERRIDE;
101 virtual void RequestCopyOfOutputOnRootLayer( 100 virtual void RequestCopyOfOutputOnRootLayer(
102 scoped_ptr<cc::CopyOutputRequest> request) OVERRIDE; 101 scoped_ptr<cc::CopyOutputRequest> request) OVERRIDE;
103 virtual void OnVSync(base::TimeTicks frame_time, 102 virtual void OnVSync(base::TimeTicks frame_time,
104 base::TimeDelta vsync_period) OVERRIDE; 103 base::TimeDelta vsync_period) OVERRIDE;
105 virtual void SetNeedsAnimate() OVERRIDE; 104 virtual void SetNeedsAnimate() OVERRIDE;
106 virtual ui::SystemUIResourceManager& GetSystemUIResourceManager() OVERRIDE; 105 virtual ui::SystemUIResourceManager& GetSystemUIResourceManager() OVERRIDE;
107 106
107 void SetWindowSurface(ANativeWindow* window);
108
108 enum CompositingTrigger { 109 enum CompositingTrigger {
109 DO_NOT_COMPOSITE, 110 DO_NOT_COMPOSITE,
110 COMPOSITE_IMMEDIATELY, 111 COMPOSITE_IMMEDIATELY,
111 COMPOSITE_EVENTUALLY, 112 COMPOSITE_EVENTUALLY,
112 }; 113 };
113 void PostComposite(CompositingTrigger trigger); 114 void PostComposite(CompositingTrigger trigger);
114 void Composite(CompositingTrigger trigger); 115 void Composite(CompositingTrigger trigger);
115 116
116 bool WillCompositeThisFrame() const { 117 bool WillCompositeThisFrame() const {
117 return current_composite_task_ && 118 return current_composite_task_ &&
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 base::TimeTicks last_vsync_; 186 base::TimeTicks last_vsync_;
186 187
187 base::WeakPtrFactory<CompositorImpl> weak_factory_; 188 base::WeakPtrFactory<CompositorImpl> weak_factory_;
188 189
189 DISALLOW_COPY_AND_ASSIGN(CompositorImpl); 190 DISALLOW_COPY_AND_ASSIGN(CompositorImpl);
190 }; 191 };
191 192
192 } // namespace content 193 } // namespace content
193 194
194 #endif // CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ 195 #endif // CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_
OLDNEW
« no previous file with comments | « no previous file | content/public/browser/android/compositor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698