update gui tweaks - micah
This commit is contained in:
parent
e80da672f0
commit
09334d8892
|
@ -117,6 +117,10 @@ class DelugeGTK:
|
||||||
self.apply_prefs()
|
self.apply_prefs()
|
||||||
self.load_window_geometry()
|
self.load_window_geometry()
|
||||||
|
|
||||||
|
# Boolean used in update method to help check whether gui
|
||||||
|
# should be updated and is set by the window_state_event method
|
||||||
|
self.is_minimized = False
|
||||||
|
|
||||||
def connect_signals(self):
|
def connect_signals(self):
|
||||||
self.wtree.signal_autoconnect({
|
self.wtree.signal_autoconnect({
|
||||||
## File Menu
|
## File Menu
|
||||||
|
@ -820,6 +824,11 @@ class DelugeGTK:
|
||||||
#Update any active plugins
|
#Update any active plugins
|
||||||
self.plugins.update_active_plugins()
|
self.plugins.update_active_plugins()
|
||||||
|
|
||||||
|
# only update gui if it's needed
|
||||||
|
if self.window.get_property("visible") and not self.is_minimized:
|
||||||
|
print "Visibility", self.window.get_property("visible")
|
||||||
|
print "Minimized", self.is_minimized
|
||||||
|
|
||||||
# Put the generated message into the statusbar
|
# Put the generated message into the statusbar
|
||||||
# This gives plugins a chance to write to the
|
# This gives plugins a chance to write to the
|
||||||
# statusbar if they want
|
# statusbar if they want
|
||||||
|
@ -1330,6 +1339,11 @@ class DelugeGTK:
|
||||||
self.config.set("window_maximized", True)
|
self.config.set("window_maximized", True)
|
||||||
else:
|
else:
|
||||||
self.config.set("window_maximized", False)
|
self.config.set("window_maximized", False)
|
||||||
|
if event.changed_mask & gtk.gdk.WINDOW_STATE_ICONIFIED:
|
||||||
|
if event.new_window_state & gtk.gdk.WINDOW_STATE_ICONIFIED:
|
||||||
|
self.is_minimized = True
|
||||||
|
else:
|
||||||
|
self.is_minimized = False
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue