| 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 <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 void ClearCompositorFrame() override; | 155 void ClearCompositorFrame() override; |
| 156 void DidOverscroll(const DidOverscrollParams& params) override; | 156 void DidOverscroll(const DidOverscrollParams& params) override; |
| 157 void DidStopFlinging() override; | 157 void DidStopFlinging() override; |
| 158 uint32_t GetSurfaceClientId() override; | 158 uint32_t GetSurfaceClientId() override; |
| 159 void ShowDisambiguationPopup(const gfx::Rect& rect_pixels, | 159 void ShowDisambiguationPopup(const gfx::Rect& rect_pixels, |
| 160 const SkBitmap& zoomed_bitmap) override; | 160 const SkBitmap& zoomed_bitmap) override; |
| 161 std::unique_ptr<SyntheticGestureTarget> CreateSyntheticGestureTarget() | 161 std::unique_ptr<SyntheticGestureTarget> CreateSyntheticGestureTarget() |
| 162 override; | 162 override; |
| 163 void LockCompositingSurface() override; | 163 void LockCompositingSurface() override; |
| 164 void UnlockCompositingSurface() override; | 164 void UnlockCompositingSurface() override; |
| 165 void OnTextSurroundingSelectionResponse(const base::string16& content, | |
| 166 size_t start_offset, | |
| 167 size_t end_offset) override; | |
| 168 void OnDidNavigateMainFrameToNewPage() override; | 165 void OnDidNavigateMainFrameToNewPage() override; |
| 169 | 166 |
| 170 // cc::SurfaceFactoryClient implementation. | 167 // cc::SurfaceFactoryClient implementation. |
| 171 void ReturnResources(const cc::ReturnedResourceArray& resources) override; | 168 void ReturnResources(const cc::ReturnedResourceArray& resources) override; |
| 172 void SetBeginFrameSource(cc::BeginFrameSource* begin_frame_source) override; | 169 void SetBeginFrameSource(cc::BeginFrameSource* begin_frame_source) override; |
| 173 | 170 |
| 174 // ui::GestureProviderClient implementation. | 171 // ui::GestureProviderClient implementation. |
| 175 void OnGestureEvent(const ui::GestureEventData& gesture) override; | 172 void OnGestureEvent(const ui::GestureEventData& gesture) override; |
| 176 | 173 |
| 177 // ui::WindowAndroidObserver implementation. | 174 // ui::WindowAndroidObserver implementation. |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 243 void MoveCaret(const gfx::Point& point); | 240 void MoveCaret(const gfx::Point& point); |
| 244 void DismissTextHandles(); | 241 void DismissTextHandles(); |
| 245 void SetTextHandlesTemporarilyHidden(bool hidden); | 242 void SetTextHandlesTemporarilyHidden(bool hidden); |
| 246 void OnShowingPastePopup(const gfx::PointF& point); | 243 void OnShowingPastePopup(const gfx::PointF& point); |
| 247 void OnShowUnhandledTapUIIfNeeded(int x_dip, int y_dip); | 244 void OnShowUnhandledTapUIIfNeeded(int x_dip, int y_dip); |
| 248 | 245 |
| 249 void SynchronousFrameMetadata(cc::CompositorFrameMetadata frame_metadata); | 246 void SynchronousFrameMetadata(cc::CompositorFrameMetadata frame_metadata); |
| 250 | 247 |
| 251 void SetOverlayVideoMode(bool enabled); | 248 void SetOverlayVideoMode(bool enabled); |
| 252 | 249 |
| 253 typedef base::Callback< | |
| 254 void(const base::string16& content, int start_offset, int end_offset)> | |
| 255 TextSurroundingSelectionCallback; | |
| 256 void SetTextSurroundingSelectionCallback( | |
| 257 const TextSurroundingSelectionCallback& callback); | |
| 258 | |
| 259 static void OnContextLost(); | 250 static void OnContextLost(); |
| 260 | 251 |
| 261 private: | 252 private: |
| 262 void RunAckCallbacks(cc::SurfaceDrawStatus status); | 253 void RunAckCallbacks(cc::SurfaceDrawStatus status); |
| 263 | 254 |
| 264 void DestroyDelegatedContent(); | 255 void DestroyDelegatedContent(); |
| 265 void CheckOutputSurfaceChanged(uint32_t output_surface_id); | 256 void CheckOutputSurfaceChanged(uint32_t output_surface_id); |
| 266 void SubmitCompositorFrame(cc::CompositorFrame frame_data); | 257 void SubmitCompositorFrame(cc::CompositorFrame frame_data); |
| 267 void SendReclaimCompositorResources(uint32_t output_surface_id, | 258 void SendReclaimCompositorResources(uint32_t output_surface_id, |
| 268 bool is_swap_ack); | 259 bool is_swap_ack); |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 388 | 379 |
| 389 struct LastFrameInfo { | 380 struct LastFrameInfo { |
| 390 LastFrameInfo(uint32_t output_id, cc::CompositorFrame output_frame); | 381 LastFrameInfo(uint32_t output_id, cc::CompositorFrame output_frame); |
| 391 ~LastFrameInfo(); | 382 ~LastFrameInfo(); |
| 392 uint32_t output_surface_id; | 383 uint32_t output_surface_id; |
| 393 cc::CompositorFrame frame; | 384 cc::CompositorFrame frame; |
| 394 }; | 385 }; |
| 395 | 386 |
| 396 std::unique_ptr<LastFrameInfo> last_frame_info_; | 387 std::unique_ptr<LastFrameInfo> last_frame_info_; |
| 397 | 388 |
| 398 TextSurroundingSelectionCallback text_surrounding_selection_callback_; | |
| 399 | |
| 400 // The last scroll offset of the view. | 389 // The last scroll offset of the view. |
| 401 gfx::Vector2dF last_scroll_offset_; | 390 gfx::Vector2dF last_scroll_offset_; |
| 402 | 391 |
| 403 base::WeakPtrFactory<RenderWidgetHostViewAndroid> weak_ptr_factory_; | 392 base::WeakPtrFactory<RenderWidgetHostViewAndroid> weak_ptr_factory_; |
| 404 | 393 |
| 405 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); | 394 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); |
| 406 }; | 395 }; |
| 407 | 396 |
| 408 } // namespace content | 397 } // namespace content |
| 409 | 398 |
| 410 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ | 399 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ |
| OLD | NEW |