]> git.mxchange.org Git - flightgear.git/blob - src/Main/keyboard.cxx
Tweaks and massaging relative to the new waypoint route management system.
[flightgear.git] / src / Main / keyboard.cxx
1 // keyboard.cxx -- handle GLUT keyboard events
2 //
3 // Written by Curtis Olson, started May 1997.
4 //
5 // Copyright (C) 1997 - 1999  Curtis L. Olson  - curt@flightgear.org
6 //
7 // This program is free software; you can redistribute it and/or
8 // modify it under the terms of the GNU General Public License as
9 // published by the Free Software Foundation; either version 2 of the
10 // License, or (at your option) any later version.
11 //
12 // This program is distributed in the hope that it will be useful, but
13 // WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15 // General Public License for more details.
16 //
17 // You should have received a copy of the GNU General Public License
18 // along with this program; if not, write to the Free Software
19 // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20 //
21 // $Id$
22
23
24 #ifdef HAVE_CONFIG_H
25 #  include <config.h>
26 #endif
27
28 #ifdef HAVE_WINDOWS_H
29 #  include <windows.h>                     
30 #endif
31
32 #include <simgear/compiler.h>
33
34 #include <GL/glut.h>
35 #include <simgear/xgl/xgl.h>
36
37 #if defined(FX) && defined(XMESA)
38 #include <GL/xmesa.h>
39 #endif
40
41 #include <stdio.h>
42 #include <stdlib.h>
43
44 #include STL_FSTREAM
45
46 #include <plib/pu.h>            // plib include
47
48 #include <simgear/constants.h>
49 #include <simgear/debug/logstream.hxx>
50 #include <simgear/misc/fgpath.hxx>
51
52 #include <Aircraft/aircraft.hxx>
53 #include <Autopilot/auto_gui.hxx>
54 #include <Autopilot/newauto.hxx>
55 #include <Cockpit/hud.hxx>
56 #include <Cockpit/panel.hxx>
57 #include <Cockpit/panel_io.hxx>
58 #include <GUI/gui.h>
59 #include <Scenery/tilemgr.hxx>
60 #include <Objects/matlib.hxx>
61 #include <Time/light.hxx>
62 #include <Time/tmp.hxx>
63
64 #ifndef FG_OLD_WEATHER
65 #  include <WeatherCM/FGLocalWeatherDatabase.h>
66 #else
67 #  include <Weather/weather.hxx>
68 #endif
69
70 #include "bfi.hxx"
71 #include "globals.hxx"
72 #include "keyboard.hxx"
73 #include "options.hxx"
74 #include "save.hxx"
75 #include "views.hxx"
76
77                                 // From main.cxx
78 extern void fgReshape( int width, int height );
79
80
81 // Handle keyboard events
82 void GLUTkey(unsigned char k, int x, int y) {
83     FGInterface *f;
84     SGTime *t;
85     FGView *v;
86     float fov, tmp;
87     static bool winding_ccw = true;
88     int speed;
89
90     f = current_aircraft.fdm_state;
91     v = &current_view;
92
93     FG_LOG( FG_INPUT, FG_DEBUG, "Key hit = " << k );
94     if ( puKeyboard(k, PU_DOWN) ) {
95         return;
96     }
97
98     if ( GLUT_ACTIVE_ALT && glutGetModifiers() ) {
99         FG_LOG( FG_INPUT, FG_DEBUG, " SHIFTED" );
100         switch (k) {
101         case 1: // Ctrl-A key
102             current_autopilot->set_AltitudeMode( 
103                   FGAutopilot::FG_ALTITUDE_LOCK );
104             current_autopilot->set_AltitudeEnabled(
105                   ! current_autopilot->get_AltitudeEnabled()
106                 );
107             return;
108         case 7: // Ctrl-G key
109             current_autopilot->set_AltitudeMode( 
110                   FGAutopilot::FG_ALTITUDE_GS1 );
111             current_autopilot->set_AltitudeEnabled(
112                   ! current_autopilot->get_AltitudeEnabled()
113                 );
114             return;
115         case 8: // Ctrl-H key
116             current_autopilot->set_HeadingMode( 
117                   FGAutopilot::FG_HEADING_LOCK );
118             current_autopilot->set_HeadingEnabled(
119                   ! current_autopilot->get_HeadingEnabled()
120                 );
121             return;
122         case 14: // Ctrl-N key
123             current_autopilot->set_HeadingMode( 
124                   FGAutopilot::FG_HEADING_NAV1 );
125             current_autopilot->set_HeadingEnabled(
126                   ! current_autopilot->get_HeadingEnabled()
127                 );
128             return;
129         case 18: // Ctrl-R key
130             // temporary
131             winding_ccw = !winding_ccw;
132             if ( winding_ccw ) {
133                 glFrontFace ( GL_CCW );
134             } else {
135                 glFrontFace ( GL_CW );
136             }
137             return;
138         case 19: // Ctrl-S key
139             current_autopilot->set_AutoThrottleEnabled(
140                   ! current_autopilot->get_AutoThrottleEnabled()
141                 );
142             return;
143         case 20: // Ctrl-T key
144             current_autopilot->set_AltitudeMode( 
145                   FGAutopilot::FG_ALTITUDE_TERRAIN );
146             current_autopilot->set_AltitudeEnabled(
147                   ! current_autopilot->get_AltitudeEnabled()
148                 );
149             return;
150         case 21: // Ctrl-U key
151             // add 1000' of emergency altitude.  Possibly good for 
152             // unflipping yourself :-)
153             {
154                 double alt = cur_fdm_state->get_Altitude() + 1000;
155                 fgFDMForceAltitude( current_options.get_flight_model(), 
156                                     alt * FEET_TO_METER );
157             }
158             return;
159         case 49: // numeric keypad 1
160             v->set_goal_view_offset( FG_PI * 0.75 );
161             return;
162         case 50: // numeric keypad 2
163             v->set_goal_view_offset( FG_PI );
164             return;
165         case 51: // numeric keypad 3
166             v->set_goal_view_offset( FG_PI * 1.25 );
167             return;
168         case 52: // numeric keypad 4
169             v->set_goal_view_offset( FG_PI * 0.50 );
170             return;
171         case 54: // numeric keypad 6
172             v->set_goal_view_offset( FG_PI * 1.50 );
173             return;
174         case 55: // numeric keypad 7
175             v->set_goal_view_offset( FG_PI * 0.25 );
176             return;
177         case 56: // numeric keypad 8
178             v->set_goal_view_offset( 0.00 );
179             return;
180         case 57: // numeric keypad 9
181             v->set_goal_view_offset( FG_PI * 1.75 );
182             return;
183         case 65: // A key
184             speed = current_options.get_speed_up();
185             speed--;
186             if ( speed < 1 ) {
187                 speed = 1;
188             }
189             current_options.set_speed_up( speed );
190             return;
191         case 72: // H key
192             // status = current_options.get_hud_status();
193             // current_options.set_hud_status(!status);
194             HUD_brightkey( true );
195             return;
196         case 73: // I key
197             // Minimal Hud
198             fgHUDInit2(&current_aircraft);
199             return;
200         case 77: // M key
201             globals->inc_warp( -60 );
202             fgUpdateSkyAndLightingParams();
203             return;
204         case 80: // P key
205             current_options.toggle_panel();
206             break;
207         case 84: // T key
208             globals->inc_warp_delta( -30 );
209             fgUpdateSkyAndLightingParams();
210             return;
211         case 87: // W key
212 #if defined(FX) && !defined(WIN32)
213             global_fullscreen = ( !global_fullscreen );
214 #  if defined(XMESA_FX_FULLSCREEN) && defined(XMESA_FX_WINDOW)
215             XMesaSetFXmode( global_fullscreen ? 
216                             XMESA_FX_FULLSCREEN : XMESA_FX_WINDOW );
217 #  endif
218 #endif
219             return;
220         case 88: // X key
221             fov = current_options.get_fov();
222             fov *= 1.05;
223             if ( fov > FG_FOV_MAX ) {
224                 fov = FG_FOV_MAX;
225             }
226             current_options.set_fov(fov);
227             v->force_update_fov_math();
228             return;
229         case 90: // Z key
230 #ifndef FG_OLD_WEATHER
231             tmp = WeatherDatabase->getWeatherVisibility();
232             tmp /= 1.10;
233             WeatherDatabase->setWeatherVisibility( tmp );
234 #else
235             tmp = current_weather.get_visibility();   // in meters
236             tmp /= 1.10;
237             current_weather.set_visibility( tmp );
238 #endif
239             return;
240         }
241     } else {
242         FG_LOG( FG_INPUT, FG_DEBUG, "" );
243         switch (k) {
244         case 50: // numeric keypad 2
245             if ( current_autopilot->get_AltitudeEnabled() ) {
246                 current_autopilot->AltitudeAdjust( 100 );
247             } else {
248                 controls.move_elevator(-0.05);
249             }
250             return;
251         case 56: // numeric keypad 8
252             if ( current_autopilot->get_AltitudeEnabled() ) {
253                 current_autopilot->AltitudeAdjust( -100 );
254             } else {
255                 controls.move_elevator(0.05);
256             }
257             return;
258         case 49: // numeric keypad 1
259             controls.move_elevator_trim(-0.001);
260             return;
261         case 55: // numeric keypad 7
262             controls.move_elevator_trim(0.001);
263             return;
264         case 52: // numeric keypad 4
265             controls.move_aileron(-0.05);
266             return;
267         case 54: // numeric keypad 6
268             controls.move_aileron(0.05);
269             return;
270         case 48: // numeric keypad Ins
271             if ( current_autopilot->get_HeadingEnabled() ) {
272                 current_autopilot->HeadingAdjust( -1 );
273             } else {
274                 controls.move_rudder(-0.05);
275             }
276             return;
277         case 13: // numeric keypad Enter
278             if ( current_autopilot->get_HeadingEnabled() ) {
279                 current_autopilot->HeadingAdjust( 1 );
280             } else {
281                 controls.move_rudder(0.05);
282             }
283             return;
284         case 53: // numeric keypad 5
285             controls.set_aileron(0.0);
286             controls.set_elevator(0.0);
287             controls.set_rudder(0.0);
288             return;
289         case 57: // numeric keypad 9 (Pg Up)
290             if ( current_autopilot->get_AutoThrottleEnabled() ) {
291                 current_autopilot->AutoThrottleAdjust( 5 );
292             } else {
293                 controls.move_throttle( FGControls::ALL_ENGINES, 0.01 );
294             }
295             return;
296         case 51: // numeric keypad 3 (Pg Dn)
297             if ( current_autopilot->get_AutoThrottleEnabled() ) {
298                 current_autopilot->AutoThrottleAdjust( -5 );
299             } else {
300                 controls.move_throttle( FGControls::ALL_ENGINES, -0.01 );
301             }
302             return;
303         case 91: // [ key
304             controls.move_flaps(-0.34);
305             FG_LOG( FG_INPUT, FG_INFO,
306                     "Set flaps to " << controls.get_flaps() );
307             return;
308         case 93: // ] key
309             controls.move_flaps(0.34);
310             FG_LOG( FG_INPUT, FG_INFO,
311                     "Set flaps to " << controls.get_flaps() );
312             return;
313         case 97: // a key
314             speed = current_options.get_speed_up();
315             speed++;
316             current_options.set_speed_up( speed );
317             return;
318         case 98: // b key
319             int b_ret;
320             double b_set;
321             b_ret = int( controls.get_brake( 0 ) );
322             b_set = double(!b_ret);
323             controls.set_brake( FGControls::ALL_WHEELS, b_set);
324             return;
325         case 44: // , key
326             if (controls.get_brake(0) > 0.0) {
327                 controls.set_brake(0, 0.0);
328             } else {
329                 controls.set_brake(0, 1.0);
330             }
331             return;
332         case 46: // . key
333             if (controls.get_brake(1) > 0.0) {
334                 controls.set_brake(1, 0.0);
335             } else {
336                 controls.set_brake(1, 1.0);
337             }
338             return;
339         case 104: // h key
340             HUD_masterswitch( true );
341             return;
342         case 105: // i key
343             fgHUDInit(&current_aircraft);  // normal HUD
344             return;
345         case 109: // m key
346             globals->inc_warp( 60 );
347             fgUpdateSkyAndLightingParams();
348             return;
349         case 112: // p key
350             globals->set_freeze( ! globals->get_freeze() );
351
352             {
353                 FGBucket p( f->get_Longitude() * RAD_TO_DEG,
354                             f->get_Latitude() * RAD_TO_DEG );
355                 FGPath tile_path( current_options.get_fg_root() );
356                 tile_path.append( "Scenery" );
357                 tile_path.append( p.gen_base_path() );
358                 tile_path.append( p.gen_index_str() );
359
360                 // printf position and attitude information
361                 FG_LOG( FG_INPUT, FG_INFO,
362                         "Lon = " << f->get_Longitude() * RAD_TO_DEG
363                         << "  Lat = " << f->get_Latitude() * RAD_TO_DEG
364                         << "  Altitude = " << f->get_Altitude() * FEET_TO_METER
365                         );
366                 FG_LOG( FG_INPUT, FG_INFO,
367                         "Heading = " << f->get_Psi() * RAD_TO_DEG 
368                         << "  Roll = " << f->get_Phi() * RAD_TO_DEG
369                         << "  Pitch = " << f->get_Theta() * RAD_TO_DEG );
370                 FG_LOG( FG_INPUT, FG_INFO, tile_path.c_str());
371             }
372             return;
373         case 116: // t key
374             globals->inc_warp_delta( 30 );
375             fgUpdateSkyAndLightingParams();
376             return;
377         case 118: // v key
378             current_options.cycle_view_mode();
379             return;
380         case 120: // x key
381             fov = current_options.get_fov();
382             fov /= 1.05;
383             if ( fov < FG_FOV_MIN ) {
384                 fov = FG_FOV_MIN;
385             }
386             current_options.set_fov(fov);
387             v->force_update_fov_math();
388             return;
389         case 122: // z key
390 #ifndef FG_OLD_WEATHER
391             tmp = WeatherDatabase->getWeatherVisibility();
392             tmp *= 1.10;
393             WeatherDatabase->setWeatherVisibility( tmp );
394 #else
395             tmp = current_weather.get_visibility();   // in meters
396             tmp *= 1.10;
397             current_weather.set_visibility( tmp );
398 #endif
399             return;
400         case 27: // ESC
401             // if( fg_DebugOutput ) {
402             //   fclose( fg_DebugOutput );
403             // }
404             FG_LOG( FG_INPUT, FG_ALERT, 
405                     "Program exit requested." );
406             ConfirmExitDialog();
407             return;
408         }
409     }
410 }
411
412
413 // Handle "special" keyboard events
414 void GLUTspecialkey(int k, int x, int y) {
415     FGView *v;
416
417     v = &current_view;
418
419     FG_LOG( FG_INPUT, FG_DEBUG, "Special key hit = " << k );
420
421     if ( puKeyboard(k + PU_KEY_GLUT_SPECIAL_OFFSET, PU_DOWN) ) {
422         return;
423     }
424
425     if ( GLUT_ACTIVE_SHIFT && glutGetModifiers() ) {
426         FG_LOG( FG_INPUT, FG_DEBUG, " SHIFTED" );
427         switch (k) {
428         case GLUT_KEY_F1: {
429             ifstream input("fgfs.sav");
430             if (input.good() && fgLoadFlight(input)) {
431                 input.close();
432                 FG_LOG(FG_INPUT, FG_INFO, "Restored flight from fgfs.sav");
433             } else {
434                 FG_LOG(FG_INPUT, FG_ALERT, "Cannot load flight from fgfs.sav");
435             }
436             return;
437         }
438         case GLUT_KEY_F2: {
439             FG_LOG(FG_INPUT, FG_INFO, "Saving flight");
440             ofstream output("fgfs.sav");
441             if (output.good() && fgSaveFlight(output)) {
442                 output.close();
443                 FG_LOG(FG_INPUT, FG_INFO, "Saved flight to fgfs.sav");
444             } else {
445                 FG_LOG(FG_INPUT, FG_ALERT, "Cannot save flight to fgfs.sav");
446             }
447             return;
448         }
449         case GLUT_KEY_F3: {
450           string panel_path =
451             current_properties.getStringValue("/sim/panel/path",
452                                               "Panels/Default/default.xml");
453           FGPanel * new_panel = fgReadPanel(panel_path);
454           if (new_panel == 0) {
455             FG_LOG(FG_INPUT, FG_ALERT,
456                    "Error reading new panel from " << panel_path);
457             return;
458           }
459           FG_LOG(FG_INPUT, FG_INFO, "Loaded new panel from " << panel_path);
460           delete current_panel;
461           current_panel = new_panel;
462           return;
463         }
464         case GLUT_KEY_F4: {
465           FGPath props_path(current_options.get_fg_root());
466           props_path.append("preferences.xml");
467           FG_LOG(FG_INPUT, FG_INFO, "Rereading global preferences");
468           if (!readPropertyList(props_path.str(), &current_properties)) {
469             FG_LOG(FG_INPUT, FG_ALERT,
470                    "Failed to reread global preferences from "
471                    << props_path.str());
472           } else {
473             FG_LOG(FG_INPUT, FG_INFO, "Finished Reading global preferences");
474           }
475           return;
476         }
477         case GLUT_KEY_F5: {
478           current_panel->setYOffset(current_panel->getYOffset() - 5);
479           fgReshape(current_view.get_winWidth(),
480                     current_view.get_winHeight());
481           return;
482         }
483         case GLUT_KEY_F6: {
484           current_panel->setYOffset(current_panel->getYOffset() + 5);
485           fgReshape(current_view.get_winWidth(),
486                     current_view.get_winHeight());
487           return;
488         }
489         case GLUT_KEY_F7: {
490           current_panel->setXOffset(current_panel->getXOffset() - 5);
491           return;
492         }
493         case GLUT_KEY_F8: {
494           current_panel->setXOffset(current_panel->getXOffset() + 5);
495           return;
496         }
497         case GLUT_KEY_END: // numeric keypad 1
498             v->set_goal_view_offset( FG_PI * 0.75 );
499             return;
500         case GLUT_KEY_DOWN: // numeric keypad 2
501             v->set_goal_view_offset( FG_PI );
502             return;
503         case GLUT_KEY_PAGE_DOWN: // numeric keypad 3
504             v->set_goal_view_offset( FG_PI * 1.25 );
505             return;
506         case GLUT_KEY_LEFT: // numeric keypad 4
507             v->set_goal_view_offset( FG_PI * 0.50 );
508             return;
509         case GLUT_KEY_RIGHT: // numeric keypad 6
510             v->set_goal_view_offset( FG_PI * 1.50 );
511             return;
512         case GLUT_KEY_HOME: // numeric keypad 7
513             v->set_goal_view_offset( FG_PI * 0.25 );
514             return;
515         case GLUT_KEY_UP: // numeric keypad 8
516             v->set_goal_view_offset( 0.00 );
517             return;
518         case GLUT_KEY_PAGE_UP: // numeric keypad 9
519             v->set_goal_view_offset( FG_PI * 1.75 );
520             return;
521         }
522     } else {
523         FG_LOG( FG_INPUT, FG_DEBUG, "" );
524         switch (k) {
525         case GLUT_KEY_F2: // F2 Reload Tile Cache...
526             {
527                 bool freeze;
528                 FG_LOG(FG_INPUT, FG_INFO, "ReIniting TileCache");
529                 if ( !freeze ) 
530                     globals->set_freeze( true );
531                 BusyCursor(0);
532                 if ( global_tile_mgr.init() ) {
533                     // Load the local scenery data
534                     global_tile_mgr.update( 
535                         cur_fdm_state->get_Longitude() * RAD_TO_DEG,
536                         cur_fdm_state->get_Latitude() * RAD_TO_DEG );
537                 } else {
538                     FG_LOG( FG_GENERAL, FG_ALERT, 
539                             "Error in Tile Manager initialization!" );
540                     exit(-1);
541                 }
542                 BusyCursor(1);
543                 if ( !freeze )
544                    globals->set_freeze( false );
545                 return;
546             }
547         case GLUT_KEY_F3: // F3 Take a screen shot
548             fgDumpSnapShot();
549             return;
550         case GLUT_KEY_F6: // F6 toggles Autopilot target location
551             if ( current_autopilot->get_HeadingMode() !=
552                  FGAutopilot::FG_HEADING_WAYPOINT ) {
553                 current_autopilot->set_HeadingMode(
554                     FGAutopilot::FG_HEADING_WAYPOINT );
555                 current_autopilot->set_HeadingEnabled( true );
556             } else {
557                 current_autopilot->set_HeadingMode(
558                     FGAutopilot::FG_HEADING_LOCK );
559             }
560             return;
561         case GLUT_KEY_F8: // F8 toggles fog ... off fastest nicest...
562             current_options.cycle_fog();
563         
564             if ( current_options.get_fog() == fgOPTIONS::FG_FOG_DISABLED ) {
565                 FG_LOG( FG_INPUT, FG_INFO, "Fog disabled" );
566             } else if ( current_options.get_fog() == 
567                         fgOPTIONS::FG_FOG_FASTEST )
568             {
569                 FG_LOG( FG_INPUT, FG_INFO, 
570                         "Fog enabled, hint set to fastest" );
571             } else if ( current_options.get_fog() ==
572                         fgOPTIONS::FG_FOG_NICEST )
573             {
574                 FG_LOG( FG_INPUT, FG_INFO,
575                         "Fog enabled, hint set to nicest" );
576             }
577
578             return;
579         case GLUT_KEY_F9: // F9 toggles textures on and off...
580             FG_LOG( FG_INPUT, FG_INFO, "Toggling texture" );
581             if ( current_options.get_textures() ) {
582                 current_options.set_textures( false );
583                 material_lib.set_step( 1 );
584             } else {
585                 current_options.set_textures( true );
586                 material_lib.set_step( 0 );
587             }
588             return;
589         case GLUT_KEY_F10: // F10 toggles menu on and off...
590             FG_LOG(FG_INPUT, FG_INFO, "Invoking call back function");
591             guiToggleMenu();
592             return;
593         case GLUT_KEY_F11: // F11 Altitude Dialog.
594             FG_LOG(FG_INPUT, FG_INFO, "Invoking Altitude call back function");
595             NewAltitude( NULL );
596             return;
597         case GLUT_KEY_F12: // F12 Heading Dialog...
598             FG_LOG(FG_INPUT, FG_INFO, "Invoking Heading call back function");
599             NewHeading( NULL );
600             return;
601         case GLUT_KEY_UP:
602             if ( current_autopilot->get_AltitudeEnabled() ) {
603                 current_autopilot->AltitudeAdjust( -100 );
604             } else {
605                 controls.move_elevator(0.05);
606             }
607             return;
608         case GLUT_KEY_DOWN:
609             if ( current_autopilot->get_AltitudeEnabled() ) {
610                 current_autopilot->AltitudeAdjust( 100 );
611             } else {
612                 controls.move_elevator(-0.05);
613             }
614             return;
615         case GLUT_KEY_LEFT:
616             controls.move_aileron(-0.05);
617             return;
618         case GLUT_KEY_RIGHT:
619             controls.move_aileron(0.05);
620             return;
621         case GLUT_KEY_HOME: // numeric keypad 1
622             controls.move_elevator_trim(0.001);
623             return;
624         case GLUT_KEY_END: // numeric keypad 7
625             controls.move_elevator_trim(-0.001);
626             return;
627         case GLUT_KEY_INSERT: // numeric keypad Ins
628             if ( current_autopilot->get_HeadingEnabled() ) {
629                 current_autopilot->HeadingAdjust( -1 );
630             } else {
631                 controls.move_rudder(-0.05);
632             }
633             return;
634         case 13: // numeric keypad Enter
635             if ( current_autopilot->get_HeadingEnabled() ) {
636                 current_autopilot->HeadingAdjust( 1 );
637             } else {
638                 controls.move_rudder(0.05);
639             }
640             return;
641         case 53: // numeric keypad 5
642             controls.set_aileron(0.0);
643             controls.set_elevator(0.0);
644             controls.set_rudder(0.0);
645             return;
646         case GLUT_KEY_PAGE_UP: // numeric keypad 9 (Pg Up)
647             if ( current_autopilot->get_AutoThrottleEnabled() ) {
648                 current_autopilot->AutoThrottleAdjust( 5 );
649             } else {
650                 controls.move_throttle( FGControls::ALL_ENGINES, 0.01 );
651             }
652             return;
653         case GLUT_KEY_PAGE_DOWN: // numeric keypad 3 (Pg Dn)
654             if ( current_autopilot->get_AutoThrottleEnabled() ) {
655                 current_autopilot->AutoThrottleAdjust( -5 );
656             } else {
657                 controls.move_throttle( FGControls::ALL_ENGINES, -0.01 );
658             }
659             return;
660         }
661     }
662 }
663
664