[pitivi] shortcuts: Avoid centering the shortcuts window on the screen



commit ccc6b0930b701dcbeb12d20d0f78a9f516218adb
Author: Alexandru Băluț <alexandru balut gmail com>
Date:   Mon Jun 27 10:18:05 2016 +0200

    shortcuts: Avoid centering the shortcuts window on the screen
    
    We should allow the window to place itself where it thinks it's most
    useful and for this we specify it's transient for the main window.
    
    Because the position was set to CENTER_ALWAYS, the window was being
    displayed and then moved to the center of the screen, thus flickering.
    
    Differential Revision: https://phabricator.freedesktop.org/D1128

 pitivi/shortcutswindow.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/pitivi/shortcutswindow.py b/pitivi/shortcutswindow.py
index 5840756..2164a6e 100644
--- a/pitivi/shortcutswindow.py
+++ b/pitivi/shortcutswindow.py
@@ -32,9 +32,9 @@ class ShortcutsWindow(Gtk.ShortcutsWindow):
     def __init__(self, app):
         Gtk.ShortcutsWindow.__init__(self)
         self.app = app
-        self.populate()
-        self.set_position(Gtk.WindowPosition.CENTER_ALWAYS)
+        self.set_transient_for(self.app.gui)
         self.set_modal(True)
+        self.populate()
 
     def populate(self):
         """Gathers the accelerators and populates the window."""


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]