[polari] mainWindow: Minor cleanup



commit e6b3bd19b906dd4aa9bf2118dfa89689e7f2fe07
Author: Florian Müllner <fmuellner gnome org>
Date:   Thu Mar 5 22:40:15 2015 +0100

    mainWindow: Minor cleanup
    
    https://bugzilla.gnome.org/show_bug.cgi?id=745717

 src/mainWindow.js |    9 +++------
 1 files changed, 3 insertions(+), 6 deletions(-)
---
diff --git a/src/mainWindow.js b/src/mainWindow.js
index bb11d52..67ef986 100644
--- a/src/mainWindow.js
+++ b/src/mainWindow.js
@@ -88,12 +88,9 @@ const MainWindow = new Lang.Class({
         this.window.connect('delete-event',
                             Lang.bind(this, this._onDelete));
 
-        let size = this._settings.get_value('window-size');
-        if (size.n_children() == 2) {
-            let width = size.get_child_value(0);
-            let height = size.get_child_value(1);
-            this.window.set_default_size(width.get_int32(), height.get_int32());
-        }
+        let size = this._settings.get_value('window-size').deep_unpack();
+        if (size.length == 2)
+            this.window.set_default_size.apply(this.window, size);
 
         let position = this._settings.get_value('window-position');
         if (position.n_children() == 2) {


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