diff options
author | peter1138 <peter1138@openttd.org> | 2008-01-18 10:36:55 +0000 |
---|---|---|
committer | peter1138 <peter1138@openttd.org> | 2008-01-18 10:36:55 +0000 |
commit | 68707808c015db1cda0723882ffce99977d4593c (patch) | |
tree | 4a7f2fbd16bbc5ad48c890141c722273c2efea2e /src/group_gui.cpp | |
parent | b7f50533c29ea74e9973ac641ec677eb69411d5d (diff) | |
download | openttd-68707808c015db1cda0723882ffce99977d4593c.tar.xz |
(svn r11915) -Codechange: Add a function to draw a sort button's up/down arrow. Arrows are now drawn in a consistent position based on the widget, instead of randomly positioned by pixel.
Diffstat (limited to 'src/group_gui.cpp')
-rw-r--r-- | src/group_gui.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/group_gui.cpp b/src/group_gui.cpp index 515ccf77a..28dca4663 100644 --- a/src/group_gui.cpp +++ b/src/group_gui.cpp @@ -466,9 +466,9 @@ static void GroupWndProc(Window *w, WindowEvent *e) DrawStringRightAligned(187, y1 + 1, STR_GROUP_TINY_NUM, (gv->group_sel == g->index) ? TC_WHITE : TC_BLACK); } - /* Draw Matrix Vehicle according to the vehicle list built before */ - DoDrawString(gv->l.flags & VL_DESC ? DOWNARROW : UPARROW, 269, 15, TC_BLACK); + DrawSortButtonState(w, GRP_WIDGET_SORT_BY_ORDER, gv->l.flags & VL_DESC ? SBS_DOWN : SBS_UP); + /* Draw Matrix Vehicle according to the vehicle list built before */ max = min(w->vscroll2.pos + w->vscroll2.cap, gv->l.list_length); for (i = w->vscroll2.pos ; i < max ; ++i) { const Vehicle* v = gv->sort_list[i]; |