Changeset 182:dd806c3cc18d for src/mlx/gui
- Timestamp:
- 05/15/12 15:01:07 (13 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mlx/gui/gui.py
r178 r182 19 19 import mlx.acft as acft 20 20 import mlx.web as web 21 import mlx.singleton as singleton 21 22 from mlx.i18n import xstr 22 23 from mlx.pirep import PIREP … … 306 307 self._mainWindow) 307 308 self._updater.start() 308 309 310 singleton.raiseCallback = self.raiseCallback 309 311 gtk.main() 312 singleton.raiseCallback = None 310 313 311 314 self._disconnect() … … 499 502 (event.new_window_state&iconified)!=0: 500 503 self.hideMainWindow(savePosition = False) 504 505 def raiseCallback(self): 506 """Callback for the singleton handling code.""" 507 gobject.idle_add(self.raiseMainWindow) 508 509 def raiseMainWindow(self): 510 """SHow the main window if invisible, and raise it.""" 511 if not self._mainWindow.get_visible(): 512 self.showMainWindow() 513 self._mainWindow.present() 501 514 502 515 def hideMainWindow(self, savePosition = True):
Note:
See TracChangeset
for help on using the changeset viewer.