diff options
author | estade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-13 00:51:48 +0000 |
---|---|---|
committer | estade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-13 00:51:48 +0000 |
commit | 16adb28574253284c920079a6800a7cc192c8dc4 (patch) | |
tree | a480ca244e37ba0143b1f171bb621c2129f299f8 /chrome/browser/gtk/bookmark_bar_gtk.cc | |
parent | caafdbb72b9bb42aa0d40a25b4a47e6450246391 (diff) | |
download | chromium_src-16adb28574253284c920079a6800a7cc192c8dc4.zip chromium_src-16adb28574253284c920079a6800a7cc192c8dc4.tar.gz chromium_src-16adb28574253284c920079a6800a7cc192c8dc4.tar.bz2 |
Make findbar paint themed image.
Also, fixed drawing of background images that are not 1 pixel wide. (The code for this is somewhat speculative as there is no way of testing it at the moment, but for now it should still at least look correct.)
If you open the findbar while the bookmark bar is opened and then close the bookmark bar, the findbar painting is a little messed up in that it still thinks it's farther away from the tabstrip than it really is. The solution (unfortunately) is to continuously repaint the findbar as it is closing. Since this is glitch is hardly noticeable, I'm putting off fixing it.
TEST=findbar should look more integrated with bookmark bar, toolbar.
BUG=none
Review URL: http://codereview.chromium.org/125084
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18339 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk/bookmark_bar_gtk.cc')
-rw-r--r-- | chrome/browser/gtk/bookmark_bar_gtk.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/chrome/browser/gtk/bookmark_bar_gtk.cc b/chrome/browser/gtk/bookmark_bar_gtk.cc index 0e03a9c..181e4a2 100644 --- a/chrome/browser/gtk/bookmark_bar_gtk.cc +++ b/chrome/browser/gtk/bookmark_bar_gtk.cc @@ -799,9 +799,11 @@ gboolean BookmarkBarGtk::OnHBoxExpose(GtkWidget* widget, event->area.width, event->area.height); cairo_clip(cr); bar->InitBackground(); - int y = bar->window_->tabstrip()->GetTabStripOriginForWidget(widget).y(); - bar->background_ninebox_->RenderTopCenterStrip(cr, event->area.x, - y, event->area.width); + gfx::Point tabstrip_origin = + bar->window_->tabstrip()->GetTabStripOriginForWidget(widget); + bar->background_ninebox_->RenderTopCenterStrip( + cr, tabstrip_origin.x(), tabstrip_origin.y(), + event->area.x + event->area.width - tabstrip_origin.x()); cairo_destroy(cr); return FALSE; // Propagate expose to children. |