Changeset - r19795:fb0d66caa0fe
[Not reviewed]
master
0 4 0
frosch - 12 years ago 2012-11-14 22:51:05
frosch@openttd.org
(svn r24750) -Cleanup: Remove old special clear filter button from signs list.
4 files changed with 0 insertions and 24 deletions:
0 comments (0 inline, 0 general)
src/script/api/game/game_window.hpp.sq
Show inline comments
 
@@ -1020,7 +1020,6 @@ void SQGSWindow_Register(Squirrel *engin
 
	SQGSWindow.DefSQConst(engine, ScriptWindow::WID_SIL_SCROLLBAR,                         "WID_SIL_SCROLLBAR");
 
	SQGSWindow.DefSQConst(engine, ScriptWindow::WID_SIL_FILTER_TEXT,                       "WID_SIL_FILTER_TEXT");
 
	SQGSWindow.DefSQConst(engine, ScriptWindow::WID_SIL_FILTER_MATCH_CASE_BTN,             "WID_SIL_FILTER_MATCH_CASE_BTN");
 
	SQGSWindow.DefSQConst(engine, ScriptWindow::WID_SIL_FILTER_CLEAR_BTN,                  "WID_SIL_FILTER_CLEAR_BTN");
 
	SQGSWindow.DefSQConst(engine, ScriptWindow::WID_SIL_FILTER_ENTER_BTN,                  "WID_SIL_FILTER_ENTER_BTN");
 
	SQGSWindow.DefSQConst(engine, ScriptWindow::WID_QES_CAPTION,                           "WID_QES_CAPTION");
 
	SQGSWindow.DefSQConst(engine, ScriptWindow::WID_QES_TEXT,                              "WID_QES_TEXT");
src/script/api/script_window.hpp
Show inline comments
 
@@ -2143,7 +2143,6 @@ public:
 
		WID_SIL_SCROLLBAR                            = ::WID_SIL_SCROLLBAR,                            ///< Scrollbar of list.
 
		WID_SIL_FILTER_TEXT                          = ::WID_SIL_FILTER_TEXT,                          ///< Text box for typing a filter string.
 
		WID_SIL_FILTER_MATCH_CASE_BTN                = ::WID_SIL_FILTER_MATCH_CASE_BTN,                ///< Button to toggle if case sensitive filtering should be used.
 
		WID_SIL_FILTER_CLEAR_BTN                     = ::WID_SIL_FILTER_CLEAR_BTN,                     ///< Button to clear the filter.
 
		WID_SIL_FILTER_ENTER_BTN                     = ::WID_SIL_FILTER_ENTER_BTN,                     ///< Scroll to first sign.
 
	};
 

	
src/signs_gui.cpp
Show inline comments
 
@@ -172,17 +172,6 @@ struct SignListWindow : Window, SignList
 
	}
 

	
 
	/**
 
	 * Empties the string buffer that is edited by the filter text edit widget.
 
	 * It also triggers the redraw of the widget so it become visible that the string has been made empty.
 
	 */
 
	void ClearFilterTextWidget()
 
	{
 
		this->filter_editbox.text.DeleteAll();
 

	
 
		this->SetWidgetDirty(WID_SIL_FILTER_TEXT);
 
	}
 

	
 
	/**
 
	 * This function sets the filter string of the sign list. The contents of
 
	 * the edit widget is not updated by this function. Depending on if the
 
	 * new string is zero-length or not the clear button is made
 
@@ -192,10 +181,6 @@ struct SignListWindow : Window, SignList
 
	{
 
		/* check if there is a new filter string */
 
		this->string_filter.SetFilterTerm(new_filter_string);
 
		this->SetWidgetDisabledState(WID_SIL_FILTER_CLEAR_BTN, StrEmpty(new_filter_string));
 

	
 
		/* Repaint the clear button since its disabled state may have changed */
 
		this->SetWidgetDirty(WID_SIL_FILTER_CLEAR_BTN);
 

	
 
		/* Rebuild the list of signs */
 
		this->InvalidateData();
 
@@ -263,11 +248,6 @@ struct SignListWindow : Window, SignList
 
				}
 
				break;
 

	
 
			case WID_SIL_FILTER_CLEAR_BTN:
 
				this->ClearFilterTextWidget(); // Empty the text in the EditBox widget
 
				this->SetFilterString("");     // Use empty text as filter text (= view all signs)
 
				break;
 

	
 
			case WID_SIL_FILTER_MATCH_CASE_BTN:
 
				SignList::match_case = !SignList::match_case; // Toggle match case
 
				this->SetWidgetLoweredState(WID_SIL_FILTER_MATCH_CASE_BTN, SignList::match_case); // Toggle button pushed state
 
@@ -379,7 +359,6 @@ static const NWidgetPart _nested_sign_li
 
							SetDataTip(STR_LIST_FILTER_OSKTITLE, STR_LIST_FILTER_TOOLTIP),
 
				EndContainer(),
 
				NWidget(WWT_TEXTBTN, COLOUR_GREY, WID_SIL_FILTER_MATCH_CASE_BTN), SetDataTip(STR_SIGN_LIST_MATCH_CASE, STR_SIGN_LIST_MATCH_CASE_TOOLTIP),
 
				NWidget(WWT_PUSHTXTBTN, COLOUR_GREY, WID_SIL_FILTER_CLEAR_BTN), SetDataTip(STR_SIGN_LIST_CLEAR, STR_SIGN_LIST_CLEAR_TOOLTIP),
 
			EndContainer(),
 
		EndContainer(),
 
		NWidget(NWID_VERTICAL),
src/widgets/sign_widget.h
Show inline comments
 
@@ -20,7 +20,6 @@ enum SignListWidgets {
 
	WID_SIL_SCROLLBAR,             ///< Scrollbar of list.
 
	WID_SIL_FILTER_TEXT,           ///< Text box for typing a filter string.
 
	WID_SIL_FILTER_MATCH_CASE_BTN, ///< Button to toggle if case sensitive filtering should be used.
 
	WID_SIL_FILTER_CLEAR_BTN,      ///< Button to clear the filter.
 
	WID_SIL_FILTER_ENTER_BTN,      ///< Scroll to first sign.
 
};
 

	
0 comments (0 inline, 0 general)