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

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

Issue 1046783002: wip: Aura-specific implementation of unified touch selection: touch_selection (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Moving the responsibility for showing the menu into the client. Created 5 years, 8 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/browser/renderer_host/render_widget_host_view_android.cc » ('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_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 14 matching lines...) Expand all
25 #include "content/browser/renderer_host/render_widget_host_view_base.h" 25 #include "content/browser/renderer_host/render_widget_host_view_base.h"
26 #include "content/common/content_export.h" 26 #include "content/common/content_export.h"
27 #include "content/public/browser/readback_types.h" 27 #include "content/public/browser/readback_types.h"
28 #include "gpu/command_buffer/common/mailbox.h" 28 #include "gpu/command_buffer/common/mailbox.h"
29 #include "third_party/skia/include/core/SkColor.h" 29 #include "third_party/skia/include/core/SkColor.h"
30 #include "third_party/WebKit/public/platform/WebGraphicsContext3D.h" 30 #include "third_party/WebKit/public/platform/WebGraphicsContext3D.h"
31 #include "ui/android/window_android_observer.h" 31 #include "ui/android/window_android_observer.h"
32 #include "ui/events/gesture_detection/filtered_gesture_provider.h" 32 #include "ui/events/gesture_detection/filtered_gesture_provider.h"
33 #include "ui/gfx/geometry/size.h" 33 #include "ui/gfx/geometry/size.h"
34 #include "ui/gfx/geometry/vector2d_f.h" 34 #include "ui/gfx/geometry/vector2d_f.h"
35 #include "ui/touch_selection/touch_selection_controller.h" 35 #include "ui/touch_selection/touch_selection_controller_android.h"
36 36
37 struct ViewHostMsg_TextInputState_Params; 37 struct ViewHostMsg_TextInputState_Params;
38 38
39 namespace cc { 39 namespace cc {
40 class CopyOutputResult; 40 class CopyOutputResult;
41 class DelegatedFrameProvider; 41 class DelegatedFrameProvider;
42 class DelegatedRendererLayer; 42 class DelegatedRendererLayer;
43 class Layer; 43 class Layer;
44 class SurfaceFactory; 44 class SurfaceFactory;
45 class SurfaceIdAllocator; 45 class SurfaceIdAllocator;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 // See comments in render_widget_host_view.h about this class and its members. 84 // See comments in render_widget_host_view.h about this class and its members.
85 // ----------------------------------------------------------------------------- 85 // -----------------------------------------------------------------------------
86 class CONTENT_EXPORT RenderWidgetHostViewAndroid 86 class CONTENT_EXPORT RenderWidgetHostViewAndroid
87 : public RenderWidgetHostViewBase, 87 : public RenderWidgetHostViewBase,
88 public cc::DelegatedFrameResourceCollectionClient, 88 public cc::DelegatedFrameResourceCollectionClient,
89 public cc::SurfaceFactoryClient, 89 public cc::SurfaceFactoryClient,
90 public ui::GestureProviderClient, 90 public ui::GestureProviderClient,
91 public ui::WindowAndroidObserver, 91 public ui::WindowAndroidObserver,
92 public DelegatedFrameEvictorClient, 92 public DelegatedFrameEvictorClient,
93 public StylusTextSelectorClient, 93 public StylusTextSelectorClient,
94 public ui::TouchSelectionControllerClient { 94 public ui::TouchSelectionControllerAndroidClient {
95 public: 95 public:
96 RenderWidgetHostViewAndroid(RenderWidgetHostImpl* widget, 96 RenderWidgetHostViewAndroid(RenderWidgetHostImpl* widget,
97 ContentViewCoreImpl* content_view_core); 97 ContentViewCoreImpl* content_view_core);
98 ~RenderWidgetHostViewAndroid() override; 98 ~RenderWidgetHostViewAndroid() override;
99 99
100 // RenderWidgetHostView implementation. 100 // RenderWidgetHostView implementation.
101 bool OnMessageReceived(const IPC::Message& msg) override; 101 bool OnMessageReceived(const IPC::Message& msg) override;
102 void InitAsChild(gfx::NativeView parent_view) override; 102 void InitAsChild(gfx::NativeView parent_view) override;
103 void InitAsPopup(RenderWidgetHostView* parent_host_view, 103 void InitAsPopup(RenderWidgetHostView* parent_host_view,
104 const gfx::Rect& pos) override; 104 const gfx::Rect& pos) override;
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 void EvictDelegatedFrame() override; 206 void EvictDelegatedFrame() override;
207 207
208 SkColorType PreferredReadbackFormat() override; 208 SkColorType PreferredReadbackFormat() override;
209 209
210 // StylusTextSelectorClient implementation. 210 // StylusTextSelectorClient implementation.
211 void OnStylusSelectBegin(float x0, float y0, float x1, float y1) override; 211 void OnStylusSelectBegin(float x0, float y0, float x1, float y1) override;
212 void OnStylusSelectUpdate(float x, float y) override; 212 void OnStylusSelectUpdate(float x, float y) override;
213 void OnStylusSelectEnd() override; 213 void OnStylusSelectEnd() override;
214 void OnStylusSelectTap(base::TimeTicks time, float x, float y) override; 214 void OnStylusSelectTap(base::TimeTicks time, float x, float y) override;
215 215
216 // ui::TouchSelectionControllerClient implementation. 216 // ui::TouchSelectionControllerAndroidClient implementation.
217 bool SupportsAnimation() const override; 217 bool SupportsAnimation() const override;
218 void SetNeedsAnimate() override; 218 void SetNeedsAnimate() override;
219 void MoveCaret(const gfx::PointF& position) override; 219 void MoveCaret(const gfx::PointF& position) override;
220 void MoveRangeSelectionExtent(const gfx::PointF& extent) override; 220 void MoveRangeSelectionExtent(const gfx::PointF& extent) override;
221 void SelectBetweenCoordinates(const gfx::PointF& base, 221 void SelectBetweenCoordinates(const gfx::PointF& base,
222 const gfx::PointF& extent) override; 222 const gfx::PointF& extent) override;
223 void OnSelectionEvent(ui::SelectionEventType event, 223 void OnSelectionEvent(ui::SelectionEventType event,
224 const gfx::PointF& anchor_position) override; 224 const gfx::PointF& anchor_position) override;
225 scoped_ptr<ui::TouchHandleDrawable> CreateDrawable() override; 225 scoped_ptr<ui::TouchHandleDrawable> CreateDrawable() override;
226 226
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
393 393
394 // Provides gesture synthesis given a stream of touch events (derived from 394 // Provides gesture synthesis given a stream of touch events (derived from
395 // Android MotionEvent's) and touch event acks. 395 // Android MotionEvent's) and touch event acks.
396 ui::FilteredGestureProvider gesture_provider_; 396 ui::FilteredGestureProvider gesture_provider_;
397 397
398 // Handles gesture based text selection 398 // Handles gesture based text selection
399 StylusTextSelector stylus_text_selector_; 399 StylusTextSelector stylus_text_selector_;
400 400
401 // Manages selection handle rendering and manipulation. 401 // Manages selection handle rendering and manipulation.
402 // This will always be NULL if |content_view_core_| is NULL. 402 // This will always be NULL if |content_view_core_| is NULL.
403 scoped_ptr<ui::TouchSelectionController> selection_controller_; 403 scoped_ptr<ui::TouchSelectionControllerAndroid> selection_controller_;
404 404
405 int accelerated_surface_route_id_; 405 int accelerated_surface_route_id_;
406 406
407 // Size to use if we have no backing ContentViewCore 407 // Size to use if we have no backing ContentViewCore
408 gfx::Size default_size_; 408 gfx::Size default_size_;
409 409
410 const bool using_browser_compositor_; 410 const bool using_browser_compositor_;
411 411
412 scoped_ptr<DelegatedFrameEvictor> frame_evictor_; 412 scoped_ptr<DelegatedFrameEvictor> frame_evictor_;
413 413
(...skipping 19 matching lines...) Expand all
433 gfx::Vector2dF last_scroll_offset_; 433 gfx::Vector2dF last_scroll_offset_;
434 434
435 base::WeakPtrFactory<RenderWidgetHostViewAndroid> weak_ptr_factory_; 435 base::WeakPtrFactory<RenderWidgetHostViewAndroid> weak_ptr_factory_;
436 436
437 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); 437 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid);
438 }; 438 };
439 439
440 } // namespace content 440 } // namespace content
441 441
442 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ 442 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/renderer_host/render_widget_host_view_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698