[gnome-initial-setup] language: Actually update the regions on click
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-initial-setup] language: Actually update the regions on click
- Date: Thu, 26 Jul 2012 06:40:46 +0000 (UTC)
commit 8ff8178df5bf95df54dacb09ff023a91125fe82c
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Mon Jul 23 21:41:23 2012 -0300
language: Actually update the regions on click
.../pages/language/gis-language-page.c | 24 ++++++++++++++++++++
1 files changed, 24 insertions(+), 0 deletions(-)
---
diff --git a/gnome-initial-setup/pages/language/gis-language-page.c b/gnome-initial-setup/pages/language/gis-language-page.c
index e08b31f..4de027a 100644
--- a/gnome-initial-setup/pages/language/gis-language-page.c
+++ b/gnome-initial-setup/pages/language/gis-language-page.c
@@ -196,6 +196,27 @@ language_visible (GtkTreeModel *model,
return is_extra;
}
+static void
+selection_changed (GtkTreeSelection *selection,
+ LanguageData *data)
+{
+ GtkTreeModel *model;
+ GtkTreeIter iter;
+ gchar *new_locale_id;
+
+ gtk_tree_selection_get_selected (selection, &model, &iter);
+
+ g_free (data->locale_id);
+
+ gtk_tree_model_get (model, &iter,
+ COL_LOCALE_ID, &new_locale_id,
+ -1);
+
+ data->locale_id = new_locale_id;
+
+ sync_language (data);
+}
+
void
gis_prepare_language_page (SetupData *setup)
{
@@ -236,6 +257,9 @@ gis_prepare_language_page (SetupData *setup)
G_CALLBACK (gtk_tree_model_filter_refilter),
filter);
+ g_signal_connect (gtk_tree_view_get_selection (treeview), "changed",
+ G_CALLBACK (selection_changed), data);
+
gis_assistant_add_page (assistant, data->page);
gis_assistant_set_page_complete (assistant, data->page, TRUE);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]