[gnome-boxes/wip/wizard-n-props-in-dialog2: 11/12] i-properties-provider: Add Property.flushed signal



commit f8d39a28d38c6ee3b09a33cfecfeddf2bf5acf58
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date:   Sun Nov 23 15:11:03 2014 +0000

    i-properties-provider: Add Property.flushed signal
    
    Add a signal to Property to notify interested parties that said property
    has been flushed.

 src/i-properties-provider.vala |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/src/i-properties-provider.vala b/src/i-properties-provider.vala
index 566ec5a..17b61a9 100644
--- a/src/i-properties-provider.vala
+++ b/src/i-properties-provider.vala
@@ -8,6 +8,7 @@ private class Boxes.Property: GLib.Object {
     public bool reboot_required { get; set; }
 
     public signal void refresh_properties ();
+    public signal void flushed ();
 
     public uint defer_interval { get; set; default = 1; } // In seconds
 
@@ -39,7 +40,7 @@ private class Boxes.Property: GLib.Object {
                 return;
 
             deferred_change_id = Timeout.add_seconds (defer_interval, () => {
-                flush ();
+                flush_changes ();
 
                 return false;
             });
@@ -51,6 +52,12 @@ private class Boxes.Property: GLib.Object {
     }
 
     public void flush () {
+        flush_changes ();
+
+        flushed ();
+    }
+
+    private void flush_changes () {
         if (deferred_change == null)
             return;
 


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