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

Side by Side Diff: content/browser/web_contents/web_contents_view_android.h

Issue 2626723003: Revert "Introduce ViewRoot forwarding input/view events to native" (Closed)
Patch Set: Created 3 years, 11 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
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_WEB_CONTENTS_WEB_CONTENTS_VIEW_ANDROID_H_ 5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_ANDROID_H_
6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_ANDROID_H_ 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_ANDROID_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "content/browser/renderer_host/render_view_host_delegate_view.h" 11 #include "content/browser/renderer_host/render_view_host_delegate_view.h"
12 #include "content/browser/web_contents/web_contents_view.h" 12 #include "content/browser/web_contents/web_contents_view.h"
13 #include "content/public/browser/web_contents_view_delegate.h" 13 #include "content/public/browser/web_contents_view_delegate.h"
14 #include "content/public/common/context_menu_params.h" 14 #include "content/public/common/context_menu_params.h"
15 #include "content/public/common/drop_data.h" 15 #include "content/public/common/drop_data.h"
16 #include "ui/android/overscroll_refresh.h" 16 #include "ui/android/overscroll_refresh.h"
17 #include "ui/android/view_android.h" 17 #include "ui/android/view_android.h"
18 #include "ui/android/view_client.h"
19 #include "ui/gfx/geometry/rect_f.h" 18 #include "ui/gfx/geometry/rect_f.h"
20 19
21 namespace content { 20 namespace content {
22 class ContentViewCoreImpl; 21 class ContentViewCoreImpl;
23 class SynchronousCompositorClient; 22 class SynchronousCompositorClient;
24 class WebContentsImpl; 23 class WebContentsImpl;
25 24
26 // Android-specific implementation of the WebContentsView. 25 // Android-specific implementation of the WebContentsView.
27 class WebContentsViewAndroid : public WebContentsView, 26 class WebContentsViewAndroid : public WebContentsView,
28 public RenderViewHostDelegateView, 27 public RenderViewHostDelegateView {
29 public ui::ViewClient {
30 public: 28 public:
31 WebContentsViewAndroid(WebContentsImpl* web_contents, 29 WebContentsViewAndroid(WebContentsImpl* web_contents,
32 WebContentsViewDelegate* delegate); 30 WebContentsViewDelegate* delegate);
33 ~WebContentsViewAndroid() override; 31 ~WebContentsViewAndroid() override;
34 32
35 // Sets the interface to the view system. ContentViewCoreImpl is owned 33 // Sets the interface to the view system. ContentViewCoreImpl is owned
36 // by its Java ContentViewCore counterpart, whose lifetime is managed 34 // by its Java ContentViewCore counterpart, whose lifetime is managed
37 // by the UI frontend. 35 // by the UI frontend.
38 void SetContentViewCore(ContentViewCoreImpl* content_view_core); 36 void SetContentViewCore(ContentViewCoreImpl* content_view_core);
39 37
(...skipping 26 matching lines...) Expand all
66 RenderWidgetHostViewBase* CreateViewForWidget( 64 RenderWidgetHostViewBase* CreateViewForWidget(
67 RenderWidgetHost* render_widget_host, 65 RenderWidgetHost* render_widget_host,
68 bool is_guest_view_hack) override; 66 bool is_guest_view_hack) override;
69 RenderWidgetHostViewBase* CreateViewForPopupWidget( 67 RenderWidgetHostViewBase* CreateViewForPopupWidget(
70 RenderWidgetHost* render_widget_host) override; 68 RenderWidgetHost* render_widget_host) override;
71 void SetPageTitle(const base::string16& title) override; 69 void SetPageTitle(const base::string16& title) override;
72 void RenderViewCreated(RenderViewHost* host) override; 70 void RenderViewCreated(RenderViewHost* host) override;
73 void RenderViewSwappedIn(RenderViewHost* host) override; 71 void RenderViewSwappedIn(RenderViewHost* host) override;
74 void SetOverscrollControllerEnabled(bool enabled) override; 72 void SetOverscrollControllerEnabled(bool enabled) override;
75 73
76 // ui::ViewClient implementation.
77 void OnPhysicalBackingSizeChanged(int width, int height) override;
78
79 // Backend implementation of RenderViewHostDelegateView. 74 // Backend implementation of RenderViewHostDelegateView.
80 void ShowContextMenu(RenderFrameHost* render_frame_host, 75 void ShowContextMenu(RenderFrameHost* render_frame_host,
81 const ContextMenuParams& params) override; 76 const ContextMenuParams& params) override;
82 void ShowPopupMenu(RenderFrameHost* render_frame_host, 77 void ShowPopupMenu(RenderFrameHost* render_frame_host,
83 const gfx::Rect& bounds, 78 const gfx::Rect& bounds,
84 int item_height, 79 int item_height,
85 double item_font_size, 80 double item_font_size,
86 int selected_item, 81 int selected_item,
87 const std::vector<MenuItem>& items, 82 const std::vector<MenuItem>& items,
88 bool right_aligned, 83 bool right_aligned,
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 123
129 // Interface used to get notified of events from the synchronous compositor. 124 // Interface used to get notified of events from the synchronous compositor.
130 SynchronousCompositorClient* synchronous_compositor_client_; 125 SynchronousCompositorClient* synchronous_compositor_client_;
131 126
132 DISALLOW_COPY_AND_ASSIGN(WebContentsViewAndroid); 127 DISALLOW_COPY_AND_ASSIGN(WebContentsViewAndroid);
133 }; 128 };
134 129
135 } // namespace content 130 } // namespace content
136 131
137 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_ANDROID_H_ 132 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_ANDROID_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698