[gnome-boxes] wizard: Drop intro page
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes] wizard: Drop intro page
- Date: Fri, 13 Feb 2015 17:22:36 +0000 (UTC)
commit d559d6216ba181d2e72f466ae6116f35d7dde82b
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Fri Feb 13 17:10:18 2015 +0000
wizard: Drop intro page
Now that we have a nice looking first-time UI, this is kinda redundant
and its pretty useless and annoying for users who use wizard on regular
bases.
data/ui/wizard.ui | 53 -----------------------------------------------
src/wizard-toolbar.vala | 6 +----
src/wizard.vala | 14 ++++--------
3 files changed, 6 insertions(+), 67 deletions(-)
---
diff --git a/data/ui/wizard.ui b/data/ui/wizard.ui
index 94c94f9..778331a 100644
--- a/data/ui/wizard.ui
+++ b/data/ui/wizard.ui
@@ -8,59 +8,6 @@
<property name="hexpand">True</property>
<property name="vexpand">True</property>
- <!-- Introduction -->
- <child>
- <object class="GtkBox" id="intro_box">
- <property name="visible">True</property>
- <style>
- <class name="content-bg"/>
- </style>
-
- <child>
- <object class="GtkBox" id="intro_hbox">
- <property name="visible">True</property>
- <property name="orientation">horizontal</property>
- <property name="spacing">10</property>
- <property name="margin-start">10</property>
- <property name="margin-end">10</property>
- <property name="halign">center</property>
-
- <child>
- <object class="GtkImage" id="intro_image">
- <property name="visible">True</property>
- <property name="resource">/org/gnome/Boxes/icons/boxes-create.png</property>
- <property name="hexpand">True</property>
- <property name="halign">end</property>
- </object>
- </child>
-
- <child>
- <object class="GtkLabel" id="intro_label">
- <property name="visible">True</property>
- <property name="wrap">True</property>
- <!-- Work around clutter size allocation issue (bz#677260) -->
- <property name="max-width-chars">40</property>
- <property name="use-markup">True</property>
- <property name="label" translatable="yes">Creating a box will allow you to use another
operating system directly from your existing login.
-
-You may connect to an existing machine <b><i>over the network</i></b> or create a
<b><i>virtual machine</i></b> that runs locally on your own.</property>
- <property name="use-markup">True</property>
- <property name="hexpand">True</property>
- <property name="halign">start</property>
- <style>
- <class name="boxes-wizard-label"/>
- </style>
- </object>
- </child>
- </object>
- </child>
- </object>
-
- <packing>
- <property name="name">introduction</property>
- </packing>
- </child>
-
<!-- Source -->
<child>
<object class="GtkBox" id="source_box">
diff --git a/src/wizard-toolbar.vala b/src/wizard-toolbar.vala
index 021ba0d..4215dac 100644
--- a/src/wizard-toolbar.vala
+++ b/src/wizard-toolbar.vala
@@ -56,12 +56,8 @@ private class Boxes.WizardToolbar: Gtk.Stack {
case WizardPage.LAST:
break;
- case WizardPage.INTRODUCTION:
- main.title = _("Create a box");
-
- break;
default:
- main.title = _("Create a box (step %d/4)").printf (page);
+ main.title = _("Create a box (step %d/4)").printf (page + 1);
break;
}
diff --git a/src/wizard.vala b/src/wizard.vala
index 34c0c08..64ddf75 100644
--- a/src/wizard.vala
+++ b/src/wizard.vala
@@ -1,7 +1,6 @@
// This file is part of GNOME Boxes. License: LGPLv2+
private enum Boxes.WizardPage {
- INTRODUCTION,
SOURCE,
PREPARATION,
SETUP,
@@ -14,7 +13,7 @@ private enum Boxes.WizardPage {
private class Boxes.Wizard: Gtk.Stack, Boxes.UI {
private const double DOWNLOAD_PROGRESS_SCALE = 0.95;
private const double PREPARE_PROGRESS_SCALE = 0.05;
- private const string[] page_names = { "introduction", "source", "preparation", "setup", "review" };
+ private const string[] page_names = { "source", "preparation", "setup", "review" };
public UIState previous_ui_state { get; protected set; }
public UIState ui_state { get; protected set; }
@@ -62,21 +61,18 @@ private class Boxes.Wizard: Gtk.Stack, Boxes.UI {
public WizardPage page {
get { return _page; }
set {
- back_button.sensitive = (value != WizardPage.INTRODUCTION);
+ back_button.sensitive = (value != WizardPage.SOURCE);
var forwards = value > page;
switch (value) {
- case WizardPage.INTRODUCTION:
+ case WizardPage.SOURCE:
+ // reset page to notify deeply widgets states
create_button.visible = false;
continue_button.visible = true;
next_button = continue_button;
next_button.sensitive = true;
next_button.grab_focus ();
- break;
-
- case WizardPage.SOURCE:
- // reset page to notify deeply widgets states
wizard_source.page = wizard_source.page;
cleanup ();
break;
@@ -649,7 +645,7 @@ private class Boxes.Wizard: Gtk.Stack, Boxes.UI {
wizard_source.uri = "";
wizard_source.libvirt_sys_import = false;
- page = WizardPage.INTRODUCTION;
+ page = WizardPage.SOURCE;
}
private void destroy_machine () {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]