From 0b50c4966cf1b378164a9df929820a69708c8531 Mon Sep 17 00:00:00 2001 From: Max Horn Date: Fri, 4 Aug 2006 17:59:53 +0000 Subject: Activate _dimsInactive for ValueDisplayDialog, makes the text speed/volume change etc. mini-dialogs behave a little bit less weird (TODO: Disable cursor change) svn-id: r23667 --- engines/scumm/dialogs.cpp | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) (limited to 'engines') diff --git a/engines/scumm/dialogs.cpp b/engines/scumm/dialogs.cpp index d96f840373..25e6ebaf97 100644 --- a/engines/scumm/dialogs.cpp +++ b/engines/scumm/dialogs.cpp @@ -846,17 +846,22 @@ void ConfirmDialog::handleKeyDown(uint16 ascii, int keycode, int modifiers) { #pragma mark - -ValueDisplayDialog::ValueDisplayDialog(const Common::String& label, int minVal, int maxVal, int val, uint16 incKey, uint16 decKey) - : GUI::Dialog("scummDummyDialog"), _label(label), _min(minVal), _max(maxVal), _value(val), _incKey(incKey), _decKey(decKey) { +ValueDisplayDialog::ValueDisplayDialog(const Common::String& label, int minVal, int maxVal, + int val, uint16 incKey, uint16 decKey) + : GUI::Dialog("scummDummyDialog", false), + _label(label), _min(minVal), _max(maxVal), + _value(val), _incKey(incKey), _decKey(decKey) { assert(_min <= _value && _value <= _max); - } void ValueDisplayDialog::drawDialog() { const int labelWidth = _w - 8 - _percentBarWidth; - g_gui.theme()->drawDialogBackground(Common::Rect(_x, _y, _x+_w, _y+_h), GUI::THEME_HINT_SAVE_BACKGROUND | GUI::THEME_HINT_FIRST_DRAW); - g_gui.theme()->drawText(Common::Rect(_x+4, _y+4, _x+labelWidth+4, _y+g_gui.theme()->getFontHeight()+4), _label); - g_gui.theme()->drawSlider(Common::Rect(_x+4+labelWidth, _y+4, _x+_w-4, _y+_h-4), _percentBarWidth * (_value - _min) / (_max - _min)); + g_gui.theme()->drawDialogBackground(Common::Rect(_x, _y, _x+_w, _y+_h), + GUI::THEME_HINT_SAVE_BACKGROUND | GUI::THEME_HINT_FIRST_DRAW); + g_gui.theme()->drawText(Common::Rect(_x+4, _y+4, _x+labelWidth+4, + _y+g_gui.theme()->getFontHeight()+4), _label); + g_gui.theme()->drawSlider(Common::Rect(_x+4+labelWidth, _y+4, _x+_w-4, _y+_h-4), + _percentBarWidth * (_value - _min) / (_max - _min)); } void ValueDisplayDialog::handleTickle() { -- cgit v1.2.3