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

Unified Diff: chrome/browser/ui/gtk/browser_window_gtk.cc

Issue 12334073: Remove WebContents methods that duplicate WebContentsView methods. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/gtk/browser_window_gtk.cc
diff --git a/chrome/browser/ui/gtk/browser_window_gtk.cc b/chrome/browser/ui/gtk/browser_window_gtk.cc
index 638e3e5bb331044f6c5dad887e7824f58267317d..bbeb1e10416e252548fa39007cda6a8742378406 100644
--- a/chrome/browser/ui/gtk/browser_window_gtk.cc
+++ b/chrome/browser/ui/gtk/browser_window_gtk.cc
@@ -1145,7 +1145,7 @@ bool BrowserWindowGtk::GetConstrainedWindowTopY(int* top_y) {
void BrowserWindowGtk::ShowAvatarBubble(WebContents* web_contents,
const gfx::Rect& rect) {
- GtkWidget* widget = web_contents->GetContentNativeView();
+ GtkWidget* widget = web_contents->GetView()->GetContentNativeView();
new AvatarMenuBubbleGtk(browser_.get(), widget,
BubbleGtk::ANCHOR_TOP_LEFT, &rect);
}
@@ -1161,7 +1161,7 @@ void BrowserWindowGtk::ShowPasswordGenerationBubble(
autofill::PasswordGenerator* password_generator) {
WebContents* web_contents =
browser_->tab_strip_model()->GetActiveWebContents();
- if (!web_contents || !web_contents->GetContentNativeView()) {
+ if (!web_contents || !web_contents->GetView()->GetContentNativeView()) {
return;
}
@@ -1984,8 +1984,10 @@ gboolean BrowserWindowGtk::OnKeyPress(GtkWidget* widget, GdkEventKey* event) {
WebContents* current_web_contents =
browser()->tab_strip_model()->GetActiveWebContents();
// The current tab might not have a render view if it crashed.
- if (!current_web_contents || !current_web_contents->GetContentNativeView() ||
- !gtk_widget_is_focus(current_web_contents->GetContentNativeView())) {
+ if (!current_web_contents ||
+ !current_web_contents->GetView()->GetContentNativeView() ||
+ !gtk_widget_is_focus(
+ current_web_contents->GetView()->GetContentNativeView())) {
int command_id = GetCustomCommandId(event);
if (command_id == -1)
command_id = GetPreHandleCommandId(event);
« no previous file with comments | « chrome/browser/ui/cocoa/web_dialog_window_controller.mm ('k') | chrome/browser/ui/gtk/constrained_web_dialog_delegate_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698