[gnome-initial-setup] language page: Go to next when active row is activated twice
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-initial-setup] language page: Go to next when active row is activated twice
- Date: Sun, 7 Sep 2014 15:19:11 +0000 (UTC)
commit 89a353777ac3a4efe9fed5093c858582e526b9b1
Author: Matthias Clasen <mclasen redhat com>
Date: Sun Sep 7 09:49:59 2014 -0400
language page: Go to next when active row is activated twice
This lets you hit Enter twice to select a language and go to the
next page, which is expected behavior in wizard-like UIs like
this.
.../pages/language/cc-language-chooser.c | 12 ++++++------
.../pages/language/gis-language-page.c | 9 +++++++++
2 files changed, 15 insertions(+), 6 deletions(-)
---
diff --git a/gnome-initial-setup/pages/language/cc-language-chooser.c
b/gnome-initial-setup/pages/language/cc-language-chooser.c
index 0b61916..d333710 100644
--- a/gnome-initial-setup/pages/language/cc-language-chooser.c
+++ b/gnome-initial-setup/pages/language/cc-language-chooser.c
@@ -545,12 +545,12 @@ cc_language_chooser_class_init (CcLanguageChooserClass *klass)
object_class->constructed = cc_language_chooser_constructed;
signals[CONFIRM] = g_signal_new ("confirm",
- G_TYPE_FROM_CLASS (object_class),
- G_SIGNAL_RUN_FIRST,
- G_STRUCT_OFFSET (CcLanguageChooserClass, confirm),
- NULL, NULL,
- g_cclosure_marshal_VOID__VOID,
- G_TYPE_NONE, 0);
+ G_TYPE_FROM_CLASS (object_class),
+ G_SIGNAL_RUN_FIRST,
+ G_STRUCT_OFFSET (CcLanguageChooserClass, confirm),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
obj_props[PROP_LANGUAGE] =
g_param_spec_string ("language", "", "", "",
diff --git a/gnome-initial-setup/pages/language/gis-language-page.c
b/gnome-initial-setup/pages/language/gis-language-page.c
index b29c93f..d13d3ac 100644
--- a/gnome-initial-setup/pages/language/gis-language-page.c
+++ b/gnome-initial-setup/pages/language/gis-language-page.c
@@ -229,6 +229,13 @@ update_distro_logo (GisLanguagePage *page)
}
static void
+language_confirmed (CcLanguageChooser *chooser,
+ GisLanguagePage *page)
+{
+ gis_assistant_next_page (gis_driver_get_assistant (GIS_PAGE (page)->driver));
+}
+
+static void
gis_language_page_constructed (GObject *object)
{
GisLanguagePage *page = GIS_LANGUAGE_PAGE (object);
@@ -243,6 +250,8 @@ gis_language_page_constructed (GObject *object)
g_signal_connect (priv->language_chooser, "notify::language",
G_CALLBACK (language_changed), page);
+ g_signal_connect (priv->language_chooser, "confirm",
+ G_CALLBACK (language_confirmed), page);
/* If we're in new user mode then we're manipulating system settings */
if (gis_driver_get_mode (GIS_PAGE (page)->driver) == GIS_DRIVER_MODE_NEW_USER)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]