Changeset 367:ecebdd53757b


Ignore:
Timestamp:
12/16/12 14:28:14 (12 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
default
Phase:
public
Message:

Added the ADF frequencies

File:
1 edited

Legend:

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

    r340 r367  
    202202        table.attach(self._apHeading, 3, 4, 7, 8)
    203203
     204        self._xpdrC = gtk.Label("XPDR C")
     205        table.attach(self._xpdrC, 4, 5, 7, 8)
     206
    204207        self._apAltitudeHold = gtk.Label("AP ALT HOLD")
    205208        table.attach(self._apAltitudeHold, 5, 6, 7, 8)
     
    209212        table.attach(self._apAltitude, 7, 8, 7, 8)
    210213
    211         self._xpdrC = gtk.Label("XPDR CHARLIE")
    212         table.attach(self._xpdrC, 10, 12, 7, 8)
     214        (label, self._adf1) = self._createLabeledEntry("ADF1:", 5)
     215        table.attach(label, 8, 9, 7, 8)
     216        table.attach(self._adf1, 9, 10, 7, 8)
     217
     218        (label, self._adf2) = self._createLabeledEntry("ADF2:", 5)
     219        table.attach(label, 10, 11, 7, 8)
     220        table.attach(self._adf2, 11, 12, 7, 8)
    213221
    214222        alignment.add(table)
     
    290298            self._apHeadingHold.set_sensitive(False)
    291299            self._apHeading.set_text("-")
     300            self._xpdrC.set_sensitive(False)
    292301            self._apAltitudeHold.set_sensitive(False)
    293302            self._apAltitude.set_text("-")
    294             self._xpdrC.set_sensitive(False)
     303            self._adf1.set_text("-")
     304            self._adf2.set_text("-")
    295305        else:
    296306            self._timestamp.set_text(time.strftime("%H:%M:%S",
     
    375385            self._apHeadingHold.set_sensitive(aircraftState.apHeadingHold)
    376386            self._apHeading.set_text("%03.0f" % (aircraftState.apHeading,))
     387            self._xpdrC.set_sensitive(aircraftState.xpdrC)
    377388            self._apAltitudeHold.set_sensitive(aircraftState.apAltitudeHold)
    378389            self._apAltitude.set_text("%5.0f" % (aircraftState.apAltitude,))
    379390
    380             self._xpdrC.set_sensitive(aircraftState.xpdrC)
     391            self._adf1.set_text("-" if aircraftState.adf1 is None else aircraftState.adf1)
     392            self._adf2.set_text("-" if aircraftState.adf2 is None else aircraftState.adf2)
    381393
    382394#------------------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.