| 260 | } |
| 261 | |
| 262 | void OnClick([[maybe_unused]] Point pt, WidgetID widget, [[maybe_unused]] int click_count) override |
| 263 | { |
| 264 | switch (widget) { |
| 265 | default: break; |
| 266 | case WID_BBS_BRIDGE_LIST: { |
| 267 | auto it = this->vscroll->GetScrolledItemFromWidget(this->bridges, pt.y, this, WID_BBS_BRIDGE_LIST); |
| 268 | if (it != this->bridges.end()) { |
| 269 | this->BuildBridge(it->index); |
| 270 | this->Close(); |
| 271 | } |
| 272 | break; |
| 273 | } |
| 274 | |
| 275 | case WID_BBS_DROPDOWN_ORDER: |
| 276 | this->bridges.ToggleSortOrder(); |
| 277 | this->SetDirty(); |
| 278 | break; |
| 279 | |
| 280 | case WID_BBS_DROPDOWN_CRITERIA: |
| 281 | ShowDropDownMenu(this, BuildBridgeWindow::sorter_names, this->bridges.SortType(), WID_BBS_DROPDOWN_CRITERIA, 0, 0); |
| 282 | break; |
| 283 | } |
| 284 | } |
| 285 | |
| 286 | void OnDropdownSelect(WidgetID widget, int index, int) override |
| 287 | { |
nothing calls this directly
no test coverage detected