From 9ed9ced7ec9c848ef25815be2578785e057afa74 Mon Sep 17 00:00:00 2001 From: planetmaker Date: Thu, 4 Aug 2011 17:22:18 +0000 Subject: [PATCH] (svn r22716) -Fix: Murphy is a bitch --- src/airport_gui.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/airport_gui.cpp b/src/airport_gui.cpp index a4a27a057b..a8feed7a4f 100644 --- a/src/airport_gui.cpp +++ b/src/airport_gui.cpp @@ -108,7 +108,6 @@ struct BuildAirToolbarWindow : Window { virtual EventState OnKeyPress(uint16 key, uint16 keycode) { - if (!CanBuildVehicleInfrastructure(VEH_AIRCRAFT)) return ES_NOT_HANDLED; int num = CheckHotkeyMatch(airtoolbar_hotkeys, keycode, this); if (num == -1) return ES_NOT_HANDLED; this->OnClick(Point(), num, 1); @@ -197,6 +196,7 @@ Window *ShowBuildAirToolbar() EventState AirportToolbarGlobalHotkeys(uint16 key, uint16 keycode) { + if (!CanBuildVehicleInfrastructure(VEH_AIRCRAFT)) return ES_NOT_HANDLED; int num = CheckHotkeyMatch(_airtoolbar_hotkeys, keycode, NULL, true); if (num == -1) return ES_NOT_HANDLED; Window *w = ShowBuildAirToolbar();