[gnome-software/wip/temp/ubuntu-xenial-rebased: 82/329] Use a template for login dialog UI



commit 2a5a0e07eeb7bd5cfcc34937f05aa0d500f46dae
Author: Robert Ancell <robert ancell canonical com>
Date:   Thu Feb 11 11:20:24 2016 +1300

    Use a template for login dialog UI

 src/plugins/ubuntu-login-dialog.c  |   48 +--
 src/plugins/ubuntu-login-dialog.ui |  785 ++++++++++++++++++------------------
 2 files changed, 402 insertions(+), 431 deletions(-)
---
diff --git a/src/plugins/ubuntu-login-dialog.c b/src/plugins/ubuntu-login-dialog.c
index c708eab..fe6d997 100644
--- a/src/plugins/ubuntu-login-dialog.c
+++ b/src/plugins/ubuntu-login-dialog.c
@@ -31,7 +31,6 @@ struct _UbuntuLoginDialog
 {
        GtkDialog parent_instance;
 
-       GtkBuilder *builder;
        GtkWidget *content_box;
        GtkWidget *cancel_button;
        GtkWidget *next_button;
@@ -71,16 +70,6 @@ enum
 G_DEFINE_TYPE (UbuntuLoginDialog, ubuntu_login_dialog, GTK_TYPE_DIALOG)
 
 static void
-ubuntu_login_dialog_dispose (GObject *object)
-{
-       UbuntuLoginDialog *self = UBUNTU_LOGIN_DIALOG (object);
-
-       g_clear_object (&self->builder);
-
-       G_OBJECT_CLASS (ubuntu_login_dialog_parent_class)->dispose (object);
-}
-
-static void
 ubuntu_login_dialog_finalize (GObject *object)
 {
        UbuntuLoginDialog *self = UBUNTU_LOGIN_DIALOG (object);
@@ -163,13 +152,30 @@ static void
 ubuntu_login_dialog_class_init (UbuntuLoginDialogClass *klass)
 {
        GObjectClass *object_class = G_OBJECT_CLASS (klass);
+       GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
        GParamFlags param_flags;
 
-       object_class->dispose = ubuntu_login_dialog_dispose;
        object_class->finalize = ubuntu_login_dialog_finalize;
        object_class->get_property = ubuntu_login_dialog_get_property;
        object_class->set_property = ubuntu_login_dialog_set_property;
 
+       gtk_widget_class_set_template_from_resource (widget_class, 
"/org/gnome/Software/plugins/ubuntu-login-dialog.ui");
+
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, content_box);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, cancel_button);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, next_button);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, status_stack);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, status_image);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, status_label);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, page_stack);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, login_radio);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, register_radio);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, reset_radio);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, email_entry);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, password_entry);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, remember_check);
+       gtk_widget_class_bind_template_child (widget_class, UbuntuLoginDialog, passcode_entry);
+
        param_flags = G_PARAM_READABLE | G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB;
 
        g_object_class_install_property (object_class,
@@ -521,7 +527,7 @@ radio_button_toggled_cb (UbuntuLoginDialog *self,
 
 static void
 entry_edited_cb (UbuntuLoginDialog *self,
-                GParamSpec     *pspec,
+                GParamSpec        *pspec,
                 GObject           *object)
 {
        update_widgets (self);
@@ -537,21 +543,7 @@ remember_check_toggled_cb (UbuntuLoginDialog *self,
 static void
 ubuntu_login_dialog_init (UbuntuLoginDialog *self)
 {
-       self->builder = gtk_builder_new_from_resource ("/org/gnome/Software/plugins/ubuntu-login-dialog.ui");
-       self->content_box = GTK_WIDGET (gtk_builder_get_object (self->builder, "content-box"));
-       self->cancel_button = GTK_WIDGET (gtk_builder_get_object (self->builder, "cancel-button"));
-       self->next_button = GTK_WIDGET (gtk_builder_get_object (self->builder, "next-button"));
-       self->status_stack = GTK_WIDGET (gtk_builder_get_object (self->builder, "status-stack"));
-       self->status_image = GTK_WIDGET (gtk_builder_get_object (self->builder, "status-image"));
-       self->status_label = GTK_WIDGET (gtk_builder_get_object (self->builder, "status-label"));
-       self->page_stack = GTK_WIDGET (gtk_builder_get_object (self->builder, "page-stack"));
-       self->login_radio = GTK_WIDGET (gtk_builder_get_object (self->builder, "login-radio"));
-       self->register_radio = GTK_WIDGET (gtk_builder_get_object (self->builder, "register-radio"));
-       self->reset_radio = GTK_WIDGET (gtk_builder_get_object (self->builder, "reset-radio"));
-       self->email_entry = GTK_WIDGET (gtk_builder_get_object (self->builder, "email-entry"));
-       self->password_entry = GTK_WIDGET (gtk_builder_get_object (self->builder, "password-entry"));
-       self->remember_check = GTK_WIDGET (gtk_builder_get_object (self->builder, "remember-check"));
-       self->passcode_entry = GTK_WIDGET (gtk_builder_get_object (self->builder, "passcode-entry"));
+       gtk_widget_init_template (GTK_WIDGET (self));
 
        g_signal_connect_swapped (self->cancel_button, "clicked", G_CALLBACK (cancel_button_clicked_cb), 
self);
        g_signal_connect_swapped (self->next_button, "clicked", G_CALLBACK (next_button_clicked_cb), self);
diff --git a/src/plugins/ubuntu-login-dialog.ui b/src/plugins/ubuntu-login-dialog.ui
index e6bc625..6c70369 100644
--- a/src/plugins/ubuntu-login-dialog.ui
+++ b/src/plugins/ubuntu-login-dialog.ui
@@ -2,407 +2,386 @@
 <!-- Generated with glade 3.19.0 -->
 <interface>
   <requires lib="gtk+" version="3.16"/>
-  <object class="GtkBox" id="content-box">
-    <property name="name">content-box</property>
-    <property name="visible">True</property>
-    <property name="can_focus">False</property>
-    <property name="margin_left">20</property>
-    <property name="margin_right">20</property>
-    <property name="margin_top">20</property>
-    <property name="margin_bottom">20</property>
-    <property name="orientation">vertical</property>
-    <property name="spacing">40</property>
-    <child>
-      <object class="GtkBox">
-        <property name="visible">True</property>
-        <property name="can_focus">False</property>
-        <property name="spacing">20</property>
-        <child>
-          <object class="GtkImage">
-            <property name="visible">True</property>
-            <property name="can_focus">False</property>
-            <property name="yalign">0</property>
-            <property name="resource">/org/gnome/Software/plugins/ubuntu-one.png</property>
-          </object>
-          <packing>
-            <property name="expand">False</property>
-            <property name="fill">True</property>
-            <property name="position">0</property>
-          </packing>
-        </child>
-        <child>
-          <object class="GtkStack" id="page-stack">
-            <property name="name">page-stack</property>
-            <property name="visible">True</property>
-            <property name="can_focus">False</property>
-            <child>
-              <object class="GtkGrid" id="page-0">
-                <property name="name">page-0</property>
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <child>
-                  <object class="GtkLabel">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="margin_bottom">20</property>
-                    <property name="label" translatable="yes">To rate and review software, you need an 
Ubuntu Single Sign-On account.</property>
-                    <property name="wrap">True</property>
-                    <property name="xalign">0</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">0</property>
-                    <property name="width">2</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkAccelLabel">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="halign">end</property>
-                    <property name="margin_right">10</property>
-                    <property name="margin_bottom">20</property>
-                    <property name="label" translatable="yes">_Email address:</property>
-                    <property name="use_underline">True</property>
-                    <property name="xalign">1</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">1</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkEntry" id="email-entry">
-                    <property name="name">email-entry</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="margin_bottom">20</property>
-                    <property name="hexpand">True</property>
-                    <property name="input_purpose">email</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">1</property>
-                    <property name="top_attach">1</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="login-radio">
-                    <property name="label" translatable="yes">I have an Ubuntu Single Sign-On 
account</property>
-                    <property name="name">login-radio</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="margin_bottom">5</property>
-                    <property name="xalign">0</property>
-                    <property name="active">True</property>
-                    <property name="draw_indicator">True</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">2</property>
-                    <property name="width">2</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkAccelLabel">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="halign">end</property>
-                    <property name="margin_left">25</property>
-                    <property name="margin_right">10</property>
-                    <property name="margin_bottom">5</property>
-                    <property name="label" translatable="yes">_Password:</property>
-                    <property name="use_underline">True</property>
-                    <property name="xalign">1</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">3</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkEntry" id="password-entry">
-                    <property name="name">password-entry</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="margin_bottom">5</property>
-                    <property name="hexpand">True</property>
-                    <property name="visibility">False</property>
-                    <property name="invisible_char">•</property>
-                    <property name="input_purpose">password</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">1</property>
-                    <property name="top_attach">3</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkCheckButton" id="remember-check">
-                    <property name="label" translatable="yes">Sign in automatically next time</property>
-                    <property name="name">remember-check</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="margin_bottom">20</property>
-                    <property name="hexpand">True</property>
-                    <property name="xalign">0</property>
-                    <property name="draw_indicator">True</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">1</property>
-                    <property name="top_attach">4</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="register-radio">
-                    <property name="label" translatable="yes">I want to register for an account 
now</property>
-                    <property name="name">register-radio</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="margin_bottom">20</property>
-                    <property name="xalign">0</property>
-                    <property name="active">True</property>
-                    <property name="draw_indicator">True</property>
-                    <property name="group">login-radio</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">5</property>
-                    <property name="width">2</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="reset-radio">
-                    <property name="label" translatable="yes">I've forgotten my password</property>
-                    <property name="name">reset-radio</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="xalign">0</property>
-                    <property name="active">True</property>
-                    <property name="draw_indicator">True</property>
-                    <property name="group">login-radio</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">6</property>
-                    <property name="width">2</property>
-                  </packing>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-              </object>
-              <packing>
-                <property name="name">page-0</property>
-                <property name="title" translatable="yes">page-0</property>
-              </packing>
-            </child>
-            <child>
-              <object class="GtkGrid" id="page-1">
-                <property name="name">page-1</property>
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <child>
-                  <object class="GtkLabel">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="margin_bottom">20</property>
-                    <property name="label" translatable="yes">Enter your one-time password for two-factor 
authentication.</property>
-                    <property name="wrap">True</property>
-                    <property name="xalign">0</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">0</property>
-                    <property name="width">2</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkAccelLabel">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="margin_right">10</property>
-                    <property name="label" translatable="yes">One-time password:</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">1</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkEntry" id="passcode-entry">
-                    <property name="name">passcode-entry</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="hexpand">True</property>
-                    <property name="input_purpose">pin</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">1</property>
-                    <property name="top_attach">1</property>
-                  </packing>
-                </child>
-              </object>
-              <packing>
-                <property name="name">page-1</property>
-                <property name="title" translatable="yes">page-1</property>
-                <property name="position">1</property>
-              </packing>
-            </child>
-            <child>
-              <object class="GtkGrid" id="page-2">
-                <property name="name">page-2</property>
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <child>
-                  <object class="GtkLabel">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="label" translatable="yes">You are now signed into Ubuntu One.</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">0</property>
-                    <property name="top_attach">0</property>
-                  </packing>
-                </child>
-              </object>
-              <packing>
-                <property name="name">page-2</property>
-                <property name="title" translatable="yes">page-2</property>
-                <property name="position">2</property>
-              </packing>
-            </child>
-          </object>
-          <packing>
-            <property name="expand">True</property>
-            <property name="fill">True</property>
-            <property name="position">1</property>
-          </packing>
-        </child>
-      </object>
-      <packing>
-        <property name="expand">True</property>
-        <property name="fill">True</property>
-        <property name="position">0</property>
-      </packing>
-    </child>
-    <child>
-      <object class="GtkBox">
-        <property name="visible">True</property>
-        <property name="can_focus">False</property>
-        <property name="spacing">10</property>
-        <child>
-          <object class="GtkBox">
-            <property name="visible">True</property>
-            <property name="can_focus">False</property>
-            <child>
-              <object class="GtkStack" id="status-stack">
-                <property name="name">status-stack</property>
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <property name="margin_right">5</property>
-                <child>
-                  <object class="GtkImage" id="status-image">
-                    <property name="name">status-image</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                  </object>
-                  <packing>
-                    <property name="name">status-image</property>
-                    <property name="title" translatable="yes">status-image</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkSpinner" id="status-spinner">
-                    <property name="name">status-spinner</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="active">True</property>
-                  </object>
-                  <packing>
-                    <property name="name">status-spinner</property>
-                    <property name="title" translatable="yes">status-spinner</property>
-                    <property name="position">1</property>
-                  </packing>
-                </child>
-              </object>
-              <packing>
-                <property name="expand">False</property>
-                <property name="fill">True</property>
-                <property name="position">0</property>
-              </packing>
-            </child>
-            <child>
-              <object class="GtkLabel" id="status-label">
-                <property name="name">status-label</property>
-                <property name="visible">True</property>
-                <property name="can_focus">False</property>
-                <property name="xalign">0</property>
-              </object>
-              <packing>
-                <property name="expand">True</property>
-                <property name="fill">True</property>
-                <property name="position">1</property>
-              </packing>
-            </child>
-          </object>
-          <packing>
-            <property name="expand">True</property>
-            <property name="fill">True</property>
-            <property name="position">0</property>
-          </packing>
-        </child>
-        <child>
-          <object class="GtkButtonBox">
-            <property name="visible">True</property>
-            <property name="can_focus">False</property>
-            <property name="spacing">10</property>
-            <property name="layout_style">start</property>
-            <child>
-              <object class="GtkButton" id="cancel-button">
-                <property name="label" translatable="yes">Cancel</property>
-                <property name="name">cancel-button</property>
-                <property name="visible">True</property>
-                <property name="can_focus">True</property>
-                <property name="receives_default">True</property>
-              </object>
-              <packing>
-                <property name="expand">True</property>
-                <property name="fill">True</property>
-                <property name="position">0</property>
-              </packing>
-            </child>
-            <child>
-              <object class="GtkButton" id="next-button">
-                <property name="label" translatable="yes">_Continue</property>
-                <property name="name">next-button</property>
-                <property name="visible">True</property>
-                <property name="can_focus">True</property>
-                <property name="receives_default">True</property>
-                <property name="use_underline">True</property>
-              </object>
-              <packing>
-                <property name="expand">True</property>
-                <property name="fill">True</property>
-                <property name="position">1</property>
-              </packing>
-            </child>
-          </object>
-          <packing>
-            <property name="expand">False</property>
-            <property name="fill">True</property>
-            <property name="pack_type">end</property>
-            <property name="position">1</property>
-          </packing>
-        </child>
-      </object>
-      <packing>
-        <property name="expand">False</property>
-        <property name="fill">True</property>
-        <property name="position">1</property>
-      </packing>
-    </child>
-  </object>
+  <template class="UbuntuLoginDialog" parent="GtkDialog">
+    <object class="GtkBox" id="content_box">
+      <property name="visible">True</property>
+      <property name="can_focus">False</property>
+      <property name="margin_left">20</property>
+      <property name="margin_right">20</property>
+      <property name="margin_top">20</property>
+      <property name="margin_bottom">20</property>
+      <property name="orientation">vertical</property>
+      <property name="spacing">40</property>
+      <child>
+        <object class="GtkBox">
+          <property name="visible">True</property>
+          <property name="can_focus">False</property>
+          <property name="spacing">20</property>
+          <child>
+            <object class="GtkImage">
+              <property name="visible">True</property>
+              <property name="can_focus">False</property>
+              <property name="yalign">0</property>
+              <property name="resource">/org/gnome/Software/plugins/ubuntu-one.png</property>
+            </object>
+            <packing>
+              <property name="expand">False</property>
+              <property name="fill">True</property>
+              <property name="position">0</property>
+            </packing>
+          </child>
+          <child>
+            <object class="GtkStack" id="page_stack">
+              <property name="visible">True</property>
+              <property name="can_focus">False</property>
+              <child>
+                <object class="GtkGrid" id="page-0">
+                  <property name="visible">True</property>
+                  <property name="can_focus">False</property>
+                  <child>
+                    <object class="GtkLabel">
+                      <property name="visible">True</property>
+                      <property name="can_focus">False</property>
+                      <property name="margin_bottom">20</property>
+                      <property name="label" translatable="yes">To rate and review software, you need an 
Ubuntu Single Sign-On account.</property>
+                      <property name="wrap">True</property>
+                      <property name="xalign">0</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">0</property>
+                      <property name="width">2</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkAccelLabel">
+                      <property name="visible">True</property>
+                      <property name="can_focus">False</property>
+                      <property name="halign">end</property>
+                      <property name="margin_right">10</property>
+                      <property name="margin_bottom">20</property>
+                      <property name="label" translatable="yes">_Email address:</property>
+                      <property name="use_underline">True</property>
+                      <property name="xalign">1</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">1</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkEntry" id="email_entry">
+                      <property name="visible">True</property>
+                      <property name="can_focus">True</property>
+                      <property name="margin_bottom">20</property>
+                      <property name="hexpand">True</property>
+                      <property name="input_purpose">email</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">1</property>
+                      <property name="top_attach">1</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkRadioButton" id="login_radio">
+                      <property name="label" translatable="yes">I have an Ubuntu Single Sign-On 
account</property>
+                      <property name="visible">True</property>
+                      <property name="can_focus">True</property>
+                      <property name="receives_default">False</property>
+                      <property name="margin_bottom">5</property>
+                      <property name="xalign">0</property>
+                      <property name="active">True</property>
+                      <property name="draw_indicator">True</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">2</property>
+                      <property name="width">2</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkAccelLabel">
+                      <property name="visible">True</property>
+                      <property name="can_focus">False</property>
+                      <property name="halign">end</property>
+                      <property name="margin_left">25</property>
+                      <property name="margin_right">10</property>
+                      <property name="margin_bottom">5</property>
+                      <property name="label" translatable="yes">_Password:</property>
+                      <property name="use_underline">True</property>
+                      <property name="xalign">1</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">3</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkEntry" id="password_entry">
+                      <property name="visible">True</property>
+                      <property name="can_focus">True</property>
+                      <property name="margin_bottom">5</property>
+                      <property name="hexpand">True</property>
+                      <property name="visibility">False</property>
+                      <property name="invisible_char">•</property>
+                      <property name="input_purpose">password</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">1</property>
+                      <property name="top_attach">3</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkCheckButton" id="remember_check">
+                      <property name="label" translatable="yes">Sign in automatically next time</property>
+                      <property name="visible">True</property>
+                      <property name="can_focus">True</property>
+                      <property name="receives_default">False</property>
+                      <property name="margin_bottom">20</property>
+                      <property name="hexpand">True</property>
+                      <property name="xalign">0</property>
+                      <property name="draw_indicator">True</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">1</property>
+                      <property name="top_attach">4</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkRadioButton" id="register_radio">
+                      <property name="label" translatable="yes">I want to register for an account 
now</property>
+                      <property name="visible">True</property>
+                      <property name="can_focus">True</property>
+                      <property name="receives_default">False</property>
+                      <property name="margin_bottom">20</property>
+                      <property name="xalign">0</property>
+                      <property name="active">True</property>
+                      <property name="draw_indicator">True</property>
+                      <property name="group">login_radio</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">5</property>
+                      <property name="width">2</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkRadioButton" id="reset_radio">
+                      <property name="label" translatable="yes">I've forgotten my password</property>
+                      <property name="visible">True</property>
+                      <property name="can_focus">True</property>
+                      <property name="receives_default">False</property>
+                      <property name="xalign">0</property>
+                      <property name="active">True</property>
+                      <property name="draw_indicator">True</property>
+                      <property name="group">login_radio</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">6</property>
+                      <property name="width">2</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <placeholder/>
+                  </child>
+                </object>
+                <packing>
+                  <property name="name">page-0</property>
+                </packing>
+              </child>
+              <child>
+                <object class="GtkGrid" id="page-1">
+                  <property name="visible">True</property>
+                  <property name="can_focus">False</property>
+                  <child>
+                    <object class="GtkLabel">
+                      <property name="visible">True</property>
+                      <property name="can_focus">False</property>
+                      <property name="margin_bottom">20</property>
+                      <property name="label" translatable="yes">Enter your one-time password for two-factor 
authentication.</property>
+                      <property name="wrap">True</property>
+                      <property name="xalign">0</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">0</property>
+                      <property name="width">2</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkAccelLabel">
+                      <property name="visible">True</property>
+                      <property name="can_focus">False</property>
+                      <property name="margin_right">10</property>
+                      <property name="label" translatable="yes">One-time password:</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">1</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkEntry" id="passcode_entry">
+                      <property name="visible">True</property>
+                      <property name="can_focus">True</property>
+                      <property name="hexpand">True</property>
+                      <property name="input_purpose">pin</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">1</property>
+                      <property name="top_attach">1</property>
+                    </packing>
+                  </child>
+                </object>
+                <packing>
+                  <property name="name">page-1</property>
+                  <property name="position">1</property>
+                </packing>
+              </child>
+              <child>
+                <object class="GtkGrid" id="page-2">
+                  <property name="visible">True</property>
+                  <property name="can_focus">False</property>
+                  <child>
+                    <object class="GtkLabel">
+                      <property name="visible">True</property>
+                      <property name="can_focus">False</property>
+                      <property name="label" translatable="yes">You are now signed into Ubuntu 
One.</property>
+                    </object>
+                    <packing>
+                      <property name="left_attach">0</property>
+                      <property name="top_attach">0</property>
+                    </packing>
+                  </child>
+                </object>
+                <packing>
+                  <property name="name">page-2</property>
+                  <property name="position">2</property>
+                </packing>
+              </child>
+            </object>
+            <packing>
+              <property name="expand">True</property>
+              <property name="fill">True</property>
+              <property name="position">1</property>
+            </packing>
+          </child>
+        </object>
+        <packing>
+          <property name="expand">True</property>
+          <property name="fill">True</property>
+          <property name="position">0</property>
+        </packing>
+      </child>
+      <child>
+        <object class="GtkBox">
+          <property name="visible">True</property>
+          <property name="can_focus">False</property>
+          <property name="spacing">10</property>
+          <child>
+            <object class="GtkBox">
+              <property name="visible">True</property>
+              <property name="can_focus">False</property>
+              <child>
+                <object class="GtkStack" id="status_stack">
+                  <property name="visible">True</property>
+                  <property name="can_focus">False</property>
+                  <property name="margin_right">5</property>
+                  <child>
+                    <object class="GtkImage" id="status_image">
+                      <property name="visible">True</property>
+                      <property name="can_focus">False</property>
+                    </object>
+                    <packing>
+                      <property name="name">status-image</property>
+                    </packing>
+                  </child>
+                  <child>
+                    <object class="GtkSpinner" id="status_spinner">
+                      <property name="visible">True</property>
+                      <property name="can_focus">False</property>
+                      <property name="active">True</property>
+                    </object>
+                    <packing>
+                      <property name="name">status-spinner</property>
+                      <property name="position">1</property>
+                    </packing>
+                  </child>
+                </object>
+                <packing>
+                  <property name="expand">False</property>
+                  <property name="fill">True</property>
+                  <property name="position">0</property>
+                </packing>
+              </child>
+              <child>
+                <object class="GtkLabel" id="status_label">
+                  <property name="visible">True</property>
+                  <property name="can_focus">False</property>
+                  <property name="xalign">0</property>
+                </object>
+                <packing>
+                  <property name="expand">True</property>
+                  <property name="fill">True</property>
+                  <property name="position">1</property>
+                </packing>
+              </child>
+            </object>
+            <packing>
+              <property name="expand">True</property>
+              <property name="fill">True</property>
+              <property name="position">0</property>
+            </packing>
+          </child>
+          <child>
+            <object class="GtkButtonBox">
+              <property name="visible">True</property>
+              <property name="can_focus">False</property>
+              <property name="spacing">10</property>
+              <property name="layout_style">start</property>
+              <child>
+                <object class="GtkButton" id="cancel_button">
+                  <property name="label" translatable="yes">Cancel</property>
+                  <property name="visible">True</property>
+                  <property name="can_focus">True</property>
+                  <property name="receives_default">True</property>
+                </object>
+                <packing>
+                  <property name="expand">True</property>
+                  <property name="fill">True</property>
+                  <property name="position">0</property>
+                </packing>
+              </child>
+              <child>
+                <object class="GtkButton" id="next_button">
+                  <property name="label" translatable="yes">_Continue</property>
+                  <property name="visible">True</property>
+                  <property name="can_focus">True</property>
+                  <property name="receives_default">True</property>
+                  <property name="use_underline">True</property>
+                </object>
+                <packing>
+                  <property name="expand">True</property>
+                  <property name="fill">True</property>
+                  <property name="position">1</property>
+                </packing>
+              </child>
+            </object>
+            <packing>
+              <property name="expand">False</property>
+              <property name="fill">True</property>
+              <property name="pack_type">end</property>
+              <property name="position">1</property>
+            </packing>
+          </child>
+        </object>
+        <packing>
+          <property name="expand">False</property>
+          <property name="fill">True</property>
+          <property name="position">1</property>
+        </packing>
+      </child>
+    </object>
+  </template>
 </interface>



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