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

Side by Side Diff: content/browser/frame_host/interstitial_page_impl.cc

Issue 2751763002: Make USE_EXTERNAL_POPUP_MENU local to content. (Closed)
Patch Set: rebase Created 3 years, 9 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 | « content/browser/BUILD.gn ('k') | content/browser/frame_host/render_frame_host_impl.h » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "content/browser/frame_host/interstitial_page_impl.h" 5 #include "content/browser/frame_host/interstitial_page_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 15 matching lines...) Expand all
26 #include "content/browser/loader/resource_dispatcher_host_impl.h" 26 #include "content/browser/loader/resource_dispatcher_host_impl.h"
27 #include "content/browser/renderer_host/render_process_host_impl.h" 27 #include "content/browser/renderer_host/render_process_host_impl.h"
28 #include "content/browser/renderer_host/render_view_host_delegate_view.h" 28 #include "content/browser/renderer_host/render_view_host_delegate_view.h"
29 #include "content/browser/renderer_host/render_view_host_factory.h" 29 #include "content/browser/renderer_host/render_view_host_factory.h"
30 #include "content/browser/renderer_host/render_view_host_impl.h" 30 #include "content/browser/renderer_host/render_view_host_impl.h"
31 #include "content/browser/renderer_host/render_widget_host_view_base.h" 31 #include "content/browser/renderer_host/render_widget_host_view_base.h"
32 #include "content/browser/renderer_host/text_input_manager.h" 32 #include "content/browser/renderer_host/text_input_manager.h"
33 #include "content/browser/site_instance_impl.h" 33 #include "content/browser/site_instance_impl.h"
34 #include "content/browser/web_contents/web_contents_impl.h" 34 #include "content/browser/web_contents/web_contents_impl.h"
35 #include "content/browser/web_contents/web_contents_view.h" 35 #include "content/browser/web_contents/web_contents_view.h"
36 #include "content/common/features.h"
36 #include "content/common/frame_messages.h" 37 #include "content/common/frame_messages.h"
37 #include "content/common/input_messages.h" 38 #include "content/common/input_messages.h"
38 #include "content/common/view_messages.h" 39 #include "content/common/view_messages.h"
39 #include "content/public/browser/browser_context.h" 40 #include "content/public/browser/browser_context.h"
40 #include "content/public/browser/browser_thread.h" 41 #include "content/public/browser/browser_thread.h"
41 #include "content/public/browser/content_browser_client.h" 42 #include "content/public/browser/content_browser_client.h"
42 #include "content/public/browser/interstitial_page_delegate.h" 43 #include "content/public/browser/interstitial_page_delegate.h"
43 #include "content/public/browser/invalidate_type.h" 44 #include "content/public/browser/invalidate_type.h"
44 #include "content/public/browser/notification_service.h" 45 #include "content/public/browser/notification_service.h"
45 #include "content/public/browser/notification_source.h" 46 #include "content/public/browser/notification_source.h"
(...skipping 10 matching lines...) Expand all
56 using blink::WebDragOperationsMask; 57 using blink::WebDragOperationsMask;
57 58
58 namespace content { 59 namespace content {
59 60
60 class InterstitialPageImpl::InterstitialPageRVHDelegateView 61 class InterstitialPageImpl::InterstitialPageRVHDelegateView
61 : public RenderViewHostDelegateView { 62 : public RenderViewHostDelegateView {
62 public: 63 public:
63 explicit InterstitialPageRVHDelegateView(InterstitialPageImpl* page); 64 explicit InterstitialPageRVHDelegateView(InterstitialPageImpl* page);
64 65
65 // RenderViewHostDelegateView implementation: 66 // RenderViewHostDelegateView implementation:
66 #if defined(USE_EXTERNAL_POPUP_MENU) 67 #if BUILDFLAG(USE_EXTERNAL_POPUP_MENU)
67 void ShowPopupMenu(RenderFrameHost* render_frame_host, 68 void ShowPopupMenu(RenderFrameHost* render_frame_host,
68 const gfx::Rect& bounds, 69 const gfx::Rect& bounds,
69 int item_height, 70 int item_height,
70 double item_font_size, 71 double item_font_size,
71 int selected_item, 72 int selected_item,
72 const std::vector<MenuItem>& items, 73 const std::vector<MenuItem>& items,
73 bool right_aligned, 74 bool right_aligned,
74 bool allow_multiple_selection) override; 75 bool allow_multiple_selection) override;
75 void HidePopupMenu() override; 76 void HidePopupMenu() override;
76 #endif 77 #endif
(...skipping 795 matching lines...) Expand 10 before | Expand all | Expand 10 after
872 return; 873 return;
873 delegate_->CommandReceived(json_string); 874 delegate_->CommandReceived(json_string);
874 } 875 }
875 876
876 877
877 InterstitialPageImpl::InterstitialPageRVHDelegateView:: 878 InterstitialPageImpl::InterstitialPageRVHDelegateView::
878 InterstitialPageRVHDelegateView(InterstitialPageImpl* page) 879 InterstitialPageRVHDelegateView(InterstitialPageImpl* page)
879 : interstitial_page_(page) { 880 : interstitial_page_(page) {
880 } 881 }
881 882
882 #if defined(USE_EXTERNAL_POPUP_MENU) 883 #if BUILDFLAG(USE_EXTERNAL_POPUP_MENU)
883 void InterstitialPageImpl::InterstitialPageRVHDelegateView::ShowPopupMenu( 884 void InterstitialPageImpl::InterstitialPageRVHDelegateView::ShowPopupMenu(
884 RenderFrameHost* render_frame_host, 885 RenderFrameHost* render_frame_host,
885 const gfx::Rect& bounds, 886 const gfx::Rect& bounds,
886 int item_height, 887 int item_height,
887 double item_font_size, 888 double item_font_size,
888 int selected_item, 889 int selected_item,
889 const std::vector<MenuItem>& items, 890 const std::vector<MenuItem>& items,
890 bool right_aligned, 891 bool right_aligned,
891 bool allow_multiple_selection) { 892 bool allow_multiple_selection) {
892 NOTREACHED() << "InterstitialPage does not support showing popup menus."; 893 NOTREACHED() << "InterstitialPage does not support showing popup menus.";
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
971 void InterstitialPageImpl::UpdateDeviceScaleFactor(double device_scale_factor) { 972 void InterstitialPageImpl::UpdateDeviceScaleFactor(double device_scale_factor) {
972 WebContentsImpl* web_contents_impl = 973 WebContentsImpl* web_contents_impl =
973 static_cast<WebContentsImpl*>(web_contents_); 974 static_cast<WebContentsImpl*>(web_contents_);
974 if (!web_contents_impl) 975 if (!web_contents_impl)
975 return; 976 return;
976 977
977 web_contents_impl->UpdateDeviceScaleFactor(device_scale_factor); 978 web_contents_impl->UpdateDeviceScaleFactor(device_scale_factor);
978 } 979 }
979 980
980 } // namespace content 981 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/browser/frame_host/render_frame_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698