| 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_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/renderer_host/render_widget_host_view_android_delegate
.h" |
| 12 #include "content/browser/web_contents/web_contents_view.h" | 13 #include "content/browser/web_contents/web_contents_view.h" |
| 13 #include "content/public/browser/web_contents_view_delegate.h" | 14 #include "content/public/browser/web_contents_view_delegate.h" |
| 14 #include "content/public/common/context_menu_params.h" | 15 #include "content/public/common/context_menu_params.h" |
| 15 #include "content/public/common/drop_data.h" | 16 #include "content/public/common/drop_data.h" |
| 16 #include "ui/android/view_android.h" | 17 #include "ui/android/view_android.h" |
| 17 #include "ui/gfx/geometry/rect_f.h" | 18 #include "ui/gfx/geometry/rect_f.h" |
| 18 | 19 |
| 19 namespace content { | 20 namespace content { |
| 20 class ContentViewCoreImpl; | 21 class ContentViewCoreImpl; |
| 21 class WebContentsImpl; | 22 class WebContentsImpl; |
| 22 | 23 |
| 24 class RenderWidgetHostViewAndroidDelegateImpl |
| 25 : public RenderWidgetHostViewAndroidDelegate { |
| 26 public: |
| 27 RenderWidgetHostViewAndroidDelegateImpl(WebContentsImpl* web_contents); |
| 28 bool ShowingInterstitialPage() override; |
| 29 scoped_refptr<DevToolsAgentHost> GetDevToolsAgentHost() override; |
| 30 |
| 31 private: |
| 32 WebContentsImpl* web_contents_; |
| 33 }; |
| 34 |
| 23 // Android-specific implementation of the WebContentsView. | 35 // Android-specific implementation of the WebContentsView. |
| 24 class WebContentsViewAndroid : public WebContentsView, | 36 class WebContentsViewAndroid : public WebContentsView, |
| 25 public RenderViewHostDelegateView { | 37 public RenderViewHostDelegateView { |
| 26 public: | 38 public: |
| 27 WebContentsViewAndroid(WebContentsImpl* web_contents, | 39 WebContentsViewAndroid(WebContentsImpl* web_contents, |
| 28 WebContentsViewDelegate* delegate); | 40 WebContentsViewDelegate* delegate); |
| 29 ~WebContentsViewAndroid() override; | 41 ~WebContentsViewAndroid() override; |
| 30 | 42 |
| 31 // Sets the interface to the view system. ContentViewCoreImpl is owned | 43 // Sets the interface to the view system. ContentViewCoreImpl is owned |
| 32 // by its Java ContentViewCore counterpart, whose lifetime is managed | 44 // by its Java ContentViewCore counterpart, whose lifetime is managed |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 | 114 |
| 103 // The native view associated with the contents of the web. | 115 // The native view associated with the contents of the web. |
| 104 ui::ViewAndroid view_; | 116 ui::ViewAndroid view_; |
| 105 | 117 |
| 106 DISALLOW_COPY_AND_ASSIGN(WebContentsViewAndroid); | 118 DISALLOW_COPY_AND_ASSIGN(WebContentsViewAndroid); |
| 107 }; | 119 }; |
| 108 | 120 |
| 109 } // namespace content | 121 } // namespace content |
| 110 | 122 |
| 111 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_ANDROID_H_ | 123 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_ANDROID_H_ |
| OLD | NEW |