Changeset - r20300:c9a1fb7bc57b
[Not reviewed]
master
0 1 0
frosch - 11 years ago 2013-05-31 18:47:49
frosch@openttd.org
(svn r25307) -Fix: Do not focus the editbox in the NewGRF window, if there is no editbox visible.
1 file changed with 1 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/newgrf_gui.cpp
Show inline comments
 
@@ -643,13 +643,13 @@ struct NewGRFWindow : public Window, New
 
		this->GetWidget<NWidgetStacked>(WID_NS_SHOW_REMOVE)->SetDisplayedPlane(this->editable ? 0 : 1);
 
		this->GetWidget<NWidgetStacked>(WID_NS_SHOW_APPLY)->SetDisplayedPlane(this->editable ? 0 : this->show_params ? 1 : SZSP_HORIZONTAL);
 
		this->FinishInitNested(WN_GAME_OPTIONS_NEWGRF_STATE);
 

	
 
		this->querystrings[WID_NS_FILTER] = &this->filter_editbox;
 
		this->filter_editbox.cancel_button = QueryString::ACTION_CLEAR;
 
		this->SetFocusedWidget(WID_NS_FILTER);
 
		if (editable) this->SetFocusedWidget(WID_NS_FILTER);
 

	
 
		this->avails.SetListing(this->last_sorting);
 
		this->avails.SetFiltering(this->last_filtering);
 
		this->avails.SetSortFuncs(this->sorter_funcs);
 
		this->avails.SetFilterFuncs(this->filter_funcs);
 
		this->avails.ForceRebuild();
0 comments (0 inline, 0 general)