From: James Turner Date: Sat, 16 Mar 2013 12:44:43 +0000 (+0000) Subject: Show a message when pausing the sim. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=c487188bfc4f441ccf243c0b000788c900d7a14f;p=flightgear.git Show a message when pausing the sim. --- diff --git a/src/Main/fg_commands.cxx b/src/Main/fg_commands.cxx index f1909c1fa..27980afba 100644 --- a/src/Main/fg_commands.cxx +++ b/src/Main/fg_commands.cxx @@ -235,6 +235,16 @@ do_pause (const SGPropertyNode * arg) fgSetBool("/sim/freeze/master",!paused); fgSetBool("/sim/freeze/clock",!paused); } + + SGPropertyNode_ptr args(new SGPropertyNode); + args->setStringValue("id", "sim-pause"); + if (!paused) { + args->setStringValue("label", "Simulation is paused"); + globals->get_commands()->execute("show-message", args); + } else { + globals->get_commands()->execute("clear-message", args); + } + return true; }