[pitivi] mainwindow: Fix main window's panes shifting position
- From: Jean-François Fortin Tam <jfft src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] mainwindow: Fix main window's panes shifting position
- Date: Sat, 29 Mar 2014 23:35:44 +0000 (UTC)
commit 4c09ca62ae4aa72b91cd8808e48d48891aba972c
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Tue Mar 18 12:42:48 2014 -0300
mainwindow: Fix main window's panes shifting position
Complements the fix for utility windows in bug #692980
pitivi/mainwindow.py | 6 ++++--
pitivi/tabsmanager.py | 1 +
2 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/pitivi/mainwindow.py b/pitivi/mainwindow.py
index 0591b03..315f407 100644
--- a/pitivi/mainwindow.py
+++ b/pitivi/mainwindow.py
@@ -472,10 +472,12 @@ class PitiviMainWindow(Gtk.Window, Loggable):
"""
Handle the main window being moved, resized or maximized
"""
+ # get_position() takes window manager decoration into account
+ position = self.get_position()
self.settings.mainWindowWidth = event.width
self.settings.mainWindowHeight = event.height
- self.settings.mainWindowX = event.x
- self.settings.mainWindowY = event.y
+ self.settings.mainWindowX = position[0]
+ self.settings.mainWindowY = position[1]
def _deleteCb(self, unused_widget, unused_data=None):
self._saveWindowSettings()
diff --git a/pitivi/tabsmanager.py b/pitivi/tabsmanager.py
index bcf5a10..958fc59 100644
--- a/pitivi/tabsmanager.py
+++ b/pitivi/tabsmanager.py
@@ -123,6 +123,7 @@ class BaseTabs(Gtk.Notebook):
The config key's name depends on the name (label) of the tab widget.
"""
+ # get_position() takes the window manager's decorations into account
position = window.get_position()
setattr(self.settings, child_name + "width", event.width)
setattr(self.settings, child_name + "height", event.height)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]