Index: order_gui.cpp =================================================================== --- order_gui.cpp (revision 27096) +++ order_gui.cpp (working copy) @@ -427,6 +427,7 @@ OHK_TRANSFER, OHK_NO_UNLOAD, OHK_NO_LOAD, + OHK_CLOSE, }; /** @@ -1423,6 +1424,11 @@ virtual EventState OnHotkey(int hotkey) { if (this->vehicle->owner != _local_company) return ES_NOT_HANDLED; + if(hotkey == OHK_GOTO && this->goto_type != OPOS_NONE){ + this->RaiseWidget(WID_O_GOTO); + ResetObjectToPlace(); + return ES_NOT_HANDLED; + } switch (hotkey) { case OHK_SKIP: this->OrderClick_Skip(); break; @@ -1436,6 +1442,7 @@ case OHK_TRANSFER: this->OrderHotkey_Transfer(); break; case OHK_NO_UNLOAD: this->OrderHotkey_NoUnload(); break; case OHK_NO_LOAD: this->OrderHotkey_NoLoad(); break; + case OHK_CLOSE: delete this; break; default: return ES_NOT_HANDLED; } return ES_HANDLED; @@ -1525,6 +1532,7 @@ Hotkey((uint16)0, "transfer", OHK_TRANSFER), Hotkey((uint16)0, "no_unload", OHK_NO_UNLOAD), Hotkey((uint16)0, "no_load", OHK_NO_LOAD), + Hotkey('Q', "close", OHK_CLOSE), HOTKEY_LIST_END }; HotkeyList OrdersWindow::hotkeys("order", order_hotkeys);