| OLD | NEW |
| 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_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ |
| 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ |
| 7 | 7 |
| 8 #include <map> |
| 9 |
| 8 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| 9 #include "base/i18n/rtl.h" | 11 #include "base/i18n/rtl.h" |
| 10 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
| 11 #include "base/process.h" | 13 #include "base/process.h" |
| 12 #include "content/browser/renderer_host/ime_adapter_android.h" | 14 #include "content/browser/renderer_host/ime_adapter_android.h" |
| 13 #include "content/browser/renderer_host/render_widget_host_view_base.h" | 15 #include "content/browser/renderer_host/render_widget_host_view_base.h" |
| 14 #include "third_party/skia/include/core/SkColor.h" | 16 #include "third_party/skia/include/core/SkColor.h" |
| 15 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3
D.h" | 17 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3
D.h" |
| 16 #include "ui/gfx/size.h" | 18 #include "ui/gfx/size.h" |
| 17 | 19 |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 const gfx::Rect& end_rect, | 92 const gfx::Rect& end_rect, |
| 91 WebKit::WebTextDirection end_direction) OVERRIDE; | 93 WebKit::WebTextDirection end_direction) OVERRIDE; |
| 92 virtual void OnAcceleratedCompositingStateChange() OVERRIDE; | 94 virtual void OnAcceleratedCompositingStateChange() OVERRIDE; |
| 93 virtual void AcceleratedSurfaceBuffersSwapped( | 95 virtual void AcceleratedSurfaceBuffersSwapped( |
| 94 const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params, | 96 const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params, |
| 95 int gpu_host_id) OVERRIDE; | 97 int gpu_host_id) OVERRIDE; |
| 96 virtual void AcceleratedSurfacePostSubBuffer( | 98 virtual void AcceleratedSurfacePostSubBuffer( |
| 97 const GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params& params, | 99 const GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params& params, |
| 98 int gpu_host_id) OVERRIDE; | 100 int gpu_host_id) OVERRIDE; |
| 99 virtual void AcceleratedSurfaceSuspend() OVERRIDE; | 101 virtual void AcceleratedSurfaceSuspend() OVERRIDE; |
| 102 virtual void AcceleratedSurfaceNew( |
| 103 int32 width_in_pixel, |
| 104 int32 height_in_pixel, |
| 105 uint64 surface_id, |
| 106 const std::string& mailbox_name) OVERRIDE; |
| 107 virtual void AcceleratedSurfaceRelease(uint64 surface_id) OVERRIDE; |
| 100 virtual bool HasAcceleratedSurface(const gfx::Size& desired_size) OVERRIDE; | 108 virtual bool HasAcceleratedSurface(const gfx::Size& desired_size) OVERRIDE; |
| 101 virtual void SetBackground(const SkBitmap& background) OVERRIDE; | 109 virtual void SetBackground(const SkBitmap& background) OVERRIDE; |
| 102 virtual void CopyFromCompositingSurface( | 110 virtual void CopyFromCompositingSurface( |
| 103 const gfx::Rect& src_subrect, | 111 const gfx::Rect& src_subrect, |
| 104 const gfx::Size& dst_size, | 112 const gfx::Size& dst_size, |
| 105 const base::Callback<void(bool)>& callback, | 113 const base::Callback<void(bool)>& callback, |
| 106 skia::PlatformBitmap* output) OVERRIDE; | 114 skia::PlatformBitmap* output) OVERRIDE; |
| 107 virtual BackingStore* AllocBackingStore(const gfx::Size& size) OVERRIDE; | 115 virtual BackingStore* AllocBackingStore(const gfx::Size& size) OVERRIDE; |
| 108 virtual gfx::GLSurfaceHandle GetCompositingSurface() OVERRIDE; | 116 virtual gfx::GLSurfaceHandle GetCompositingSurface() OVERRIDE; |
| 109 virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE; | 117 virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE; |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 175 // The most recent texture size that was pushed to the texture layer. | 183 // The most recent texture size that was pushed to the texture layer. |
| 176 gfx::Size texture_size_in_layer_; | 184 gfx::Size texture_size_in_layer_; |
| 177 | 185 |
| 178 // The handle for the transport surface (between renderer and browser-side | 186 // The handle for the transport surface (between renderer and browser-side |
| 179 // compositor) for this view. | 187 // compositor) for this view. |
| 180 gfx::GLSurfaceHandle shared_surface_; | 188 gfx::GLSurfaceHandle shared_surface_; |
| 181 | 189 |
| 182 // Used for image transport when needing to share resources across threads. | 190 // Used for image transport when needing to share resources across threads. |
| 183 scoped_ptr<SurfaceTextureTransportClient> surface_texture_transport_; | 191 scoped_ptr<SurfaceTextureTransportClient> surface_texture_transport_; |
| 184 | 192 |
| 193 typedef std::map<uint64, std::string> MailboxMap; |
| 194 MailboxMap id_to_mailbox_; |
| 195 |
| 196 // The identifier of the previously received frame |
| 197 uint64 current_buffer_id_; |
| 198 |
| 185 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); | 199 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); |
| 186 }; | 200 }; |
| 187 | 201 |
| 188 } // namespace content | 202 } // namespace content |
| 189 | 203 |
| 190 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ | 204 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ |
| OLD | NEW |