+ if (curpos != NULL) {
+ gchar *text = NULL;
+ GList *it;
+
+ for (it = curpos->keylist; it; it = g_list_next(it))
+ text = g_strconcat((text ? text : ""), it->data, "-", NULL);
+
+ popup_position(popup, NorthWestGravity, 10, 10);
+ if (popup->mapped) {
+ popup_show_timeout(text);
+ g_free(text);
+ } else {
+ ob_main_loop_timeout_remove(ob_main_loop, popup_show_timeout);
+ ob_main_loop_timeout_add(ob_main_loop, 1 * G_USEC_PER_SEC,
+ popup_show_timeout, text,
+ g_direct_equal, g_free);
+ }
+ } else {
+ popup_hide(popup);
+ ob_main_loop_timeout_remove(ob_main_loop, popup_show_timeout);
+ }