diff options
author | tc@google.com <tc@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-07 23:57:13 +0000 |
---|---|---|
committer | tc@google.com <tc@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-07 23:57:13 +0000 |
commit | b9293ff66e688d5ff2239b8984588f501fbbfe4b (patch) | |
tree | 61cfbfbcf6dbdf19a4482189c9fa8ec14b77ce7f /chrome/browser/gtk/tab_contents_container_gtk.cc | |
parent | 4cf2e5c49c739753ac2aa8049ec515f0a2e36186 (diff) | |
download | chromium_src-b9293ff66e688d5ff2239b8984588f501fbbfe4b.zip chromium_src-b9293ff66e688d5ff2239b8984588f501fbbfe4b.tar.gz chromium_src-b9293ff66e688d5ff2239b8984588f501fbbfe4b.tar.bz2 |
Fix the findbar crash.
FindBarController is no longer owned by the BrowserWindow, it is
owned by Browser. So we can remove the FindBarController code in
BrowserWindowGtk. Also, go ahead and implement
BrowserWindow::CreateFindBar (which creates the gtk widget and adds
it to the gtk widget hierarchy) and enable the code on linux.
Since the widgets are created and added to the hierarchy later,
we attach the signals after the widgets have been "realized".
Review URL: http://codereview.chromium.org/62126
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13310 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk/tab_contents_container_gtk.cc')
-rw-r--r-- | chrome/browser/gtk/tab_contents_container_gtk.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/chrome/browser/gtk/tab_contents_container_gtk.cc b/chrome/browser/gtk/tab_contents_container_gtk.cc index 0b38c76..9e73389 100644 --- a/chrome/browser/gtk/tab_contents_container_gtk.cc +++ b/chrome/browser/gtk/tab_contents_container_gtk.cc @@ -10,11 +10,9 @@ #include "chrome/common/notification_service.h" -TabContentsContainerGtk::TabContentsContainerGtk(GtkWidget* findbar) +TabContentsContainerGtk::TabContentsContainerGtk() : tab_contents_(NULL), vbox_(gtk_vbox_new(FALSE, 0)) { - DCHECK(findbar); - gtk_box_pack_start(GTK_BOX(vbox_), findbar, FALSE, FALSE, 0); gtk_widget_show(vbox_); } @@ -27,6 +25,10 @@ void TabContentsContainerGtk::AddContainerToBox(GtkWidget* box) { gtk_box_pack_start(GTK_BOX(box), vbox_, TRUE, TRUE, 0); } +void TabContentsContainerGtk::AddFindBar(GtkWidget* findbar) { + gtk_box_pack_start(GTK_BOX(vbox_), findbar, FALSE, FALSE, 0); +} + void TabContentsContainerGtk::SetTabContents(TabContents* tab_contents) { if (tab_contents_) { gfx::NativeView widget = tab_contents_->GetNativeView(); |