From 1b75e974088a94cd28d7a48729545904b2cd908b Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 16 Mar 2014 15:41:51 +0300 Subject: Remove some useless static methods from theme. --- src/gui/widgets/widget2.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/gui/widgets/widget2.h') diff --git a/src/gui/widgets/widget2.h b/src/gui/widgets/widget2.h index ff565815f..2d73418ba 100644 --- a/src/gui/widgets/widget2.h +++ b/src/gui/widgets/widget2.h @@ -36,16 +36,18 @@ class Widget2 const int alpha = 255) const A_WARN_UNUSED { - return Theme::getThemeColor(mPaletteOffset + type, alpha); + return theme->getColor(mPaletteOffset + type, alpha); } inline const Color &getThemeCharColor(const signed char c, bool &valid) const A_WARN_UNUSED { - const int colorId = Theme::getThemeIdByChar(c, valid); + if (!theme) + return Palette::BLACK; + const int colorId = theme->getIdByChar(c, valid);; if (valid) - return Theme::getThemeColor(mPaletteOffset + colorId); + return theme->getColor(mPaletteOffset + colorId, 255); else return Palette::BLACK; } -- cgit v1.2.3-70-g09d2