Changeset 42:f23f648550e9 for src/mlx/gui
- Timestamp:
- 03/10/12 16:20:55 (13 years ago)
- Branch:
- default
- Phase:
- public
- Location:
- src/mlx/gui
- Files:
-
- 1 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mlx/gui/common.py
r32 r42 17 17 except Exception, e: 18 18 pass 19 20 MESSAGETYPE_ERROR = gtk.MESSAGE_ERROR 21 BUTTONSTYPE_OK = gtk.BUTTONS_OK 19 22 else: 20 23 print "Using PyGObject" … … 25 28 from gi.repository import AppIndicator3 as appindicator 26 29 appIndicator = True 30 31 MESSAGETYPE_ERROR = gtk.MessageType.ERROR 32 BUTTONSTYPE_OK = gtk.ButtonsType.OK 27 33 28 34 import cairo -
src/mlx/gui/gui.py
r41 r42 5 5 from update import Updater 6 6 from mlx.gui.common import * 7 from mlx.gui.flight import Wizard 7 8 8 9 import mlx.const as const … … 40 41 41 42 self._programDirectory = programDirectory 42 self. _config = config43 self.config = config 43 44 self._connecting = False 44 45 self._connected = False … … 69 70 window.add(mainVBox) 70 71 72 notebook = gtk.Notebook() 73 mainVBox.add(notebook) 74 75 notebook.append_page(Wizard(self), gtk.Label("Flight")) 76 77 dataVBox = gtk.VBox() 78 notebook.append_page(dataVBox, gtk.Label("Data")) 79 71 80 setupFrame = self._buildSetupFrame() 72 81 setupFrame.set_border_width(8) 73 mainVBox.pack_start(setupFrame, False, False, 0)82 dataVBox.pack_start(setupFrame, False, False, 0) 74 83 75 84 dataFrame = self._buildDataFrame() 76 85 dataFrame.set_border_width(8) 77 mainVBox.pack_start(dataFrame, False, False, 0) 78 86 dataVBox.pack_start(dataFrame, False, False, 0) 87 88 logVBox = gtk.VBox() 89 notebook.append_page(logVBox, gtk.Label("Log")) 90 79 91 logFrame = self._buildLogFrame() 80 92 logFrame.set_border_width(8) 81 mainVBox.pack_start(logFrame, True, True, 0)93 logVBox.pack_start(logFrame, True, True, 0) 82 94 83 95 mainVBox.pack_start(gtk.HSeparator(), False, False, 0) … … 94 106 def run(self): 95 107 """Run the GUI.""" 96 if self. _config.autoUpdate:108 if self.config.autoUpdate: 97 109 self._updater = Updater(self, 98 110 self._programDirectory, 99 self. _config.updateURL,111 self.config.updateURL, 100 112 self._mainWindow) 101 113 self._updater.start()
Note:
See TracChangeset
for help on using the changeset viewer.