[gnome-mines/gnome-3-12] Use "delay-apply" mode for GSettings



commit 3b58ba3885840e2cf36ef3d29b0168988576e0eb
Author: Chris Johns <christopher johns intel com>
Date:   Mon Apr 14 13:29:30 2014 +0100

    Use "delay-apply" mode for GSettings
    
    By delaying the settings, we will not lose any values within the current
    session.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=727191

 src/gnome-mines.vala |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/src/gnome-mines.vala b/src/gnome-mines.vala
index ef7e189..26660bc 100644
--- a/src/gnome-mines.vala
+++ b/src/gnome-mines.vala
@@ -92,6 +92,7 @@ public class Mines : Gtk.Application
         Environment.set_application_name (_("Mines"));
 
         settings = new Settings ("org.gnome.mines");
+        settings.delay ();
 
         Gtk.Window.set_default_icon_name ("gnome-mines");
 
@@ -391,6 +392,7 @@ public class Mines : Gtk.Application
         settings.set_int ("window-width", window_width);
         settings.set_int ("window-height", window_height);
         settings.set_boolean ("window-is-maximized", is_maximized);
+        settings.apply ();
     }
 
     public override void activate ()


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