Author: tkng
Date: Mon Aug  8 12:50:42 2005
New Revision: 1161

Modified:
   trunk/gtk/gtk-im-uim.c
   trunk/xim/helper.cpp

Log:
* gtk/gtk-im-uim.c:
 -(im_uim_parse_helper_str): Corresponded to custom_reload_notify.

* xim/helper.cpp:
 -(helper_str_parse): Corresponded to custom_reload_notify.


Modified: trunk/gtk/gtk-im-uim.c
==============================================================================
--- trunk/gtk/gtk-im-uim.c      (original)
+++ trunk/gtk/gtk-im-uim.c      Mon Aug  8 12:50:42 2005
@@ -986,15 +986,9 @@
   if (g_str_has_prefix(str, "im_change") == TRUE) {
     im_uim_parse_helper_str_im_change(str);
   } else if (g_str_has_prefix(str, "prop_update_custom") == TRUE) {
-    IMUIMContext *cc;
-    lines = g_strsplit(str, "\n", 0);
-    if (lines && lines[0] && lines[1] && lines[2]) {
-      for (cc = context_list.next; cc != &context_list; cc = cc->next) {
-       uim_prop_update_custom(cc->uc, lines[1], lines[2]);
-       break;  /* all custom variables are global */
-      }
-      g_strfreev(lines);
-    }
+    uim_prop_reload_configs();
+  } else if (g_str_has_prefix(str, "custom_reload_notify") == TRUE) {
+    uim_prop_reload_configs();
   } else if (focused_context && !disable_focused_context) {
     if (g_str_has_prefix(str, "prop_list_get") == TRUE) {
       uim_prop_list_update(focused_context->uc);

Modified: trunk/xim/helper.cpp
==============================================================================
--- trunk/xim/helper.cpp        (original)
+++ trunk/xim/helper.cpp        Mon Aug  8 12:50:42 2005
@@ -204,26 +204,9 @@
        parse_helper_str_im_change(line, engine);
        return;
     } else if (strcmp("prop_update_custom", line) == 0) {
-       line = eol + 1;
-       eol = strchr(line, '\n');
-       if (eol != NULL)
-           *eol = '\0';
-       else
-           return;
-
-       char *custom = line;
-       char *val = eol + 1;
-       eol = strchr(val, '\n');
-       if (eol != NULL)
-           *eol = '\0';
-       else
-           return;
-
-       std::map<Window, XimServer *>::iterator it;
-       for (it = XimServer::gServerMap.begin(); it != 
XimServer::gServerMap.end(); it++) {
-           (*it).second->customContext(custom, val);
-       }
-       return;
+       uim_prop_reload_configs();
+    } else if (strcmp("custom_reload_notify", line) == 0) {
+       uim_prop_reload_configs();
     }
 }
 

Reply via email to