Changeset 139:839016dcd0d1 for src/mlx/acft.py
- Timestamp:
- 05/01/12 08:29:24 (12 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mlx/acft.py
r136 r139 8 8 import util 9 9 10 import sys 10 11 import time 12 import traceback 11 13 12 14 #--------------------------------------------------------------------------------------- … … 59 61 self._checkers.append(checks.VisibilityChecker()) 60 62 63 # FIXME: we should have a central data model object, and not collect 64 # the data from the GUI. However, some pieces of data (e.g. V-speeds, 65 # etc. that is entered into the GUI) *should* be a part of the GUI and 66 # queried from it, so the model should have a reference to the GUI as 67 # well and access such data via the GUI! 68 if flight.config.onlineACARS: 69 self._checkers.append(checks.ACARSSender(flight._gui)) 70 61 71 # Fault checkers 62 72 … … 105 115 return self._flight.logger 106 116 117 @property 118 def state(self): 119 """Get the current aircraft state.""" 120 return self._aircraftState 121 107 122 def getFlapsSpeedLimit(self, flaps): 108 123 """Get the speed limit for the given flaps setting.""" … … 119 134 """Called when the state of the aircraft changes.""" 120 135 for checker in self._checkers: 121 checker.check(self._flight, self, self._flight.logger, 122 self._aircraftState, aircraftState) 136 try: 137 checker.check(self._flight, self, self._flight.logger, 138 self._aircraftState, aircraftState) 139 except: 140 print >> sys.stderr, "Checker", checker, "failed" 141 traceback.print_exc() 123 142 124 143 self._flight.handleState(self._aircraftState, aircraftState)
Note:
See TracChangeset
for help on using the changeset viewer.