diff options
author | glen@chromium.org <glen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-04 02:31:20 +0000 |
---|---|---|
committer | glen@chromium.org <glen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-04 02:31:20 +0000 |
commit | 198d0468712f48b7d02a5366cfa03989061ed147 (patch) | |
tree | f5e9166965cfaafba50f9532ab1049147c7b9710 /views/controls/button/text_button.h | |
parent | 6e853c3ad131fe6713ce8efbac2270fee26ab5b2 (diff) | |
download | chromium_src-198d0468712f48b7d02a5366cfa03989061ed147.zip chromium_src-198d0468712f48b7d02a5366cfa03989061ed147.tar.gz chromium_src-198d0468712f48b7d02a5366cfa03989061ed147.tar.bz2 |
Reland of r17500:
Theme our bookmark bar buttons.
BUG=12467
TEST=Apply a theme and verify that bookmark bar text colors changes.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17587 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/controls/button/text_button.h')
-rw-r--r-- | views/controls/button/text_button.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/views/controls/button/text_button.h b/views/controls/button/text_button.h index 1a8134e..e18ef59 100644 --- a/views/controls/button/text_button.h +++ b/views/controls/button/text_button.h @@ -89,6 +89,9 @@ class TextButton : public CustomButton { void ClearMaxTextSize(); void set_max_width(int max_width) { max_width_ = max_width; } + void SetEnabledColor(SkColor color); + void SetDisabledColor(SkColor color); + void SetHighlightColor(SkColor color); // Paint the button into the specified canvas. If |for_drag| is true, the // function paints a drag image representation into the canvas. @@ -103,6 +106,10 @@ class TextButton : public CustomButton { virtual bool OnMousePressed(const MouseEvent& e); virtual void Paint(gfx::Canvas* canvas); + // Called when enabled or disabled state changes, or the colors for those + // states change. + virtual void UpdateColor(); + private: // The text string that is displayed in the button. std::wstring text_; @@ -123,6 +130,11 @@ class TextButton : public CustomButton { // Text color. SkColor color_; + // State colors. + SkColor color_enabled_; + SkColor color_disabled_; + SkColor color_highlight_; + // An icon displayed with the text. SkBitmap icon_; |