diff --git a/Nasal/gui.nas b/Nasal/gui.nas index bb15dd82d..debc7fba9 100644 --- a/Nasal/gui.nas +++ b/Nasal/gui.nas @@ -583,6 +583,17 @@ var load_flight = func { load_flight_sel.open(); } +## +# Screen-shot directory menu function +# +var set_screenshotdir_sel = nil; +var set_screenshotdir = func { + if (set_screenshotdir_sel == nil) + set_screenshotdir_sel = gui.DirSelector.new( + func(result) { setprop("/sim/paths/screenshot-dir", result.getValue()); }, + "Select Screenshot Directory", "Ok", getprop("/sim/paths/screenshot-dir")); + set_screenshotdir_sel.open(); +} ## # Open property browser with given target path. diff --git a/gui/menubar.xml b/gui/menubar.xml index cd8babbdf..e75a0715d 100644 --- a/gui/menubar.xml +++ b/gui/menubar.xml @@ -62,6 +62,13 @@ </script> </binding> </item> + <item> + <label>Screenshot Directory</label> + <binding> + <command>nasal</command> + <script>gui.set_screenshotdir()</script> + </binding> + </item> <!-- <item> <label>Last snapshot</label>