summaryrefslogtreecommitdiff
path: root/src/gui/widgets/button.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/button.cpp')
-rw-r--r--src/gui/widgets/button.cpp85
1 files changed, 45 insertions, 40 deletions
diff --git a/src/gui/widgets/button.cpp b/src/gui/widgets/button.cpp
index 0c2600583..25986ef8a 100644
--- a/src/gui/widgets/button.cpp
+++ b/src/gui/widgets/button.cpp
@@ -108,15 +108,16 @@ Button::Button(const Widget2 *const widget) :
mDescription(),
mTextChunk(),
mVertexes2(new ImageCollection),
- mEnabledColor(getThemeColor(ThemeColorId::BUTTON)),
- mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE)),
- mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED)),
- mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE)),
- mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED)),
+ mEnabledColor(getThemeColor(ThemeColorId::BUTTON, 255U)),
+ mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE, 255U)),
+ mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED, 255U)),
+ mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE,
+ 255U)),
+ mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED, 255U)),
mHighlightedColor2(getThemeColor(
- ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE)),
- mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED)),
- mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE)),
+ ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE, 255U)),
+ mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED, 255U)),
+ mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE, 255U)),
mImages(nullptr),
mImageSet(nullptr),
mAlignment(Graphics::CENTER),
@@ -152,15 +153,16 @@ Button::Button(const Widget2 *const widget,
mDescription(),
mTextChunk(),
mVertexes2(new ImageCollection),
- mEnabledColor(getThemeColor(ThemeColorId::BUTTON)),
- mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE)),
- mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED)),
- mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE)),
- mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED)),
+ mEnabledColor(getThemeColor(ThemeColorId::BUTTON, 255U)),
+ mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE, 255U)),
+ mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED, 255U)),
+ mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE,
+ 255U)),
+ mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED, 255U)),
mHighlightedColor2(getThemeColor(
- ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE)),
- mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED)),
- mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE)),
+ ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE, 255U)),
+ mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED, 255U)),
+ mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE, 255U)),
mImages(nullptr),
mImageSet(nullptr),
mAlignment(Graphics::CENTER),
@@ -202,15 +204,16 @@ Button::Button(const Widget2 *const widget,
mDescription(),
mTextChunk(),
mVertexes2(new ImageCollection),
- mEnabledColor(getThemeColor(ThemeColorId::BUTTON)),
- mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE)),
- mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED)),
- mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE)),
- mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED)),
+ mEnabledColor(getThemeColor(ThemeColorId::BUTTON, 255U)),
+ mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE, 255U)),
+ mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED, 255U)),
+ mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE,
+ 255U)),
+ mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED, 255U)),
mHighlightedColor2(getThemeColor(
- ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE)),
- mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED)),
- mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE)),
+ ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE, 255U)),
+ mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED, 255U)),
+ mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE, 255U)),
mImages(nullptr),
mImageSet(nullptr),
mAlignment(Graphics::CENTER),
@@ -252,15 +255,16 @@ Button::Button(const Widget2 *const widget,
mDescription(),
mTextChunk(),
mVertexes2(new ImageCollection),
- mEnabledColor(getThemeColor(ThemeColorId::BUTTON)),
- mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE)),
- mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED)),
- mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE)),
- mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED)),
+ mEnabledColor(getThemeColor(ThemeColorId::BUTTON, 255U)),
+ mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE, 255U)),
+ mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED, 255U)),
+ mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE,
+ 255U)),
+ mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED, 255U)),
mHighlightedColor2(getThemeColor(
- ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE)),
- mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED)),
- mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE)),
+ ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE, 255U)),
+ mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED, 255U)),
+ mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE, 255U)),
mImages(nullptr),
mImageSet(nullptr),
mAlignment(Graphics::CENTER),
@@ -302,15 +306,16 @@ Button::Button(const Widget2 *const widget,
mDescription(),
mTextChunk(),
mVertexes2(new ImageCollection),
- mEnabledColor(getThemeColor(ThemeColorId::BUTTON)),
- mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE)),
- mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED)),
- mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE)),
- mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED)),
+ mEnabledColor(getThemeColor(ThemeColorId::BUTTON, 255U)),
+ mEnabledColor2(getThemeColor(ThemeColorId::BUTTON_OUTLINE, 255U)),
+ mDisabledColor(getThemeColor(ThemeColorId::BUTTON_DISABLED, 255U)),
+ mDisabledColor2(getThemeColor(ThemeColorId::BUTTON_DISABLED_OUTLINE,
+ 255U)),
+ mHighlightedColor(getThemeColor(ThemeColorId::BUTTON_HIGHLIGHTED, 255U)),
mHighlightedColor2(getThemeColor(
- ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE)),
- mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED)),
- mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE)),
+ ThemeColorId::BUTTON_HIGHLIGHTED_OUTLINE, 255U)),
+ mPressedColor(getThemeColor(ThemeColorId::BUTTON_PRESSED, 255U)),
+ mPressedColor2(getThemeColor(ThemeColorId::BUTTON_PRESSED_OUTLINE, 255U)),
mImages(nullptr),
mImageSet(nullptr),
mAlignment(Graphics::CENTER),