OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 | 5 |
6 #include "chrome/browser/guest_view/web_view/chrome_web_view_guest_delegate.h" | 6 #include "chrome/browser/guest_view/web_view/chrome_web_view_guest_delegate.h" |
7 | 7 |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 #include "extensions/browser/api/web_request/web_request_api.h" | 23 #include "extensions/browser/api/web_request/web_request_api.h" |
24 #include "extensions/browser/guest_view/web_view/web_view_constants.h" | 24 #include "extensions/browser/guest_view/web_view/web_view_constants.h" |
25 | 25 |
26 using guest_view::GuestViewEvent; | 26 using guest_view::GuestViewEvent; |
27 | 27 |
28 namespace extensions { | 28 namespace extensions { |
29 | 29 |
30 ChromeWebViewGuestDelegate::ChromeWebViewGuestDelegate( | 30 ChromeWebViewGuestDelegate::ChromeWebViewGuestDelegate( |
31 WebViewGuest* web_view_guest) | 31 WebViewGuest* web_view_guest) |
32 : pending_context_menu_request_id_(0), | 32 : pending_context_menu_request_id_(0), |
33 chromevox_injected_(false), | |
34 web_view_guest_(web_view_guest), | 33 web_view_guest_(web_view_guest), |
35 weak_ptr_factory_(this) { | 34 weak_ptr_factory_(this) { |
36 } | 35 } |
37 | 36 |
38 ChromeWebViewGuestDelegate::~ChromeWebViewGuestDelegate() { | 37 ChromeWebViewGuestDelegate::~ChromeWebViewGuestDelegate() { |
39 } | 38 } |
40 | 39 |
41 bool ChromeWebViewGuestDelegate::HandleContextMenu( | 40 bool ChromeWebViewGuestDelegate::HandleContextMenu( |
42 const content::ContextMenuParams& params) { | 41 const content::ContextMenuParams& params) { |
43 ContextMenuDelegate* menu_delegate = | 42 ContextMenuDelegate* menu_delegate = |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 | 157 |
159 void ChromeWebViewGuestDelegate::SetContextMenuPosition( | 158 void ChromeWebViewGuestDelegate::SetContextMenuPosition( |
160 const gfx::Point& position) { | 159 const gfx::Point& position) { |
161 if (context_menu_position_ == nullptr) | 160 if (context_menu_position_ == nullptr) |
162 context_menu_position_.reset(new gfx::Point()); | 161 context_menu_position_.reset(new gfx::Point()); |
163 | 162 |
164 *context_menu_position_ = position; | 163 *context_menu_position_ = position; |
165 } | 164 } |
166 | 165 |
167 } // namespace extensions | 166 } // namespace extensions |
OLD | NEW |