summaryrefslogtreecommitdiff
path: root/src/widgets
diff options
context:
space:
mode:
authoralberth <alberth@openttd.org>2009-09-19 11:31:12 +0000
committeralberth <alberth@openttd.org>2009-09-19 11:31:12 +0000
commit116c77c342d0f628235a7f5dbacfbb5bc3fb0829 (patch)
treed2dd74828426b0c82b4dab368e6aff5ff71f3bad /src/widgets
parent9d7fe9bd8688f2d4123dc98e2b222a5be70b306f (diff)
downloadopenttd-116c77c342d0f628235a7f5dbacfbb5bc3fb0829.tar.xz
(svn r17572) -Codechange: Use the Window::GetWidget() function to access nested widgets through the nested_array.
Diffstat (limited to 'src/widgets')
-rw-r--r--src/widgets/dropdown.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widgets/dropdown.cpp b/src/widgets/dropdown.cpp
index e78dc153d..0b010305c 100644
--- a/src/widgets/dropdown.cpp
+++ b/src/widgets/dropdown.cpp
@@ -259,7 +259,7 @@ void ShowDropDownList(Window *w, DropDownList *list, int selected, int button, u
Rect wi_rect;
Colours wi_colour;
if (w->nested_array != NULL) {
- const NWidgetCore *nwi = w->nested_array[button];
+ const NWidgetCore *nwi = w->GetWidget<NWidgetCore>(button);
wi_rect.left = nwi->pos_x;
wi_rect.right = nwi->pos_x + nwi->current_x - 1;
wi_rect.top = nwi->pos_y;