summaryrefslogtreecommitdiff
path: root/community/ibus-hangul/ibus-1.4.0.patch
blob: 0c043d3740496806e11248ce9b4531305701b90b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
diff -Naur ibus-hangul-1.3.1-orig/configure.ac ibus-hangul-1.3.1/configure.ac
--- ibus-hangul-1.3.1-orig/configure.ac	2011-10-02 03:36:02.000000000 -0400
+++ ibus-hangul-1.3.1/configure.ac	2011-10-02 03:37:01.000000000 -0400
@@ -52,7 +52,7 @@
 
 # check ibus
 PKG_CHECK_MODULES(IBUS, [
-    ibus-1.0 >= 1.2.99
+    ibus-1.0 >= 1.3.99
 ])
 
 # check libhangul
diff -Naur ibus-hangul-1.3.1-orig/src/engine.c ibus-hangul-1.3.1/src/engine.c
--- ibus-hangul-1.3.1-orig/src/engine.c	2011-10-02 03:36:02.000000000 -0400
+++ ibus-hangul-1.3.1/src/engine.c	2011-10-02 03:37:51.000000000 -0400
@@ -175,8 +194,7 @@
 void
 ibus_hangul_init (IBusBus *bus)
 {
-    gboolean res;
-    GValue value = { 0, };
+    GVariant* value;
 
     hanja_table = hanja_table_load (NULL);
 
@@ -187,22 +205,22 @@
         g_object_ref_sink (config);
 
     hangul_keyboard = g_string_new_len ("2", 8);
-    res = ibus_config_get_value (config, "engine/Hangul",
-                                         "HangulKeyboard", &value);
-    if (res) {
-        const gchar* str = g_value_get_string (&value);
+    value = ibus_config_get_value (config, "engine/Hangul",
+                                         "HangulKeyboard");
+    if (value != NULL) {
+        const gchar* str = g_variant_get_string (value, NULL);
         g_string_assign (hangul_keyboard, str);
-        g_value_unset(&value);
+        g_variant_unref(value);
     }
 
     hanja_key_list_init(&hanja_keys);
 
-    res = ibus_config_get_value (config, "engine/Hangul",
-                                         "HanjaKeys", &value);
-    if (res) {
-        const gchar* str = g_value_get_string (&value);
+    value = ibus_config_get_value (config, "engine/Hangul",
+                                         "HanjaKeys");
+    if (value != NULL) {
+        const gchar* str = g_variant_get_string (value, NULL);
         hanja_key_list_set_from_string(&hanja_keys, str);
-        g_value_unset(&value);
+        g_variant_unref(value);
     } else {
 	hanja_key_list_append(&hanja_keys, IBUS_Hangul_Hanja, 0);
 	hanja_key_list_append(&hanja_keys, IBUS_F9, 0);