1 /**************************************************************************
4 * Based on gui.cxx and renamed on 2002/08/13 by Erik Hofman.
6 * Written 1998 by Durk Talsma, started Juni, 1998. For the flight gear
9 * Additional mouse supported added by David Megginson, 1999.
11 * This program is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU General Public License as
13 * published by the Free Software Foundation; either version 2 of the
14 * License, or (at your option) any later version.
16 * This program is distributed in the hope that it will be useful, but
17 * WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * General Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with this program; if not, write to the Free Software
23 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
26 **************************************************************************/
33 #include <simgear/compiler.h>
35 #ifdef SG_MATH_EXCEPTION_CLASH
45 #if defined(FX) && defined(XMESA)
46 # include <GL/xmesa.h>
57 # include <shellapi.h>
59 # include <sys/cygwin.h>
63 #include <simgear/constants.h>
64 #include <simgear/debug/logstream.hxx>
65 #include <simgear/misc/sg_path.hxx>
66 #include <simgear/screen/screen-dump.hxx>
68 #include <Include/general.hxx>
69 #include <Aircraft/aircraft.hxx>
70 #include <Airports/simple.hxx>
71 #include <Autopilot/auto_gui.hxx>
72 #include <Cockpit/panel.hxx>
73 #include <Controls/controls.hxx>
74 #include <FDM/flight.hxx>
75 #include <Main/main.hxx>
76 #include <Main/fg_init.hxx>
77 #include <Main/fg_io.hxx>
78 #include <Main/globals.hxx>
79 #include <Main/fg_props.hxx>
80 #include <Main/viewmgr.hxx>
82 #if defined( WIN32 ) && !defined( __CYGWIN__ ) && !defined(__MINGW32__)
83 # include <simgear/screen/win32-printer.h>
84 # include <simgear/screen/GlBitmaps.h>
88 #include "gui_local.hxx"
89 #include "preset_dlg.hxx"
90 #include "prop_picker.hxx"
91 #include "sgVec3Slider.hxx"
96 extern void fgHUDalphaAdjust( puObject * );
99 extern void fgLatLonFormatToggle( puObject *);
101 #if defined( TR_HIRES_SNAP)
102 #include <simgear/screen/tr.h>
103 extern void fgUpdateHUD( GLfloat x_start, GLfloat y_start,
104 GLfloat x_end, GLfloat y_end );
107 puDialogBox *dialogBox = 0;
108 puFrame *dialogFrame = 0;
109 puText *dialogBoxMessage = 0;
110 puOneShot *dialogBoxOkButton = 0;
112 puDialogBox *YNdialogBox = 0;
113 puFrame *YNdialogFrame = 0;
114 puText *YNdialogBoxMessage = 0;
115 puOneShot *YNdialogBoxOkButton = 0;
116 puOneShot *YNdialogBoxNoButton = 0;
118 char *gui_msg_OK; // "OK"
119 char *gui_msg_NO; // "NO"
120 char *gui_msg_YES; // "YES"
121 char *gui_msg_CANCEL; // "CANCEL"
122 char *gui_msg_RESET; // "RESET"
124 char msg_OK[] = "OK";
125 char msg_NO[] = "NO";
126 char msg_YES[] = "YES";
127 char msg_CANCEL[] = "Cancel";
128 char msg_RESET[] = "Reset";
130 char global_dialog_string[256];
132 const __fg_gui_fn_t __fg_gui_fn[] = {
135 {"saveFlight", saveFlight},
136 {"loadFlight", loadFlight},
139 {"dumpHiResSnapShot", dumpHiResSnapShot},
141 {"dumpSnapShot", dumpSnapShot},
142 #if defined( WIN32 ) && !defined( __CYGWIN__) && !defined(__MINGW32__)
143 {"printScreen", printScreen},
145 {"MayBeGoodBye", MayBeGoodBye},
148 {"guiTogglePanel", guiTogglePanel},
149 {"PilotOffsetAdjust", PilotOffsetAdjust},
150 {"fgHUDalphaAdjust", fgHUDalphaAdjust},
151 {"prop_pickerView", prop_pickerView},
154 {"fgPresetAirport", fgPresetAirport},
155 {"fgPresetRunway", fgPresetRunway},
156 {"fgPresetOffsetDistance", fgPresetOffsetDistance},
157 {"fgPresetAltitude", fgPresetAltitude},
158 {"fgPresetGlideslope", fgPresetGlideslope},
159 {"fgPresetAirspeed", fgPresetAirspeed},
160 {"fgPresetCommit", fgPresetCommit},
163 {"NewAltitude", NewAltitude},
164 {"NewHeading", NewHeading},
165 {"AddWayPoint", AddWayPoint},
166 {"PopWayPoint", PopWayPoint},
167 {"ClearRoute", ClearRoute},
168 {"fgLatLonFormatToggle", fgLatLonFormatToggle},
173 // Structure termination
178 /* ================ General Purpose Functions ================ */
180 void initDialog(void) {
181 // Initialize our GLOBAL GUI STRINGS
182 gui_msg_OK = msg_OK; // "OK"
183 gui_msg_NO = msg_NO; // "NO"
184 gui_msg_YES = msg_YES; // "YES"
185 gui_msg_CANCEL = msg_CANCEL; // "CANCEL"
186 gui_msg_RESET = msg_RESET; // "RESET"
189 // General Purpose Message Box
190 void mkDialog (const char *txt)
192 strncpy(global_dialog_string, txt, 256);
193 dialogBoxMessage->setLabel(global_dialog_string);
194 FG_PUSH_PUI_DIALOG( dialogBox );
197 // Message Box to report an error.
198 void guiErrorMessage (const char *txt)
200 SG_LOG(SG_GENERAL, SG_ALERT, txt);
205 // Message Box to report a throwable (usually an exception).
206 void guiErrorMessage (const char *txt, const sg_throwable &throwable)
210 msg += throwable.getFormattedMessage();
211 if (!throwable.getOrigin().empty()) {
212 msg += "\n (reported by ";
213 msg += throwable.getOrigin();
216 SG_LOG(SG_GENERAL, SG_ALERT, msg);
218 mkDialog(msg.c_str());
221 // Intercept the Escape Key
222 void ConfirmExitDialog(void)
224 FG_PUSH_PUI_DIALOG( YNdialogBox );
229 /* -----------------------------------------------------------------------
230 the Gui callback functions
231 ____________________________________________________________________*/
234 // Hier Neu :-) This is my newly added code
235 // Added by David Findlay <nedz@bigpond.com>
236 // on Sunday 3rd of December
238 // Start new Save Dialog Box
239 puDialogBox *SaveDialog = 0;
240 puFrame *SaveDialogFrame = 0;
241 puText *SaveDialogMessage = 0;
242 puInput *SaveDialogInput = 0;
244 puOneShot *SaveDialogOkButton = 0;
245 puOneShot *SaveDialogCancelButton = 0;
246 // static puOneShot *SaveDialogResetButton = 0;
248 // Default save filename
249 char saveFile[256] = "fgfs.sav";
252 void SaveDialogCancel(puObject *) {
253 FG_POP_PUI_DIALOG( SaveDialog );
256 // If press OK do this
257 void SaveDialogOk(puObject*) {
259 FG_POP_PUI_DIALOG( SaveDialog );
262 SaveDialogInput->getValue(&s);
265 // cout << saveFile << endl;
266 if (output.good() && fgSaveFlight(output)) {
268 mkDialog("Saved flight");
269 SG_LOG(SG_INPUT, SG_INFO, "Saved flight");
271 mkDialog("Cannot save flight");
272 SG_LOG(SG_INPUT, SG_ALERT, "Cannot save flight");
277 void saveFlight(puObject *cv) {
278 SaveDialog = new puDialogBox (150, 50);
280 SaveDialogFrame = new puFrame (0,0,350, 150);
282 = new puText( (150 - puGetDefaultLabelFont().getStringWidth( "File Name:" ) / 2), 110 );
283 SaveDialogMessage -> setLabel ("File Name:");
285 SaveDialogInput = new puInput (50, 70, 300, 100);
286 SaveDialogInput -> setValue (saveFile);
287 SaveDialogInput -> acceptInput();
289 SaveDialogOkButton = new puOneShot (50, 10, 110, 50);
290 SaveDialogOkButton -> setLegend (gui_msg_OK);
291 SaveDialogOkButton -> setCallback ( SaveDialogOk );
292 SaveDialogOkButton -> makeReturnDefault(TRUE);
294 SaveDialogCancelButton = new puOneShot (140, 10, 210, 50);
295 SaveDialogCancelButton -> setLegend (gui_msg_CANCEL);
296 SaveDialogCancelButton -> setCallback ( SaveDialogCancel );
298 FG_FINALIZE_PUI_DIALOG( SaveDialog );
300 SaveDialog -> reveal();
304 puDialogBox *LoadDialog = 0;
305 puFrame *LoadDialogFrame = 0;
306 puText *LoadDialogMessage = 0;
307 puInput *LoadDialogInput = 0;
309 puOneShot *LoadDialogOkButton = 0;
310 puOneShot *LoadDialogCancelButton = 0;
311 // static puOneShot *LoadDialogResetButton = 0;
313 // Default load filename
314 char loadFile[256] = "fgfs.sav";
316 // Do this if the person click okay
317 void LoadDialogOk(puObject *) {
319 FG_POP_PUI_DIALOG( LoadDialog );
322 LoadDialogInput->getValue(&l);
325 if (input.good() && fgLoadFlight(input)) {
327 mkDialog("Loaded flight");
328 SG_LOG(SG_INPUT, SG_INFO, "Restored flight");
330 mkDialog("Failed to load flight");
331 SG_LOG(SG_INPUT, SG_ALERT, "Cannot load flight");
335 // Do this if the person presses cancel
336 void LoadDialogCancel(puObject *) {
337 FG_POP_PUI_DIALOG( LoadDialog );
340 // Create Load Dialog
341 void loadFlight(puObject *cb)
343 LoadDialog = new puDialogBox (150, 50);
345 LoadDialogFrame = new puFrame (0,0,350, 150);
347 = new puText( (150 - puGetDefaultLabelFont().getStringWidth( "File Name:" ) / 2), 110 );
348 LoadDialogMessage -> setLabel ("File Name:");
350 LoadDialogInput = new puInput (50, 70, 300, 100);
351 LoadDialogInput -> setValue (loadFile);
352 LoadDialogInput -> acceptInput();
354 LoadDialogOkButton = new puOneShot (50, 10, 110, 50);
355 LoadDialogOkButton -> setLegend (gui_msg_OK);
356 LoadDialogOkButton -> setCallback ( LoadDialogOk );
357 LoadDialogOkButton -> makeReturnDefault(TRUE);
359 LoadDialogCancelButton = new puOneShot (140, 10, 210, 50);
360 LoadDialogCancelButton -> setLegend (gui_msg_CANCEL);
361 LoadDialogCancelButton -> setCallback ( LoadDialogCancel );
363 FG_FINALIZE_PUI_DIALOG( LoadDialog );
365 LoadDialog -> reveal();
368 // This is the accessor function
369 void guiTogglePanel(puObject *cb)
371 if (fgGetBool("/sim/panel/visibility"))
372 fgSetBool("/sim/panel/visibility", false);
374 fgSetBool("/sim/panel/visibility", true);
376 globals->get_renderer()->resize(fgGetInt("/sim/startup/xsize"),
377 fgGetInt("/sim/startup/ysize"));
380 void goodBye(puObject *)
382 // SG_LOG( SG_INPUT, SG_ALERT,
383 // "Program exiting normally at user request." );
384 cout << "Program exiting normally at user request." << endl;
386 // close all external I/O connections
387 globals->get_io()->shutdown_all();
393 void goAwayCb (puObject *me)
395 FG_POP_PUI_DIALOG( dialogBox );
398 void mkDialogInit (void)
400 // printf("mkDialogInit\n");
401 int x = (fgGetInt("/sim/startup/xsize")/2 - 400/2);
402 int y = (fgGetInt("/sim/startup/ysize")/2 - 100/2);
403 dialogBox = new puDialogBox (x, y); // 150, 50
405 dialogFrame = new puFrame (0,0,400,100);
406 dialogBoxMessage = new puText (10, 70);
407 dialogBoxMessage -> setLabel ("");
408 dialogBoxOkButton = new puOneShot (180, 10, 240, 50);
409 dialogBoxOkButton -> setLegend (gui_msg_OK);
410 dialogBoxOkButton -> makeReturnDefault (TRUE );
411 dialogBoxOkButton -> setCallback (goAwayCb);
413 FG_FINALIZE_PUI_DIALOG( dialogBox );
416 void MayBeGoodBye(puObject *)
421 void goAwayYesNoCb(puObject *me)
423 FG_POP_PUI_DIALOG( YNdialogBox);
426 void ConfirmExitDialogInit(void)
428 char msg[] = "Really Quit";
431 // printf("ConfirmExitDialogInit\n");
432 int len = 200 - puGetDefaultLabelFont().getStringWidth ( msg ) / 2;
434 int x = (fgGetInt("/sim/startup/xsize")/2 - 400/2);
435 int y = (fgGetInt("/sim/startup/ysize")/2 - 100/2);
437 YNdialogBox = new puDialogBox (x, y); // 150, 50
439 YNdialogFrame = new puFrame (0,0,400, 100);
441 YNdialogBoxMessage = new puText (len, 70);
442 YNdialogBoxMessage -> setDefaultValue (msg);
443 YNdialogBoxMessage -> getDefaultValue (&s);
444 YNdialogBoxMessage -> setLabel (s);
446 YNdialogBoxOkButton = new puOneShot (100, 10, 160, 50);
447 YNdialogBoxOkButton -> setLegend (gui_msg_OK);
448 YNdialogBoxOkButton -> makeReturnDefault (TRUE );
449 YNdialogBoxOkButton -> setCallback (goodBye);
451 YNdialogBoxNoButton = new puOneShot (240, 10, 300, 50);
452 YNdialogBoxNoButton -> setLegend (gui_msg_NO);
453 YNdialogBoxNoButton -> setCallback (goAwayYesNoCb);
455 FG_FINALIZE_PUI_DIALOG( YNdialogBox );
458 void notCb (puObject *)
460 mkDialog ("This function isn't implemented yet");
463 void helpCb (puObject *)
467 #if defined(FX) && !defined(WIN32)
468 # if defined(XMESA_FX_FULLSCREEN) && defined(XMESA_FX_WINDOW)
469 if ( globals->get_fullscreen() ) {
470 globals->set_fullscreen(false);
471 XMesaSetFXmode( XMESA_FX_WINDOW );
476 SGPath path( globals->get_fg_root() );
477 path.append( "Docs/index.html" );
481 string help_app = fgGetString("/sim/startup/browser-app");
483 if ( system("xwininfo -name Netscape > /dev/null 2>&1") == 0 ) {
484 command = help_app + " -remote \"openURL(" + path.str() + ")\"";
486 command = help_app + " " + path.str();
489 system( command.c_str() );
493 // Look for favorite browser
494 char Dummy[1024], ExecName[1024], browserParameter[1024];
495 char win32_name[1024];
497 cygwin32_conv_to_full_win32_path(path.c_str(),win32_name);
499 strcpy(win32_name,path.c_str());
502 FindExecutable(win32_name, Dummy, ExecName);
503 sprintf(browserParameter, "file:///%s", win32_name);
504 ShellExecute ( NULL, "open", ExecName, browserParameter, Dummy,
509 mkDialog ("Help started in your web browser window.");
512 #if defined( TR_HIRES_SNAP)
517 bool show_pu_cursor = false;
518 char *filename = new char [24];
519 static int count = 1;
521 static const SGPropertyNode *master_freeze
522 = fgGetNode("/sim/freeze/master");
524 bool freeze = master_freeze->getBoolValue();
526 fgSetBool("/sim/freeze/master", true);
529 if ( !puCursorIsHidden() ) {
530 show_pu_cursor = true;
534 FGRenderer *renderer = globals->get_renderer();
536 renderer->resize( fgGetInt("/sim/startup/xsize"),
537 fgGetInt("/sim/startup/ysize") );
539 // we need two render frames here to clear the menu and cursor
540 // ... not sure why but doing an extra fgRenderFrame() shouldn't
542 renderer->update( 0.0 );
543 renderer->update( 0.0 );
545 // Make sure we have SSG projection primed for current view
546 glMatrixMode(GL_MODELVIEW);
548 ssgSetCamera( (sgVec4 *)globals->get_current_view()->get_VIEW() );
549 ssgSetFOV( globals->get_current_view()->get_h_fov(),
550 globals->get_current_view()->get_v_fov() );
551 // ssgSetNearFar( 10.0f, 120000.0f );
552 ssgSetNearFar( 0.5f, 1200000.0f );
555 // This ImageSize stuff is a temporary hack
556 // should probably use 128x128 tile size and
557 // support any image size
559 // This should be a requester to get multiplier from user
561 int width = fgGetInt("/sim/startup/xsize");
562 int height = fgGetInt("/sim/startup/ysize");
564 /* allocate buffer large enough to store one tile */
565 GLubyte *tile = (GLubyte *)malloc(width * height * 3 * sizeof(GLubyte));
567 printf("Malloc of tile buffer failed!\n");
571 int imageWidth = multiplier*width;
572 int imageHeight = multiplier*height;
574 /* allocate buffer to hold a row of tiles */
576 = (GLubyte *)malloc(imageWidth * height * 3 * sizeof(GLubyte));
579 printf("Malloc of tile row buffer failed!\n");
582 TRcontext *tr = trNew();
583 trTileSize(tr, width, height, 0);
584 trTileBuffer(tr, GL_RGB, GL_UNSIGNED_BYTE, tile);
585 trImageSize(tr, imageWidth, imageHeight);
586 trRowOrder(tr, TR_TOP_TO_BOTTOM);
587 sgFrustum *frustum = ssgGetFrustum();
589 frustum->getLeft(), frustum->getRight(),
590 frustum->getBot(), frustum->getTop(),
591 frustum->getNear(), frustum->getFar());
593 /* Prepare ppm output file */
594 while (count < 1000) {
595 snprintf(filename, 24, "fgfs-screen-%03d.ppm", count++);
596 if ( (f = fopen(filename, "r")) == NULL )
600 f = fopen(filename, "wb");
602 printf("Couldn't open image file: %s\n", filename);
608 fprintf(f,"# ppm-file created by %s\n", "trdemo2");
609 fprintf(f,"%i %i\n", imageWidth, imageHeight);
612 /* just to be safe... */
613 glPixelStorei(GL_PACK_ALIGNMENT, 1);
615 /* Because the HUD and Panel change the ViewPort we will
616 * need to handle some lowlevel stuff ourselves */
617 int ncols = trGet(tr, TR_COLUMNS);
618 int nrows = trGet(tr, TR_ROWS);
620 bool do_hud = fgGetBool("/sim/hud/visibility");
621 GLfloat hud_col_step = 640.0 / ncols;
622 GLfloat hud_row_step = 480.0 / nrows;
624 bool do_panel = fgPanelVisible();
625 GLfloat panel_col_step = globals->get_current_panel()->getWidth() / ncols;
626 GLfloat panel_row_step = globals->get_current_panel()->getHeight() / nrows;
632 int curColumn = trGet(tr, TR_CURRENT_COLUMN);
633 int curRow = trGet(tr, TR_CURRENT_ROW);
634 globals->get_renderer()->screendump();
636 fgUpdateHUD( curColumn*hud_col_step, curRow*hud_row_step,
637 (curColumn+1)*hud_col_step, (curRow+1)*hud_row_step );
639 globals->get_current_panel()->update(
640 curColumn*panel_col_step, panel_col_step,
641 curRow*panel_row_step, panel_row_step );
642 more = trEndTile(tr);
644 /* save tile into tile row buffer*/
645 int curTileWidth = trGet(tr, TR_CURRENT_TILE_WIDTH);
646 int bytesPerImageRow = imageWidth * 3*sizeof(GLubyte);
647 int bytesPerTileRow = (width) * 3*sizeof(GLubyte);
648 int xOffset = curColumn * bytesPerTileRow;
649 int bytesPerCurrentTileRow = (curTileWidth) * 3*sizeof(GLubyte);
651 for (i=0;i<height;i++) {
652 memcpy(buffer + i*bytesPerImageRow + xOffset, /* Dest */
653 tile + i*bytesPerTileRow, /* Src */
654 bytesPerCurrentTileRow); /* Byte count*/
657 if (curColumn == trGet(tr, TR_COLUMNS)-1) {
658 /* write this buffered row of tiles to the file */
659 int curTileHeight = trGet(tr, TR_CURRENT_TILE_HEIGHT);
660 int bytesPerImageRow = imageWidth * 3*sizeof(GLubyte);
662 for (i=0;i<curTileHeight;i++) {
663 /* Remember, OpenGL images are bottom to top. Have to reverse. */
664 GLubyte *rowPtr = buffer + (curTileHeight-1-i) * bytesPerImageRow;
665 fwrite(rowPtr, 1, imageWidth*3, f);
671 globals->get_renderer()->resize( width, height );
677 message = "Snap shot saved to ";
679 mkDialog (message.c_str());
684 // message = "Snap shot saved to ";
685 // message += filename;
686 // mkDialog (message.c_str());
690 if ( show_pu_cursor ) {
695 fgSetBool("/sim/freeze/master", false);
698 #endif // #if defined( TR_HIRES_SNAP)
701 #if defined( WIN32 ) && !defined( __CYGWIN__) && !defined(__MINGW32__)
703 void rotateView( double roll, double pitch, double yaw )
709 GLubyte *hiResScreenCapture( int multiplier )
711 float oldfov = fgGetDouble("/sim/current-view/field-of-view");
712 float fov = oldfov / multiplier;
713 FGViewer *v = globals->get_current_view();
714 fgSetDouble("/sim/current-view/field-of-view", fov);
715 globals->get_renderer()->init();
716 int cur_width = fgGetInt("/sim/startup/xsize");
717 int cur_height = fgGetInt("/sim/startup/ysize");
718 if (b1) delete( b1 );
719 // New empty (mostly) bitmap
720 b1 = new GlBitmap( GL_RGB, 1, 1, (unsigned char *)"123" );
722 for ( y = 0; y < multiplier; y++ ) {
723 for ( x = 0; x < multiplier; x++ ) {
724 globals->get_renderer()->resize( cur_width, cur_height );
726 rotateView( 0, (y*fov)-((multiplier-1)*fov/2), (x*fov)-((multiplier-1)*fov/2) );
730 b1->copyBitmap( &b2, cur_width*x, cur_height*y );
733 fgSetDouble("/sim/current-view/field-of-view", oldfov);
734 return b1->getBitmap();
738 #if defined( WIN32 ) && !defined( __CYGWIN__) && !defined(__MINGW32__)
739 // win32 print screen function
740 void printScreen ( puObject *obj ) {
741 bool show_pu_cursor = false;
743 if ( !puCursorIsHidden() ) {
744 show_pu_cursor = true;
749 CGlPrinter p( CGlPrinter::PRINT_BITMAP );
750 int cur_width = fgGetInt("/sim/startup/xsize");
751 int cur_height = fgGetInt("/sim/startup/ysize");
752 p.Begin( "FlightGear", cur_width*3, cur_height*3 );
753 p.End( hiResScreenCapture(3) );
756 if ( show_pu_cursor ) {
761 #endif // #ifdef WIN32
764 void dumpSnapShot ( puObject *obj ) {
769 void dumpHiResSnapShot ( puObject *obj ) {
774 // do a screen snap shot
775 void fgDumpSnapShot () {
776 bool show_pu_cursor = false;
777 char *filename = new char [24];
779 static int count = 1;
781 static const SGPropertyNode *master_freeze
782 = fgGetNode("/sim/freeze/master");
784 bool freeze = master_freeze->getBoolValue();
786 fgSetBool("/sim/freeze/master", true);
790 if ( !puCursorIsHidden() ) {
791 show_pu_cursor = true;
795 globals->get_renderer()->init();
796 globals->get_renderer()->resize( fgGetInt("/sim/startup/xsize"),
797 fgGetInt("/sim/startup/ysize") );
799 // we need two render frames here to clear the menu and cursor
800 // ... not sure why but doing an extra fgRenderFrame() shouldn't
805 while (count < 1000) {
807 snprintf(filename, 24, "fgfs-screen-%03d.ppm", count++);
808 if ( (fp = fopen(filename, "r")) == NULL )
813 if ( sg_glDumpWindow( filename,
814 fgGetInt("/sim/startup/xsize"),
815 fgGetInt("/sim/startup/ysize")) ) {
816 message = "Snap shot saved to ";
819 message = "Failed to save to ";
823 mkDialog (message.c_str());
827 if ( show_pu_cursor ) {
834 fgSetBool("/sim/freeze/master", false);