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> | 8 #include <map> |
9 #include <queue> | 9 #include <queue> |
10 | 10 |
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
217 void OnSetNeedsBeginFrame(bool enabled); | 217 void OnSetNeedsBeginFrame(bool enabled); |
218 void OnSmartClipDataExtracted(const base::string16& result); | 218 void OnSmartClipDataExtracted(const base::string16& result); |
219 | 219 |
220 void LockResources(); | 220 void LockResources(); |
221 void UnlockResources(); | 221 void UnlockResources(); |
222 | 222 |
223 int GetNativeImeAdapter(); | 223 int GetNativeImeAdapter(); |
224 | 224 |
225 void WasResized(); | 225 void WasResized(); |
226 | 226 |
227 void GetScaledContentBitmap( | 227 blink::WebGLId GetScaledContentTexture(float scale, gfx::Size* out_size); |
228 float scale, | |
229 gfx::Size* out_size, | |
230 const base::Callback<void(bool, const SkBitmap&)>& result_callback); | |
231 bool PopulateBitmapWithContents(jobject jbitmap); | 228 bool PopulateBitmapWithContents(jobject jbitmap); |
232 | 229 |
233 bool HasValidFrame() const; | 230 bool HasValidFrame() const; |
234 | 231 |
235 // Select all text between the given coordinates. | 232 // Select all text between the given coordinates. |
236 void SelectRange(const gfx::Point& start, const gfx::Point& end); | 233 void SelectRange(const gfx::Point& start, const gfx::Point& end); |
237 | 234 |
238 void MoveCaret(const gfx::Point& point); | 235 void MoveCaret(const gfx::Point& point); |
239 | 236 |
240 void RequestContentClipping(const gfx::Rect& clipping, | 237 void RequestContentClipping(const gfx::Rect& clipping, |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
292 const gfx::Rect& src_subrect_in_pixel, | 289 const gfx::Rect& src_subrect_in_pixel, |
293 const gfx::Size& dst_size_in_pixel, | 290 const gfx::Size& dst_size_in_pixel, |
294 const base::Callback<void(bool, const SkBitmap&)>& callback); | 291 const base::Callback<void(bool, const SkBitmap&)>& callback); |
295 | 292 |
296 // The model object. | 293 // The model object. |
297 RenderWidgetHostImpl* host_; | 294 RenderWidgetHostImpl* host_; |
298 | 295 |
299 // Used to track whether this render widget needs a BeginFrame. | 296 // Used to track whether this render widget needs a BeginFrame. |
300 bool needs_begin_frame_; | 297 bool needs_begin_frame_; |
301 | 298 |
302 bool is_showing_; | 299 // Whether or not this widget is potentially attached to the view hierarchy. |
| 300 // This view may not actually be attached if this is true, but it should be |
| 301 // treated as such, because as soon as a ContentViewCore is set the layer |
| 302 // will be attached automatically. |
| 303 bool are_layers_attached_; |
303 | 304 |
304 // ContentViewCoreImpl is our interface to the view system. | 305 // ContentViewCoreImpl is our interface to the view system. |
305 ContentViewCoreImpl* content_view_core_; | 306 ContentViewCoreImpl* content_view_core_; |
306 | 307 |
307 ImeAdapterAndroid ime_adapter_android_; | 308 ImeAdapterAndroid ime_adapter_android_; |
308 | 309 |
309 // Body background color of the underlying document. | 310 // Body background color of the underlying document. |
310 SkColor cached_background_color_; | 311 SkColor cached_background_color_; |
311 | 312 |
312 // The texture layer for this view when using browser-side compositing. | 313 // The texture layer for this view when using browser-side compositing. |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
355 const bool using_synchronous_compositor_; | 356 const bool using_synchronous_compositor_; |
356 | 357 |
357 scoped_ptr<DelegatedFrameEvictor> frame_evictor_; | 358 scoped_ptr<DelegatedFrameEvictor> frame_evictor_; |
358 | 359 |
359 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); | 360 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); |
360 }; | 361 }; |
361 | 362 |
362 } // namespace content | 363 } // namespace content |
363 | 364 |
364 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ | 365 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ |
OLD | NEW |