[gnome-initial-setup] keyboard: Disregard the current locale when adding IBus engines
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-initial-setup] keyboard: Disregard the current locale when adding IBus engines
- Date: Wed, 17 Sep 2014 14:51:46 +0000 (UTC)
commit 5f0a764ddc35e34d15c3c7bee4d804c1f5d582cc
Author: Rui Matos <tiagomatos gmail com>
Date: Tue Sep 16 19:23:12 2014 +0200
keyboard: Disregard the current locale when adding IBus engines
Similarly to 198e3bbb080109188d21482214ca829ecbd19628 we should
include all the relevant IBus engines.
https://bugzilla.gnome.org/show_bug.cgi?id=736764
.../pages/keyboard/cc-input-chooser.c | 25 +------------------
1 files changed, 2 insertions(+), 23 deletions(-)
---
diff --git a/gnome-initial-setup/pages/keyboard/cc-input-chooser.c
b/gnome-initial-setup/pages/keyboard/cc-input-chooser.c
index 71ba5c7..469ac0a 100644
--- a/gnome-initial-setup/pages/keyboard/cc-input-chooser.c
+++ b/gnome-initial-setup/pages/keyboard/cc-input-chooser.c
@@ -593,34 +593,13 @@ get_ibus_locale_infos (CcInputChooser *chooser)
GHashTableIter iter;
const gchar *engine_id;
IBusEngineDesc *engine;
- gchar *lang, *country;
if (!priv->ibus_engines)
return;
- if (!gnome_parse_locale (priv->locale, &lang, &country, NULL, NULL))
- goto out;
-
g_hash_table_iter_init (&iter, priv->ibus_engines);
- while (g_hash_table_iter_next (&iter, (gpointer *) &engine_id, (gpointer *) &engine)) {
- gchar *ibus_lang = NULL;
- gchar *ibus_country = NULL;
- const gchar *locale;
-
- locale = ibus_engine_desc_get_language (engine);
-
- if (gnome_parse_locale (locale, &ibus_lang, &ibus_country, NULL, NULL)) {
- if (g_strcmp0 (lang, ibus_lang) == 0 &&
- (ibus_country == NULL || g_strcmp0 (country, ibus_country) == 0))
- add_row_to_list (chooser, INPUT_SOURCE_TYPE_IBUS, engine_id);
- }
- g_free (ibus_lang);
- g_free (ibus_country);
- }
-
-out:
- g_free (lang);
- g_free (country);
+ while (g_hash_table_iter_next (&iter, (gpointer *) &engine_id, (gpointer *) &engine))
+ add_row_to_list (chooser, INPUT_SOURCE_TYPE_IBUS, engine_id);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]