#7 Patch for FG_ROOT and Executable path validation

open
nobody
None
5
2010-03-24
2010-03-24
Paul Richter
No

1. Fixes validation behavior for the Executable and FG_ROOT fields in the "Select Paths" (very first) wizard panel.
Currently, only the FG_ROOT edit field is checked, on every change, to validate the path. If fgrun is run on a system where FG_ROOT is defined (whether as an environment variable or in fgrun.prefs) but not the executable, it will start up in the Select Paths panel with FG_ROOT filled but Executable empty, and thus the "Next" button is disabled. But even if the correct executable is then entered, the button remains disabled because only the FG_ROOT field is checked. This patch checks the Executable text field on any change, and enables the Next button only if both paths are valid.

2. Cleaned up some path-appending code: removed double path separators ("fgrun//airports.txt") from cache path, replaced SGPath::append() with SGPath::concat() and removed leading separator from strings concatenated to paths that already contain trailing separators.

Discussion

  • Paul Richter
    Paul Richter
    2010-03-24

    fgrun patch for validating config paths

     
    Attachments