summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2010-01-23 19:30:03 +0000
committerrubidium <rubidium@openttd.org>2010-01-23 19:30:03 +0000
commit2b82db72efa7d148699cbdbcffd2e7e2a1a75f20 (patch)
tree992a15d4e39c544df9d0ab71c705559545e12f42 /src
parent4d184e9b167174283c8300d028b99ea6745eb721 (diff)
downloadopenttd-2b82db72efa7d148699cbdbcffd2e7e2a1a75f20.tar.xz
(svn r18899) -Fix: the default button was enabled even when the ENABLE_DEFAULT flag wasn't set
Diffstat (limited to 'src')
-rw-r--r--src/misc_gui.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/misc_gui.cpp b/src/misc_gui.cpp
index 1b71828f4..6ecfe45b5 100644
--- a/src/misc_gui.cpp
+++ b/src/misc_gui.cpp
@@ -1252,7 +1252,9 @@ struct QueryStringWindow : public QueryStringBaseWindow
virtual void UpdateWidgetSize(int widget, Dimension *size, const Dimension &padding, Dimension *fill, Dimension *resize)
{
if (widget == QUERY_STR_WIDGET_DEFAULT && (this->flags & QSF_ENABLE_DEFAULT) == 0) {
- this->GetWidget<NWidgetCore>(widget)->SetFill(0, 1);
+ /* We don't want this widget to show! */
+ fill->width = 0;
+ resize->width = 0;
size->width = 0;
}
}