[gnome-boxes/fix-welcome-tutorial-gnome-41] welcome-tutorial: Hold a reference to the first page




commit c30746403667340c6882de94cc5bddc1c320d1dc
Author: Felipe Borges <felipeborges gnome org>
Date:   Sat Sep 18 11:02:54 2021 +0200

    welcome-tutorial: Hold a reference to the first page
    
    Otherwise BoxesWelcomeTutorialPage is an invalid object type in
    BoxesWelcomeTutorial.
    
    Fixes #722

 data/ui/welcome-tutorial.ui | 2 +-
 src/welcome-tutorial.vala   | 2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/data/ui/welcome-tutorial.ui b/data/ui/welcome-tutorial.ui
index ba838445..cbe177e7 100644
--- a/data/ui/welcome-tutorial.ui
+++ b/data/ui/welcome-tutorial.ui
@@ -36,7 +36,7 @@
                 <signal name="notify::position" handler="on_position_changed"/>
 
                 <child>
-                  <object class="BoxesWelcomeTutorialPage">
+                  <object class="BoxesWelcomeTutorialPage" id="first_page">
                     <property name="title" translatable="yes">Welcome to Boxes</property>
                     <property name="description" translatable="yes">Boxes makes it easy to install and run 
virtual machines.</property>
                     <property name="color">#613583</property>
diff --git a/src/welcome-tutorial.vala b/src/welcome-tutorial.vala
index be920cae..a7e938c1 100644
--- a/src/welcome-tutorial.vala
+++ b/src/welcome-tutorial.vala
@@ -10,6 +10,8 @@
     private unowned Button go_back_button;
     [GtkChild]
     private unowned Button go_next_button;
+    [GtkChild]
+    private unowned Boxes.WelcomeTutorialPage first_page;
 
     private GLib.List<unowned WelcomeTutorialPage> pages;
     private CssProvider provider;


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