[polari] mainWindow: fix growth at each restart
- From: Olivier Fourdan <ofourdan src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [polari] mainWindow: fix growth at each restart
- Date: Fri, 8 Jan 2016 12:07:49 +0000 (UTC)
commit 4314b205b688b5df4ab69368d2a8e9f52dba2c02
Author: Olivier Fourdan <ofourdan redhat com>
Date: Mon Dec 7 13:08:40 2015 +0100
mainWindow: fix growth at each restart
gtk+ 3.19.x will compensate for client-side decorations in
set_default_size() and get_size() but Polari uses the requisition size
directly which includes the client-side decorations.
As a result, on exit, the window-size saved in gsettings includes the
size of the client-side decorations, and on next restart, Polari's
main window will end up being larger than previously.
Fix the issue by using get_size() instead of the requisition size
directly.
Bugzilla: https://bugzilla.gnome.org/show_bug.cgi?id=759117
src/mainWindow.js | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/mainWindow.js b/src/mainWindow.js
index d783862..b47b9f2 100644
--- a/src/mainWindow.js
+++ b/src/mainWindow.js
@@ -175,7 +175,7 @@ const MainWindow = new Lang.Class({
_onSizeAllocate: function(widget, allocation) {
if (!this._isFullscreen && !this._isMaximized)
- this._currentSize = [allocation.width, allocation.height];
+ this._currentSize = this.window.get_size(this);
},
_onDelete: function(widget, event) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]