(svn r25413) -Fix-ish: Suppress focussing editboxes which are not visible.

This commit is contained in:
frosch
2013-06-15 15:31:04 +00:00
parent 5cb174c6b8
commit ee4e68bd5e
3 changed files with 10 additions and 1 deletions

View File

@@ -646,7 +646,11 @@ struct NewGRFWindow : public Window, NewGRFScanCallback {
this->querystrings[WID_NS_FILTER] = &this->filter_editbox;
this->filter_editbox.cancel_button = QueryString::ACTION_CLEAR;
if (editable) this->SetFocusedWidget(WID_NS_FILTER);
if (editable) {
this->SetFocusedWidget(WID_NS_FILTER);
} else {
this->DisableWidget(WID_NS_FILTER);
}
this->avails.SetListing(this->last_sorting);
this->avails.SetFiltering(this->last_filtering);