[pitivi] tabsmanager: Fix utility windows' shifting behaviour
- From: Jean-François Fortin Tam <jfft src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] tabsmanager: Fix utility windows' shifting behaviour
- Date: Sat, 29 Mar 2014 23:35:39 +0000 (UTC)
commit 6e894d8e70782e26162ea2a236a20db41bbe7fb6
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Tue Mar 18 12:34:18 2014 -0300
tabsmanager: Fix utility windows' shifting behaviour
When using event.x/y, the saved values would be the internal window's position.
To save the general window position, window.get_position() was used.
Fixes bug #692980
pitivi/tabsmanager.py | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/pitivi/tabsmanager.py b/pitivi/tabsmanager.py
index 08312d2..bcf5a10 100644
--- a/pitivi/tabsmanager.py
+++ b/pitivi/tabsmanager.py
@@ -116,17 +116,18 @@ class BaseTabs(Gtk.Notebook):
else:
return notebook
- def _detachedComponentWindowConfiguredCb(self, unused_window, event, child_name):
+ def _detachedComponentWindowConfiguredCb(self, window, event, child_name):
"""
When the user configures the detached window
(changes its size, position, etc.), save the settings.
The config key's name depends on the name (label) of the tab widget.
"""
+ position = window.get_position()
setattr(self.settings, child_name + "width", event.width)
setattr(self.settings, child_name + "height", event.height)
- setattr(self.settings, child_name + "x", event.x)
- setattr(self.settings, child_name + "y", event.y)
+ setattr(self.settings, child_name + "x", position[0])
+ setattr(self.settings, child_name + "y", position[1])
def _createDefaultConfig(self, child_name):
"""
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]