Index: chrome/browser/gtk/custom_button.h |
diff --git a/chrome/browser/gtk/custom_button.h b/chrome/browser/gtk/custom_button.h |
index 768b4cabca22a78150fe761c1e669e6807264517..eb0cbd9a18cfe2d6b3547fbce9fefa0a69a4ab5f 100644 |
--- a/chrome/browser/gtk/custom_button.h |
+++ b/chrome/browser/gtk/custom_button.h |
@@ -16,6 +16,7 @@ |
#include "chrome/common/owned_widget_gtk.h" |
#include "third_party/skia/include/core/SkBitmap.h" |
+class CairoCachedSurface; |
class GtkThemeProvider; |
// These classes implement two kinds of custom-drawn buttons. They're |
@@ -36,7 +37,9 @@ class CustomDrawButtonBase : public NotificationObserver { |
~CustomDrawButtonBase(); |
- GdkPixbuf* pixbufs(int i) const { return pixbufs_[i]; } |
+ // Returns the dimensions() of the first pixbuf. |
tony
2009/09/09 21:26:21
Nit: remove the () in dimensions.
|
+ int width(); |
Evan Martin
2009/09/09 21:50:34
const?
maybe should be uppercase because it's not
|
+ int height(); |
gboolean OnExpose(GtkWidget* widget, GdkEventExpose* e); |
@@ -52,12 +55,12 @@ class CustomDrawButtonBase : public NotificationObserver { |
const NotificationDetails& details); |
private: |
- // We store one GdkPixbuf* for each possible state of the button; |
+ // We store one surface for each possible state of the button; |
// INSENSITIVE is the last available state; |
- GdkPixbuf* pixbufs_[GTK_STATE_INSENSITIVE + 1]; |
+ scoped_ptr<CairoCachedSurface> surfaces_[GTK_STATE_INSENSITIVE + 1]; |
// The background image. |
- GdkPixbuf* background_image_; |
+ scoped_ptr<CairoCachedSurface> background_image_; |
// If non-negative, the state to paint the button. |
int paint_override_; |