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

Unified Diff: chrome/browser/gtk/nine_box.h

Issue 100224: GTK: give the findbox curvy edges.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 8 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
« no previous file with comments | « chrome/browser/gtk/find_bar_gtk.cc ('k') | chrome/browser/gtk/nine_box.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/gtk/nine_box.h
===================================================================
--- chrome/browser/gtk/nine_box.h (revision 14956)
+++ chrome/browser/gtk/nine_box.h (working copy)
@@ -28,16 +28,26 @@
// Render the NineBox to |dst|.
// The images will be tiled to fit into the widget.
- void RenderToWidget(GtkWidget* dst);
+ void RenderToWidget(GtkWidget* dst) const;
// Render the top row of images to |dst| between |x1| and |x2|.
// This is split from RenderToWidget so the toolbar can use it.
- void RenderTopCenterStrip(GtkWidget* dst, int x1, int x2, int y1);
+ void RenderTopCenterStrip(GtkWidget* dst, int x1, int x2, int y1) const;
+ // Change all pixels that are white in |images_| to have 0 opacity.
+ void ChangeWhiteToTransparent();
+
+ // Set the shape of |widget| to match that of the ninebox. Note that |widget|
+ // must have its own window and be allocated. Also, currently only the top
+ // three images are used.
+ // TODO(estade): extend this function to use all 9 images (if it's ever
+ // needed).
+ void ContourWidget(GtkWidget* widget) const;
+
private:
// Repeatedly stamp src across dst.
void TileImage(GtkWidget* dst, GdkPixbuf* src,
- int x1, int y1, int x2, int y2);
+ int x1, int y1, int x2, int y2) const;
GdkPixbuf* images_[9];
};
« no previous file with comments | « chrome/browser/gtk/find_bar_gtk.cc ('k') | chrome/browser/gtk/nine_box.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698