summaryrefslogtreecommitdiffstats
path: root/chrome/browser/gtk/bookmark_bar_gtk.cc
diff options
context:
space:
mode:
authorestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-11-06 21:09:57 +0000
committerestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-11-06 21:09:57 +0000
commit58e23f78f5b1666cda9a0ab43ae6314026a88787 (patch)
tree219c2f3e69f017c4c0fa14dc307d9f98b8da3808 /chrome/browser/gtk/bookmark_bar_gtk.cc
parent97a1d694d347ce8b84fca7ed1e17782726138f54 (diff)
downloadchromium_src-58e23f78f5b1666cda9a0ab43ae6314026a88787.zip
chromium_src-58e23f78f5b1666cda9a0ab43ae6314026a88787.tar.gz
chromium_src-58e23f78f5b1666cda9a0ab43ae6314026a88787.tar.bz2
GTK: Change find bar to use a floating container rather than some hacked up gtkfixed business.
The straw that broke this camel's back was when I realized that showing the findbar in fullscreen mode would inescapably mean an extra 1 pixel border at the top. Also fix z-ordering problems for findbar that have been around since I introduced the floating bookmark bar (the fact that no one filed a bug on this suggests that it's not that noticeable). BUG=none TEST=find bar still works. find bar works in fullscreen. the toolbar bottom border still exists at all times. there are no z-ordering problems. the find bar still gets out of way of find results. Review URL: http://codereview.chromium.org/373007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31296 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk/bookmark_bar_gtk.cc')
-rw-r--r--chrome/browser/gtk/bookmark_bar_gtk.cc14
1 files changed, 6 insertions, 8 deletions
diff --git a/chrome/browser/gtk/bookmark_bar_gtk.cc b/chrome/browser/gtk/bookmark_bar_gtk.cc
index d4949c7..c8ab529 100644
--- a/chrome/browser/gtk/bookmark_bar_gtk.cc
+++ b/chrome/browser/gtk/bookmark_bar_gtk.cc
@@ -293,15 +293,13 @@ void BookmarkBarGtk::Show(bool animate) {
AnimationProgressed(slide_animation_.get());
}
+ // Hide out behind the findbar. This is rather fragile code, it could
+ // probably be improved.
if (floating_) {
- // Hide out behind the findbar.
- if (GTK_WIDGET_REALIZED(paint_box_)) {
- // We toggle the above_child property so that the event window will
- // get lowered after we lower the window of |paint_box_|.
- gtk_event_box_set_above_child(GTK_EVENT_BOX(event_box_.get()), TRUE);
- gdk_window_lower(paint_box_->window);
- gtk_event_box_set_above_child(GTK_EVENT_BOX(event_box_.get()), FALSE);
- }
+ if (GTK_WIDGET_REALIZED(event_box_->parent))
+ gdk_window_lower(event_box_->parent->window);
+ if (GTK_WIDGET_REALIZED(event_box_.get()))
+ gdk_window_lower(event_box_->window);
}
// Maybe show the instructions