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

Unified Diff: chrome/browser/ui/gtk/tab_contents_container_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/tab_contents_container_gtk.cc
diff --git a/chrome/browser/ui/gtk/tab_contents_container_gtk.cc b/chrome/browser/ui/gtk/tab_contents_container_gtk.cc
index 3dacd5e3f2fbd48a150ef9458aa28ecd50727111..a8b5c5c8155d06daadaf3c5288a594a9a8d89b19 100644
--- a/chrome/browser/ui/gtk/tab_contents_container_gtk.cc
+++ b/chrome/browser/ui/gtk/tab_contents_container_gtk.cc
@@ -12,6 +12,7 @@
#include "content/public/browser/notification_source.h"
#include "content/public/browser/render_widget_host_view.h"
#include "content/public/browser/web_contents.h"
+#include "content/public/browser/web_contents_view.h"
#include "ui/base/gtk/gtk_expanded_container.h"
#include "ui/base/gtk/gtk_floating_container.h"
#include "ui/gfx/native_widget_types.h"
@@ -80,7 +81,7 @@ void TabContentsContainerGtk::SetTab(content::WebContents* tab) {
// Make sure that the tab is below the find bar. Sometimes the content
// native view will be null.
- GtkWidget* widget = tab_->GetContentNativeView();
+ GtkWidget* widget = tab_->GetView()->GetContentNativeView();
if (widget) {
GdkWindow* content_gdk_window = gtk_widget_get_window(widget);
if (content_gdk_window)
@@ -95,7 +96,7 @@ void TabContentsContainerGtk::SetPreview(content::WebContents* preview) {
if (preview_) {
HideTab(preview_);
- GtkWidget* preview_widget = preview_->GetNativeView();
+ GtkWidget* preview_widget = preview_->GetView()->GetNativeView();
if (preview_widget)
gtk_container_remove(GTK_CONTAINER(expanded_), preview_widget);
}
@@ -107,7 +108,7 @@ void TabContentsContainerGtk::SetPreview(content::WebContents* preview) {
}
void TabContentsContainerGtk::PackTab(content::WebContents* tab) {
- gfx::NativeView widget = tab->GetNativeView();
+ gfx::NativeView widget = tab->GetView()->GetNativeView();
if (widget) {
if (gtk_widget_get_parent(widget) != expanded_)
gtk_container_add(GTK_CONTAINER(expanded_), widget);
@@ -120,7 +121,7 @@ void TabContentsContainerGtk::PackTab(content::WebContents* tab) {
}
void TabContentsContainerGtk::HideTab(content::WebContents* tab) {
- gfx::NativeView widget = tab->GetNativeView();
+ gfx::NativeView widget = tab->GetView()->GetNativeView();
if (widget)
gtk_widget_hide(widget);
@@ -130,7 +131,7 @@ void TabContentsContainerGtk::HideTab(content::WebContents* tab) {
}
void TabContentsContainerGtk::DetachTab(content::WebContents* tab) {
- gfx::NativeView widget = tab->GetNativeView();
+ gfx::NativeView widget = tab->GetView()->GetNativeView();
// It is possible to detach an unrealized, unparented WebContents if you
// slow things down enough in valgrind. Might happen in the real world, too.
@@ -169,7 +170,7 @@ void TabContentsContainerGtk::WebContentsDestroyed(
gboolean TabContentsContainerGtk::OnFocus(GtkWidget* widget,
GtkDirectionType focus) {
if (preview_) {
- gtk_widget_child_focus(tab_->GetContentNativeView(), focus);
+ gtk_widget_child_focus(tab_->GetView()->GetContentNativeView(), focus);
return TRUE;
}
« no previous file with comments | « chrome/browser/ui/gtk/speech_recognition_bubble_gtk.cc ('k') | chrome/browser/ui/gtk/tabs/dragged_tab_controller_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698