void keyboard_deinit(void) { while (keyinfos != NULL) keyinfo_remove(keyinfos->data); g_hash_table_destroy(keys); signal_remove("setup reread", (SIGNAL_FUNC) read_keyboard_config); }
void keyboard_deinit(void) { while (keyinfos != NULL) keyinfo_remove(keyinfos->data); g_hash_table_destroy(keys); signal_remove("irssi init read settings", (SIGNAL_FUNC) read_keyboard_config); signal_remove("setup reread", (SIGNAL_FUNC) read_keyboard_config); signal_remove("complete command bind", (SIGNAL_FUNC) sig_complete_bind); command_unbind("bind", (SIGNAL_FUNC) cmd_bind); }
void keyboard_deinit(void) { while (keyinfos != NULL) keyinfo_remove(keyinfos->data); g_hash_table_destroy(keys); g_hash_table_destroy(default_keys); g_tree_traverse(key_states, (GTraverseFunc) key_state_destroy, G_IN_ORDER, NULL); g_tree_destroy(key_states); signal_remove("irssi init read settings", (SIGNAL_FUNC) read_keyboard_config); signal_remove("setup reread", (SIGNAL_FUNC) read_keyboard_config); signal_remove("complete command bind", (SIGNAL_FUNC) sig_complete_bind); command_unbind("bind", (SIGNAL_FUNC) cmd_bind); }
/* Unbind key */ void key_unbind(gchar *id, SIGNAL_FUNC func) { KEYINFO_REC *info; g_return_if_fail(id != NULL); g_return_if_fail(func != NULL); /* remove keys */ info = key_info_find(id); if (info != NULL) keyinfo_remove(info); /* remove signal */ id = g_strconcat("key ", id, NULL); signal_remove(id, func); g_free(id); }
void keyboard_deinit(void) { key_unbind("command", (SIGNAL_FUNC) sig_command); key_unbind("key", (SIGNAL_FUNC) sig_key); key_unbind("multi", (SIGNAL_FUNC) sig_multi); key_unbind("nothing", (SIGNAL_FUNC) sig_nothing); while (keyinfos != NULL) keyinfo_remove(keyinfos->data); g_hash_table_destroy(keys); g_hash_table_destroy(default_keys); g_tree_foreach(key_states, (GTraverseFunc) key_state_destroy, NULL); g_tree_destroy(key_states); signal_remove("irssi init read settings", (SIGNAL_FUNC) read_keyboard_config); signal_remove("setup reread", (SIGNAL_FUNC) read_keyboard_config); signal_remove("complete command bind", (SIGNAL_FUNC) sig_complete_bind); command_unbind("bind", (SIGNAL_FUNC) cmd_bind); }