aboutsummaryrefslogtreecommitdiff
path: root/gui/theme.h
diff options
context:
space:
mode:
authorJohannes Schickel2006-01-28 23:03:39 +0000
committerJohannes Schickel2006-01-28 23:03:39 +0000
commit5fda0cc6f1addedb4e3c671a9f124e6c5b253323 (patch)
treeb869dc52a415e20e8eb5aed5704fe539216f5c2c /gui/theme.h
parentd84cefec75e8dfe6a33042c246a5f980829235a7 (diff)
downloadscummvm-rg350-5fda0cc6f1addedb4e3c671a9f124e6c5b253323.tar.gz
scummvm-rg350-5fda0cc6f1addedb4e3c671a9f124e6c5b253323.tar.bz2
scummvm-rg350-5fda0cc6f1addedb4e3c671a9f124e6c5b253323.zip
- Fixes a bug that the debugger crashed while opening
- Changed gradient calculating - added background saving for all dialog/widget backgrounds for now (change that later maybe) - changed ScummDialog to use the colors of our launcher dialog svn-id: r20276
Diffstat (limited to 'gui/theme.h')
-rw-r--r--gui/theme.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/gui/theme.h b/gui/theme.h
index 474e233f4f..f251e9888c 100644
--- a/gui/theme.h
+++ b/gui/theme.h
@@ -41,7 +41,13 @@ enum {
// Indicates that the widget will be redrawn often, e.g. list widgets.
// It may therefore be a good idea to save the background so that it
// can be redrawn quickly.
- THEME_HINT_SAVE_BACKGROUND = 1 << 1
+ THEME_HINT_SAVE_BACKGROUND = 1 << 1,
+
+ // Indicates that this is the launcher dialog (maybe delete this in the future)
+ THEME_HINT_MAIN_DIALOG = 1 << 2,
+
+ // Indicates special colorfade
+ THEME_HINT_SPECIAL_COLOR = 1 << 3
};
class Theme {
@@ -101,7 +107,7 @@ public:
virtual int getStringWidth(const Common::String &str) const = 0;
virtual int getCharWidth(byte c) const = 0;
- virtual void drawDialogBackground(const Common::Rect &r, kState state = kStateEnabled, bool mainDialog = false) = 0;
+ virtual void drawDialogBackground(const Common::Rect &r, uint16 hints, kState state = kStateEnabled) = 0;
virtual void drawText(const Common::Rect &r, const Common::String &str, kState state = kStateEnabled, kTextAlign align = kTextAlignCenter, bool inverted = false, int deltax = 0, bool useEllipsis = true) = 0;
// this should ONLY be used by the debugger until we get a nicer solution
virtual void drawChar(const Common::Rect &r, byte ch, const Graphics::Font *font, kState state = kStateEnabled) = 0;
@@ -181,7 +187,7 @@ public:
int getStringWidth(const Common::String &str) const { if (_initOk) return _font->getStringWidth(str); return 0; }
int getCharWidth(byte c) const { if (_initOk) return _font->getCharWidth(c); return 0; }
- void drawDialogBackground(const Common::Rect &r, kState state, bool mainDialog);
+ void drawDialogBackground(const Common::Rect &r, uint16 hints, kState state);
void drawText(const Common::Rect &r, const Common::String &str, kState state, kTextAlign align, bool inverted, int deltax, bool useEllipsis);
void drawChar(const Common::Rect &r, byte ch, const Graphics::Font *font, kState state);
@@ -249,7 +255,7 @@ public:
int getStringWidth(const Common::String &str) const { if (_font) return _font->getStringWidth(str); return 0; }
int getCharWidth(byte c) const { if (_font) return _font->getCharWidth(c); return 0; }
- void drawDialogBackground(const Common::Rect &r, kState state, bool mainDialog);
+ void drawDialogBackground(const Common::Rect &r, uint16 hints, kState state);
void drawText(const Common::Rect &r, const Common::String &str, kState state, kTextAlign align, bool inverted, int deltax, bool useEllipsis);
void drawChar(const Common::Rect &r, byte ch, const Graphics::Font *font, kState state);