Ignore:
Timestamp:
07/16/23 10:55:47 (10 months ago)
Author:
István Váradi <ivaradi@…>
Branch:
python3
hg-Phase:
(<MercurialRepository 1 'hg:/home/ivaradi/mlx/hg' '/'>, 'public')
Message:

The taxi sounds can be started on pushback (re #367)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/config.py

    r1084 r1094  
    249249        self._pilotHotkey = Hotkey(ctrl = True, shift = False, key = "0")
    250250
     251        self._taxiSoundOnPushback = False
     252
    251253        self._enableApproachCallouts = False
    252254        self._speedbrakeAtTD = True
     
    608610        if pilotHotkey!=self._pilotHotkey:
    609611            self._pilotHotkey = pilotHotkey
     612            self._modified = True
     613
     614    @property
     615    def taxiSoundOnPushback(self):
     616        """Get whether the taxi sound should be played as soon as pushback starts."""
     617        return self._taxiSoundOnPushback
     618
     619    @taxiSoundOnPushback.setter
     620    def taxiSoundOnPushback(self, taxiSoundOnPushback):
     621        """Set whether the taxi sound should be played as soon as pushback starts."""
     622        if taxiSoundOnPushback!=self._taxiSoundOnPushback:
     623            self._taxiSoundOnPushback = taxiSoundOnPushback
    610624            self._modified = True
    611625
     
    802816        self._pilotHotkey.set(self._get(config, "sounds",
    803817                                        "pilotHotkey", "C0"))
     818
     819        self._taxiSoundOnPushback = \
     820            self._getBoolean(config, "sounds", "taxiSoundOnPushback", False)
    804821        self._enableApproachCallouts = \
    805822            self._getBoolean(config, "sounds", "enableApproachCallouts", False)
     
    903920                   "yes" if self._pilotControlsSounds else "no")
    904921        config.set("sounds", "pilotHotkey", str(self._pilotHotkey))
     922        config.set("sounds", "taxiSoundOnPushback",
     923                   "yes" if self._taxiSoundOnPushback else "no")
    905924        config.set("sounds", "enableApproachCallouts",
    906925                   "yes" if self._enableApproachCallouts else "no")
     
    10471066        print("  pilotHotkey:", str(self._pilotHotkey))
    10481067
     1068        print("  taxiSoundOnPushback:", self._taxiSoundOnPushback)
     1069
    10491070        print("  enableApproachCallouts:", self._enableApproachCallouts)
    10501071        print("  speedbrakeAtTD:", self._speedbrakeAtTD)
Note: See TracChangeset for help on using the changeset viewer.