Chromium Code Reviews| 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 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 218 void RequestContentClipping(const gfx::Rect& clipping, | 218 void RequestContentClipping(const gfx::Rect& clipping, |
| 219 const gfx::Size& content_size); | 219 const gfx::Size& content_size); |
| 220 | 220 |
| 221 // Returns true when animation ticks are still needed. This avoids a separate | 221 // Returns true when animation ticks are still needed. This avoids a separate |
| 222 // round-trip for requesting follow-up animation. | 222 // round-trip for requesting follow-up animation. |
| 223 bool Animate(base::TimeTicks frame_time); | 223 bool Animate(base::TimeTicks frame_time); |
| 224 | 224 |
| 225 void SynchronousFrameMetadata( | 225 void SynchronousFrameMetadata( |
| 226 const cc::CompositorFrameMetadata& frame_metadata); | 226 const cc::CompositorFrameMetadata& frame_metadata); |
| 227 | 227 |
| 228 private: | 228 private: |
|
kochi
2013/07/08 04:28:43
nit: not necessary to remove a space.
nyquist
2013/07/09 07:47:36
Done.
| |
| 229 void BuffersSwapped(const gpu::Mailbox& mailbox, | 229 void BuffersSwapped(const gpu::Mailbox& mailbox, |
| 230 const base::Closure& ack_callback); | 230 const base::Closure& ack_callback); |
| 231 | 231 |
| 232 void RunAckCallbacks(); | 232 void RunAckCallbacks(); |
| 233 | 233 |
| 234 void SwapDelegatedFrame(scoped_ptr<cc::DelegatedFrameData> frame_data); | 234 void SwapDelegatedFrame(scoped_ptr<cc::DelegatedFrameData> frame_data); |
| 235 void SendDelegatedFrameAck(); | 235 void SendDelegatedFrameAck(); |
| 236 | 236 |
| 237 void UpdateContentViewCoreFrameMetadata( | 237 void UpdateContentViewCoreFrameMetadata( |
| 238 const cc::CompositorFrameMetadata& frame_metadata); | 238 const cc::CompositorFrameMetadata& frame_metadata); |
| 239 void ComputeContentsSize(const cc::CompositorFrameMetadata& frame_metadata); | 239 void ComputeContentsSize(const cc::CompositorFrameMetadata& frame_metadata); |
| 240 void ResetClipping(); | 240 void ResetClipping(); |
| 241 void ClipContents(const gfx::Rect& clipping, const gfx::Size& content_size); | 241 void ClipContents(const gfx::Rect& clipping, const gfx::Size& content_size); |
| 242 | 242 |
| 243 void AttachLayers(); | 243 void AttachLayers(); |
| 244 void RemoveLayers(); | 244 void RemoveLayers(); |
| 245 | 245 |
| 246 void CreateOverscrollEffectIfNecessary(); | 246 void CreateOverscrollEffectIfNecessary(); |
| 247 void UpdateAnimationSize(const cc::CompositorFrameMetadata& frame_metadata); | 247 void UpdateAnimationSize(const cc::CompositorFrameMetadata& frame_metadata); |
| 248 void ScheduleAnimationIfNecessary(); | 248 void ScheduleAnimationIfNecessary(); |
| 249 | 249 |
| 250 // Returns whether strict IME processing has been enabled. | |
| 251 bool has_strict_ime_processing() { return strict_ime_processing_; } | |
|
kochi
2013/07/08 04:28:43
Usually we use the same name for a simple accessor
nyquist
2013/07/09 07:47:36
Done.
| |
| 252 | |
| 250 // The model object. | 253 // The model object. |
| 251 RenderWidgetHostImpl* host_; | 254 RenderWidgetHostImpl* host_; |
| 252 | 255 |
| 253 // Used to track whether this render widget needs a BeginFrame. | 256 // Used to track whether this render widget needs a BeginFrame. |
| 254 bool needs_begin_frame_; | 257 bool needs_begin_frame_; |
| 255 | 258 |
| 256 // Whether or not this widget is potentially attached to the view hierarchy. | 259 // Whether or not this widget is potentially attached to the view hierarchy. |
| 257 // This view may not actually be attached if this is true, but it should be | 260 // This view may not actually be attached if this is true, but it should be |
| 258 // treated as such, because as soon as a ContentViewCore is set the layer | 261 // treated as such, because as soon as a ContentViewCore is set the layer |
| 259 // will be attached automatically. | 262 // will be attached automatically. |
| 260 bool are_layers_attached_; | 263 bool are_layers_attached_; |
| 261 | 264 |
| 262 // ContentViewCoreImpl is our interface to the view system. | 265 // ContentViewCoreImpl is our interface to the view system. |
| 263 ContentViewCoreImpl* content_view_core_; | 266 ContentViewCoreImpl* content_view_core_; |
| 264 | 267 |
| 265 ImeAdapterAndroid ime_adapter_android_; | 268 ImeAdapterAndroid ime_adapter_android_; |
| 266 | 269 |
| 270 // Specifies if the strict IME processing has been enabled. | |
| 271 bool strict_ime_processing_; | |
| 272 | |
| 267 // Body background color of the underlying document. | 273 // Body background color of the underlying document. |
| 268 SkColor cached_background_color_; | 274 SkColor cached_background_color_; |
| 269 | 275 |
| 270 // The texture layer for this view when using browser-side compositing. | 276 // The texture layer for this view when using browser-side compositing. |
| 271 scoped_refptr<cc::TextureLayer> texture_layer_; | 277 scoped_refptr<cc::TextureLayer> texture_layer_; |
| 272 | 278 |
| 273 scoped_refptr<cc::DelegatedRendererLayer> delegated_renderer_layer_; | 279 scoped_refptr<cc::DelegatedRendererLayer> delegated_renderer_layer_; |
| 274 | 280 |
| 275 // The layer used for rendering the contents of this view. | 281 // The layer used for rendering the contents of this view. |
| 276 // It is either owned by texture_layer_ or surface_texture_transport_ | 282 // It is either owned by texture_layer_ or surface_texture_transport_ |
| (...skipping 22 matching lines...) Expand all Loading... | |
| 299 // Used to render overscroll overlays. | 305 // Used to render overscroll overlays. |
| 300 bool overscroll_effect_enabled_; | 306 bool overscroll_effect_enabled_; |
| 301 scoped_ptr<OverscrollGlow> overscroll_effect_; | 307 scoped_ptr<OverscrollGlow> overscroll_effect_; |
| 302 | 308 |
| 303 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); | 309 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); |
| 304 }; | 310 }; |
| 305 | 311 |
| 306 } // namespace content | 312 } // namespace content |
| 307 | 313 |
| 308 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ | 314 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ |
| OLD | NEW |