[gnome-boxes/wip/props-ui-files: 9/12] props-page-widget: Async constructor



commit 12fcbab4e92c3edbaf03742486598129ef834762
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date:   Thu Jun 2 18:37:52 2016 +0100

    props-page-widget: Async constructor
    
    In a following patch we will be making
    IPropertiesProvider.get_properties(), async so the calling method also
    needs to be async.

 src/properties-page-widget.vala |    2 +-
 src/properties.vala             |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/properties-page-widget.vala b/src/properties-page-widget.vala
index fd33eab..8b5f35f 100644
--- a/src/properties-page-widget.vala
+++ b/src/properties-page-widget.vala
@@ -32,7 +32,7 @@ private class Boxes.PropertiesPageWidget: Gtk.Box {
         }
     }
 
-    public PropertiesPageWidget (PropertiesPage page, Machine machine) {
+    public async PropertiesPageWidget (PropertiesPage page, Machine machine) {
         deferred_changes = new List<DeferredChange> ();
 
         switch (page) {
diff --git a/src/properties.vala b/src/properties.vala
index 6e506ff..5c3e531 100644
--- a/src/properties.vala
+++ b/src/properties.vala
@@ -33,7 +33,7 @@ private class Boxes.Properties: Gtk.Notebook, Boxes.UI {
             return;
 
         for (var i = 0; i < PropertiesPage.LAST; i++) {
-            var page = new PropertiesPageWidget (i, machine);
+            var page = yield new PropertiesPageWidget (i, machine);
             if (page.empty)
                 continue;
 


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