forked from mirror/OpenTTD
(svn r12953) -Feature: Open a new viewport when ctrl-clicking on a 'Location' button, a town/station/industry list, or some news items.
This commit is contained in:
@@ -206,8 +206,15 @@ static void NewsWindowProc(Window *w, WindowEvent *e)
|
||||
Vehicle *v = GetVehicle(ni->data_a);
|
||||
ScrollMainWindowTo(v->x_pos, v->y_pos);
|
||||
} else if (ni->flags & NF_TILE) {
|
||||
if (!ScrollMainWindowToTile(ni->data_a) && ni->data_b != 0) {
|
||||
ScrollMainWindowToTile(ni->data_b);
|
||||
if (_ctrl_pressed) {
|
||||
ShowExtraViewPortWindow(ni->data_a);
|
||||
if (ni->data_b != 0) {
|
||||
ShowExtraViewPortWindow(ni->data_b);
|
||||
}
|
||||
} else {
|
||||
if (!ScrollMainWindowToTile(ni->data_a) && ni->data_b != 0) {
|
||||
ScrollMainWindowToTile(ni->data_b);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
Reference in New Issue
Block a user