(svn r14008) -Fix (r14004): NewGRF preset drop down list not working
authorpeter1138
Wed, 06 Aug 2008 20:12:42 +0000
changeset 9863 af31097a285f
parent 9862 f801c7d84353
child 9864 1ea12c90e7dd
(svn r14008) -Fix (r14004): NewGRF preset drop down list not working
src/newgrf_gui.cpp
--- a/src/newgrf_gui.cpp	Wed Aug 06 19:00:31 2008 +0000
+++ b/src/newgrf_gui.cpp	Wed Aug 06 20:12:42 2008 +0000
@@ -269,13 +269,13 @@
 	DropDownListPresetItem(int result) : DropDownListItem(result, false) {}
 
 	virtual ~DropDownListPresetItem() {}
-
-	virtual StringID String() const
+	
+	bool Selectable() const
 	{
-		return STR_EMPTY;
+		return true;
 	}
 
-	virtual void Draw(int x, int y, uint width, uint height, bool sel) const
+	void Draw(int x, int y, uint width, uint height, bool sel, int bg_colour) const
 	{
 		DoDrawStringTruncated(_grf_preset_list[this->result], x + 2, y, sel ? TC_WHITE : TC_BLACK, x + width);
 	}