# HG changeset patch # User Darkvater # Date 1160667517 0 # Node ID c885511caff199fd291f0ffb383ffb8b2eb3a8bd # Parent 3c6e8a54717466867dbca953781bf5a20d477915 (svn r6759) -Codechange: Remove the brainheaded usage of STR_JUST_STRING to pass a StringID diff -r 3c6e8a547174 -r c885511caff1 train_gui.c --- a/train_gui.c Thu Oct 12 15:13:40 2006 +0000 +++ b/train_gui.c Thu Oct 12 15:38:37 2006 +0000 @@ -132,18 +132,16 @@ { const EngineID va = *(const EngineID*)a; const EngineID vb = *(const EngineID*)b; - char buf1[64] = "\0"; + char buf1[64]; int r; - SetDParam(0, GetCustomEngineName(va)); - GetString(buf1, STR_JUST_STRING); + GetString(buf1, GetCustomEngineName(va)); if (vb != _last_engine) { _last_engine = vb; _bufcache[0] = '\0'; - SetDParam(0, GetCustomEngineName(vb)); - GetString(_bufcache, STR_JUST_STRING); + GetString(_bufcache, GetCustomEngineName(vb)); } r = strcmp(buf1, _bufcache); // sort by name diff -r 3c6e8a547174 -r c885511caff1 vehicle_gui.c --- a/vehicle_gui.c Thu Oct 12 15:13:40 2006 +0000 +++ b/vehicle_gui.c Thu Oct 12 15:38:37 2006 +0000 @@ -516,17 +516,13 @@ char buf1[64] = "\0"; int r; - if (va->string_id != _internal_name_sorter_id) { - SetDParam(0, va->string_id); - GetString(buf1, STR_JUST_STRING); - } + if (va->string_id != _internal_name_sorter_id) GetString(buf1, va->string_id); if (vb != _last_vehicle) { _last_vehicle = vb; _bufcache[0] = '\0'; if (vb->string_id != _internal_name_sorter_id) { - SetDParam(0, vb->string_id); - GetString(_bufcache, STR_JUST_STRING); + GetString(_bufcache, vb->string_id); } }