mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-11 13:10:45 +00:00
(svn r22716) -Fix: Murphy is a bitch
This commit is contained in:
parent
8e134320d6
commit
9ed9ced7ec
@ -108,7 +108,6 @@ struct BuildAirToolbarWindow : Window {
|
|||||||
|
|
||||||
virtual EventState OnKeyPress(uint16 key, uint16 keycode)
|
virtual EventState OnKeyPress(uint16 key, uint16 keycode)
|
||||||
{
|
{
|
||||||
if (!CanBuildVehicleInfrastructure(VEH_AIRCRAFT)) return ES_NOT_HANDLED;
|
|
||||||
int num = CheckHotkeyMatch(airtoolbar_hotkeys, keycode, this);
|
int num = CheckHotkeyMatch(airtoolbar_hotkeys, keycode, this);
|
||||||
if (num == -1) return ES_NOT_HANDLED;
|
if (num == -1) return ES_NOT_HANDLED;
|
||||||
this->OnClick(Point(), num, 1);
|
this->OnClick(Point(), num, 1);
|
||||||
@ -197,6 +196,7 @@ Window *ShowBuildAirToolbar()
|
|||||||
|
|
||||||
EventState AirportToolbarGlobalHotkeys(uint16 key, uint16 keycode)
|
EventState AirportToolbarGlobalHotkeys(uint16 key, uint16 keycode)
|
||||||
{
|
{
|
||||||
|
if (!CanBuildVehicleInfrastructure(VEH_AIRCRAFT)) return ES_NOT_HANDLED;
|
||||||
int num = CheckHotkeyMatch<BuildAirToolbarWindow>(_airtoolbar_hotkeys, keycode, NULL, true);
|
int num = CheckHotkeyMatch<BuildAirToolbarWindow>(_airtoolbar_hotkeys, keycode, NULL, true);
|
||||||
if (num == -1) return ES_NOT_HANDLED;
|
if (num == -1) return ES_NOT_HANDLED;
|
||||||
Window *w = ShowBuildAirToolbar();
|
Window *w = ShowBuildAirToolbar();
|
||||||
|
Loading…
Reference in New Issue
Block a user