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

#139: the transponder state is now queried and made available

File:
1 edited

Legend:

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

    r314 r334  
    2323        """Construct the monitor window."""
    2424        super(MonitorWindow, self).__init__()
    25        
     25
    2626        self._gui = gui
    2727
     
    4848        self._paused = gtk.Label("PAUSED")
    4949        table.attach(self._paused, 2, 4, 0, 1)
    50        
     50
    5151        self._trickMode = gtk.Label("TRICKMODE")
    5252        table.attach(self._trickMode, 4, 6, 0, 1, xoptions = 0)
    53        
     53
    5454        self._overspeed = gtk.Label("OVERSPEED")
    5555        table.attach(self._overspeed, 6, 8, 0, 1)
    56        
     56
    5757        self._stalled = gtk.Label("STALLED")
    5858        table.attach(self._stalled, 8, 10, 0, 1)
    59        
     59
    6060        self._onTheGround = gtk.Label("ONTHEGROUND")
    6161        table.attach(self._onTheGround, 10, 12, 0, 1)
    62        
     62
    6363        (label, self._zfw) = self._createLabeledEntry("ZFW:", 6)
    6464        table.attach(label, 0, 1, 1, 2)
     
    188188        table.attach(self._position, 7, 10, 6, 7)
    189189
     190        self._xpdrC = gtk.Label("XPDR CHARLIE")
     191        table.attach(self._xpdrC, 10, 12, 6, 7)
     192
    190193        alignment.add(table)
    191194
     
    202205        - the box
    203206        - the entry."""
    204        
     207
    205208        alignment = gtk.Alignment(xalign = 1.0, yalign = 0.5, xscale = 1.0)
    206209        alignment.set_padding(padding_top = 0, padding_bottom = 0,
     
    262265            self._windDirection.set_text("-")
    263266            self._position.set_text("-")
     267            self._xpdrC.set_sensitive(False)
    264268        else:
    265269            self._timestamp.set_text(time.strftime("%H:%M:%S",
     
    294298            for (_tank, fuel) in aircraftState.fuel:
    295299                if fuelStr: fuelStr += ", "
    296                 fuelStr += "%.0f" % (fuel,)               
     300                fuelStr += "%.0f" % (fuel,)
    297301            self._fuel.set_text(fuelStr)
    298302
     
    329333                    self._landingLightsOn.set_text("LANDING")
    330334            self._landingLightsOn.set_sensitive(aircraftState.landingLightsOn is True)
    331            
     335
    332336            self._pitotHeatOn.set_sensitive(aircraftState.pitotHeatOn)
    333337            self._parking.set_sensitive(aircraftState.parking)
     
    340344            self._position.set_text(util.getCoordinateString((aircraftState.latitude,
    341345                                                              aircraftState.longitude)))
     346            self._xpdrC.set_sensitive(aircraftState.xpdrC)
    342347
    343348#------------------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.