[Fedora-i18n-bugs] [ibus-m17n] Update to 1.3.1-13.

Daiki Ueno ueno at fedoraproject.org
Mon Dec 27 05:47:55 UTC 2010


commit e8171a81f11ac9e610e6295c50a82e9f2cb736fc
Author: Daiki Ueno <ueno at unixuser.org>
Date:   Mon Dec 27 14:52:29 2010 +0900

    Update to 1.3.1-13.

 ibus-m17n-iok.patch |   47 +++++++++++++++++++++++++++++------------------
 ibus-m17n.spec      |    5 ++++-
 2 files changed, 33 insertions(+), 19 deletions(-)
---
diff --git a/ibus-m17n-iok.patch b/ibus-m17n-iok.patch
index c6e4ca2..19dc2a1 100644
--- a/ibus-m17n-iok.patch
+++ b/ibus-m17n-iok.patch
@@ -1,14 +1,14 @@
-From 17e633c3e3cbfd1a240b95352167005a8396a7b2 Mon Sep 17 00:00:00 2001
+From e494dd5bde1640bc11e0be4296e7a85e88701cbe Mon Sep 17 00:00:00 2001
 From: Daiki Ueno <ueno at unixuser.org>
 Date: Wed, 8 Dec 2010 18:06:11 +0900
 Subject: [PATCH] Apply iok patch from fedora.
 
 ---
- src/engine.c |   46 ++++++++++++++++++++++++++++++++++++++++++++++
- 1 files changed, 46 insertions(+), 0 deletions(-)
+ src/engine.c |   43 +++++++++++++++++++++++++++++++++++++++++++
+ 1 files changed, 43 insertions(+), 0 deletions(-)
 
 diff --git a/src/engine.c b/src/engine.c
-index f8e7fe5..ff8bbfc 100644
+index f8e7fe5..04b0722 100644
 --- a/src/engine.c
 +++ b/src/engine.c
 @@ -35,6 +35,7 @@ struct _IBusM17NEngine {
@@ -19,27 +19,38 @@ index f8e7fe5..ff8bbfc 100644
  };
  
  struct _IBusM17NEngineClass {
-@@ -411,6 +412,8 @@ ibus_m17n_engine_init (IBusM17NEngine *m17n)
+@@ -46,6 +47,7 @@ struct _IBusM17NEngineClass {
+     guint preedit_background;
+     gint preedit_underline;
+     gint lookup_table_orientation;
++    gboolean use_iok;
+ 
+     MInputMethod *im;
+ };
+@@ -309,6 +311,9 @@ ibus_m17n_engine_class_init (IBusM17NEngineClass *klass)
+     }
+     engine_name = g_strdup_printf ("m17n:%s:%s", lang, name);
+     klass->config_section = g_strdup_printf ("engine/M17N/%s/%s", lang, name);
++    /* whether to use iok - maybe good to move this to default.xml */
++    klass->use_iok = g_strcmp0 (name, "inscript") == 0 ||
++        g_strcmp0 (name, "inscript2") == 0;
+     g_free (lang);
+     g_free (name);
+ 
+@@ -411,6 +416,7 @@ ibus_m17n_engine_init (IBusM17NEngine *m17n)
  {
      IBusText* label;
      IBusText* tooltip;
-+    const gchar *engine_name;
-+    gchar *lang = NULL, *name = NULL;
++    IBusM17NEngineClass *klass = (IBusM17NEngineClass *) G_OBJECT_GET_CLASS (m17n);
  
      m17n->status_prop = ibus_property_new ("status",
                                             PROP_TYPE_NORMAL,
-@@ -436,10 +439,32 @@ ibus_m17n_engine_init (IBusM17NEngine *m17n)
+@@ -436,10 +442,26 @@ ibus_m17n_engine_init (IBusM17NEngine *m17n)
                                            NULL);
      g_object_ref_sink (m17n->setup_prop);
  
-+    /* show iok icon for inscript - should be go in default.xml? */
-+    engine_name = ibus_engine_get_name ((IBusEngine *) m17n);
-+    if (ibus_m17n_scan_engine_name (engine_name, &lang, &name) &&
-+        (g_strcmp0 (name, "inscript") == 0 ||
-+         g_strcmp0 (name, "inscript2") == 0))
++    if (klass->use_iok)
 +        ibus_property_set_visible (m17n->show_iok_prop, TRUE);
-+    g_free (lang);
-+    g_free (name);
 +
 +    label = ibus_text_new_from_string ("iok");
 +    m17n->show_iok_prop = ibus_property_new ("iok",
@@ -61,7 +72,7 @@ index f8e7fe5..ff8bbfc 100644
  
      m17n->table = ibus_lookup_table_new (9, 0, TRUE, TRUE);
      g_object_ref_sink (m17n->table);
-@@ -524,6 +549,11 @@ ibus_m17n_engine_destroy (IBusM17NEngine *m17n)
+@@ -524,6 +546,11 @@ ibus_m17n_engine_destroy (IBusM17NEngine *m17n)
          m17n->setup_prop = NULL;
      }
  
@@ -73,7 +84,7 @@ index f8e7fe5..ff8bbfc 100644
      if (m17n->table) {
          g_object_unref (m17n->table);
          m17n->table = NULL;
-@@ -827,6 +857,22 @@ ibus_m17n_engine_property_activate (IBusEngine  *engine,
+@@ -827,6 +854,22 @@ ibus_m17n_engine_property_activate (IBusEngine  *engine,
                                   LIBEXECDIR, engine_name);
          g_spawn_command_line_async (setup, NULL);
          g_free (setup);
@@ -97,5 +108,5 @@ index f8e7fe5..ff8bbfc 100644
      parent_class->property_activate (engine, prop_name, prop_state);
  }
 -- 
-1.7.3.3
+1.7.3.4
 
diff --git a/ibus-m17n.spec b/ibus-m17n.spec
index 467317c..9bbc058 100644
--- a/ibus-m17n.spec
+++ b/ibus-m17n.spec
@@ -2,7 +2,7 @@
 
 Name:       ibus-m17n
 Version:    1.3.1
-Release:    12%{?dist}
+Release:    13%{?dist}
 Summary:    The M17N engine for IBus platform
 License:    GPLv2+
 Group:      System Environment/Libraries
@@ -66,6 +66,9 @@ rm -rf $RPM_BUILD_ROOT
 %{_datadir}/ibus/component/*
 
 %changelog
+* Mon Dec 27 2010 Daiki Ueno <dueno at redhat.com> - 1.3.1-13
+- Update iok patch.
+
 * Wed Dec 22 2010 Daiki Ueno <dueno at redhat.com> - 1.3.1-12
 - Update surrounding-text patch.
 


More information about the i18n-bugs mailing list