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

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

Issue 12252016: Prevented connecting drag drop events to a SwappedOut RenderViewHost in WebContentsViewGtk (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Use RenderViewSwappedIn to ensure we have a drag dest Created 7 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
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 #include "content/browser/web_contents/web_contents_view_android.h" 5 #include "content/browser/web_contents/web_contents_view_android.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "content/browser/android/content_view_core_impl.h" 8 #include "content/browser/android/content_view_core_impl.h"
9 #include "content/browser/android/media_player_manager_android.h" 9 #include "content/browser/android/media_player_manager_android.h"
10 #include "content/browser/renderer_host/render_widget_host_view_android.h" 10 #include "content/browser/renderer_host/render_widget_host_view_android.h"
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 } 156 }
157 157
158 RenderWidgetHostView* WebContentsViewAndroid::CreateViewForPopupWidget( 158 RenderWidgetHostView* WebContentsViewAndroid::CreateViewForPopupWidget(
159 RenderWidgetHost* render_widget_host) { 159 RenderWidgetHost* render_widget_host) {
160 return RenderWidgetHostViewPort::CreateViewForWidget(render_widget_host); 160 return RenderWidgetHostViewPort::CreateViewForWidget(render_widget_host);
161 } 161 }
162 162
163 void WebContentsViewAndroid::RenderViewCreated(RenderViewHost* host) { 163 void WebContentsViewAndroid::RenderViewCreated(RenderViewHost* host) {
164 } 164 }
165 165
166 void WebContentsViewAndroid::RenderViewSwappedIn(RenderViewHost* host) { 166 void WebContentsViewAndroid::RenderViewSwappedIn(RenderViewHost* new_host,
167 RenderViewHost* old_host) {
167 } 168 }
168 169
169 void WebContentsViewAndroid::ShowContextMenu( 170 void WebContentsViewAndroid::ShowContextMenu(
170 const ContextMenuParams& params, 171 const ContextMenuParams& params,
171 ContextMenuSourceType type) { 172 ContextMenuSourceType type) {
172 if (delegate_.get()) 173 if (delegate_.get())
173 delegate_->ShowContextMenu(params, type); 174 delegate_->ShowContextMenu(params, type);
174 } 175 }
175 176
176 void WebContentsViewAndroid::ShowPopupMenu( 177 void WebContentsViewAndroid::ShowPopupMenu(
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 // This is called when we the renderer asks us to take focus back (i.e., it has 209 // This is called when we the renderer asks us to take focus back (i.e., it has
209 // iterated past the last focusable element on the page). 210 // iterated past the last focusable element on the page).
210 void WebContentsViewAndroid::TakeFocus(bool reverse) { 211 void WebContentsViewAndroid::TakeFocus(bool reverse) {
211 if (web_contents_->GetDelegate() && 212 if (web_contents_->GetDelegate() &&
212 web_contents_->GetDelegate()->TakeFocus(web_contents_, reverse)) 213 web_contents_->GetDelegate()->TakeFocus(web_contents_, reverse))
213 return; 214 return;
214 web_contents_->GetRenderWidgetHostView()->Focus(); 215 web_contents_->GetRenderWidgetHostView()->Focus();
215 } 216 }
216 217
217 } // namespace content 218 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698