diff options
author | rubidium <rubidium@openttd.org> | 2009-09-27 10:44:25 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2009-09-27 10:44:25 +0000 |
commit | 09124e2186edb9c07ee5d5ecbc50e4ce0ebaafda (patch) | |
tree | b5806852d237513c45ea2a8d68142d9ac62b7aa8 /src | |
parent | 8a21979b42b08ec5714602dfed765c55641eb480 (diff) | |
download | openttd-09124e2186edb9c07ee5d5ecbc50e4ce0ebaafda.tar.xz |
(svn r17654) -Fix [FS#3220] (r17612): the edit box of the town fund window wasn't updated properly (based on patch of Terkhen)
Diffstat (limited to 'src')
-rw-r--r-- | src/town_gui.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/town_gui.cpp b/src/town_gui.cpp index 4a001f1dc..398bf628a 100644 --- a/src/town_gui.cpp +++ b/src/town_gui.cpp @@ -969,6 +969,7 @@ public: params(_settings_game.game_creation.town_name) { this->InitNested(desc, window_number); + InitializeTextBuffer(&this->text, this->edit_str_buf, this->edit_str_size, MAX_LENGTH_TOWN_NAME_PIXELS); this->RandomTownName(); this->UpdateButtons(); } @@ -982,9 +983,10 @@ public: } else { GetTownName(this->edit_str_buf, &this->params, this->townnameparts, &this->edit_str_buf[this->edit_str_size - 1]); } - InitializeTextBuffer(&this->text, this->edit_str_buf, this->edit_str_size, MAX_LENGTH_TOWN_NAME_PIXELS); + UpdateTextBufferSize(&this->text); this->SetFocusedWidget(TSEW_TOWNNAME_EDITBOX); + this->SetWidgetDirty(TSEW_TOWNNAME_EDITBOX); } void UpdateButtons() |