diff options
author | michi_cc <michi_cc@openttd.org> | 2012-04-17 19:44:02 +0000 |
---|---|---|
committer | michi_cc <michi_cc@openttd.org> | 2012-04-17 19:44:02 +0000 |
commit | 6a70abbd998ed5b54d52ddb44b4df8521413185c (patch) | |
tree | 25d404a46a68f3fa314dd27a4b9555ac4bc1a886 /src/widgets | |
parent | ed565853889679a409d601a61d661718ac3498cc (diff) | |
download | openttd-6a70abbd998ed5b54d52ddb44b4df8521413185c.tar.xz |
(svn r24136) -Feature [FS#4465]: Autoreplace vehicles only when they get old. (Vikthor)
Diffstat (limited to 'src/widgets')
-rw-r--r-- | src/widgets/dropdown.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/widgets/dropdown.cpp b/src/widgets/dropdown.cpp index 6f982b5a0..410ec62a4 100644 --- a/src/widgets/dropdown.cpp +++ b/src/widgets/dropdown.cpp @@ -172,7 +172,7 @@ struct DropdownWindow : Window { if (w2 != NULL) { if (w2->nested_array != NULL) { NWidgetCore *nwi2 = w2->GetWidget<NWidgetCore>(this->parent_button); - if (nwi2->type == NWID_BUTTON_DROPDOWN) { + if ((nwi2->type & WWT_MASK) == NWID_BUTTON_DROPDOWN) { nwi2->disp_flags &= ~ND_DROPDOWN_ACTIVE; } else { w2->RaiseWidget(this->parent_button); @@ -358,7 +358,7 @@ void ShowDropDownList(Window *w, DropDownList *list, int selected, int button, u wi_rect.bottom = nwi->pos_y + nwi->current_y - 1; wi_colour = nwi->colour; - if (nwi->type == NWID_BUTTON_DROPDOWN) { + if ((nwi->type & WWT_MASK) == NWID_BUTTON_DROPDOWN) { nwi->disp_flags |= ND_DROPDOWN_ACTIVE; } else { w->LowerWidget(button); |