Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/gui/gui.py

    r491 r501  
    6969        self._flight = None
    7070        self._simulator = None
     71        self._fsType = None
    7172        self._monitoring = False
    7273
     
    208209
    209210    @property
     211    def fsType(self):
     212        """Get the flight simulator type."""
     213        return self._fsType
     214
     215    @property
    210216    def entranceExam(self):
    211217        """Get whether an entrance exam is about to be taken."""
     
    428434            self._wizard.connected(fsType, descriptor)
    429435        self._reconnecting = False
     436        self._fsType = fsType
    430437        self._listenHotkeys()
    431438
     
    512519        """Reset the GUI."""
    513520        self._disconnect()
     521
     522        self._simulator = None
    514523
    515524        self._flightInfo.reset()
     
    887896            self._stdioStartingLine = False
    888897
    889     def connectSimulator(self, aircraftType):
     898    def connectSimulator(self, aircraftType, simulatorType):
    890899        """Connect to the simulator for the first time."""
    891900        self._logger.reset()
     
    898907
    899908        if self._simulator is None:
    900             self._simulator = fs.createSimulator(const.SIM_MSFS9, self)
     909            self._simulator = fs.createSimulator(simulatorType, self)
    901910            fs.setupMessageSending(self.config, self._simulator)
    902911            self._setupTimeSync()
Note: See TracChangeset for help on using the changeset viewer.