summaryrefslogtreecommitdiff
path: root/src/newgrf_gui.cpp
diff options
context:
space:
mode:
authoryexo <yexo@openttd.org>2011-06-16 10:59:09 +0000
committeryexo <yexo@openttd.org>2011-06-16 10:59:09 +0000
commitbf994b46f1441b4097093f8c8d1aa8f849c7c1da (patch)
tree42bcee677d4dac873584d3f73024d2b6ee52944e /src/newgrf_gui.cpp
parent1a0d25dab161927da00fad364963d93e2e6f9602 (diff)
downloadopenttd-bf994b46f1441b4097093f8c8d1aa8f849c7c1da.tar.xz
(svn r22594) -Fix [FS#4644]: add active NewGRFs to the list of available ones when selecting the empty preset
Diffstat (limited to 'src/newgrf_gui.cpp')
-rw-r--r--src/newgrf_gui.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/newgrf_gui.cpp b/src/newgrf_gui.cpp
index f91ef192e..f2ea18442 100644
--- a/src/newgrf_gui.cpp
+++ b/src/newgrf_gui.cpp
@@ -1004,12 +1004,9 @@ struct NewGRFWindow : public QueryStringBaseWindow {
this->preset = index;
if (index != -1) {
- GRFConfig *c = LoadGRFPresetFromConfig(_grf_preset_list[index]);
-
- this->active_sel = NULL;
- this->actives = c;
- this->avails.ForceRebuild();
+ this->actives = LoadGRFPresetFromConfig(_grf_preset_list[index]);
}
+ this->avails.ForceRebuild();
DeleteWindowByClass(WC_GRF_PARAMETERS);
this->active_sel = NULL;