From 6767a598276032799fe172a66c4cf214e81b06e0 Mon Sep 17 00:00:00 2001 From: alberth Date: Wed, 15 Jul 2009 23:04:26 +0000 Subject: (svn r16840) -Codechange: Small merge in town directory widget content method. --- src/town_gui.cpp | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'src') diff --git a/src/town_gui.cpp b/src/town_gui.cpp index fd2eb949a..9cf12bc94 100644 --- a/src/town_gui.cpp +++ b/src/town_gui.cpp @@ -647,14 +647,9 @@ public: { Dimension d = {0, 0}; switch (widget) { - case TDW_SORTNAME: { - d = GetStringBoundingBox(STR_SORT_BY_NAME); - d.width += WD_SORTBUTTON_ARROW_WIDTH * 2; // Doubled since the word is centered, also looks nice. - break; - } - + case TDW_SORTNAME: case TDW_SORTPOPULATION: { - d = GetStringBoundingBox(STR_SORT_BY_POPULATION); + d = GetStringBoundingBox(this->nested_array[widget]->widget_data); d.width += WD_SORTBUTTON_ARROW_WIDTH * 2; // Doubled since the word is centered, also looks nice. break; } -- cgit v1.2.3-70-g09d2