[gnome-boxes] i-props-provider: String change always succeeds



commit 441946c828fcdca3fd0ebc557dd8dbe07fc90571
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date:   Wed Feb 18 14:28:08 2015 +0000

    i-props-provider: String change always succeeds
    
    We are no longer watching for failures in change of an editable string
    property and none of the users of this API makes use of this functionality
    anyway so no reason for EditableStringProperty.changed() to return
    boolean.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=720788

 src/i-properties-provider.vala      |    2 +-
 src/libvirt-machine-properties.vala |    5 -----
 src/remote-machine.vala             |    2 --
 3 files changed, 1 insertions(+), 8 deletions(-)
---
diff --git a/src/i-properties-provider.vala b/src/i-properties-provider.vala
index 1816548..986be28 100644
--- a/src/i-properties-provider.vala
+++ b/src/i-properties-provider.vala
@@ -155,7 +155,7 @@ private class Boxes.StringProperty : Boxes.Property {
 }
 
 private class Boxes.EditableStringProperty : Boxes.Property {
-    public signal bool changed (string value);
+    public signal void changed (string value);
 
     public string text {
         get { return entry.text; }
diff --git a/src/libvirt-machine-properties.vala b/src/libvirt-machine-properties.vala
index 6e6408e..29a79b6 100644
--- a/src/libvirt-machine-properties.vala
+++ b/src/libvirt-machine-properties.vala
@@ -118,11 +118,6 @@ private class Boxes.LibvirtMachineProperties: GLib.Object, Boxes.IPropertiesProv
             var property = add_editable_string_property (ref list, _("Name"), machine.name);
             property.changed.connect ((property, name) => {
                 machine.name = name;
-
-                // Its unlikely that machine name change fails and even if it
-                // does, name is still changed in the UI at least (it just
-                // doesn't get saved).
-                return true;
             });
 
             var name_property = property;
diff --git a/src/remote-machine.vala b/src/remote-machine.vala
index f28664e..7e187aa 100644
--- a/src/remote-machine.vala
+++ b/src/remote-machine.vala
@@ -55,7 +55,6 @@ private class Boxes.RemoteMachine: Boxes.Machine, Boxes.IPropertiesProvider {
             var property = add_editable_string_property (ref list, _("Name"), source.name);
             property.changed.connect ((property, name) => {
                 this.name = name;
-                return true;
             });
 
             var name_property = property;
@@ -70,7 +69,6 @@ private class Boxes.RemoteMachine: Boxes.Machine, Boxes.IPropertiesProvider {
                 property = add_editable_string_property (ref list, _("URI"), source.uri);
                 property.changed.connect ((property, uri) => {
                     source.uri = uri;
-                    return true;
                });
             }
 


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