# HG changeset patch # User Mark Doliner # Date 1084667168 0 # Node ID 71fddf3f340d9b1aa10840a860ef2a110717115c # Parent b875f5d57b8187617c090a0be33b2e353001e00d [gaim-migrate @ 9711] Eradicate the two tab completion preferences. committer: Tailor Script diff -r b875f5d57b81 -r 71fddf3f340d src/gaimrc.c --- a/src/gaimrc.c Sun May 16 00:06:25 2004 +0000 +++ b/src/gaimrc.c Sun May 16 00:26:08 2004 +0000 @@ -118,7 +118,6 @@ #define OPT_CHAT_POPUP 0x00000010 #define OPT_CHAT_SIDE_TAB 0x00000020 #define OPT_CHAT_BR_TAB 0x00000040 -#define OPT_CHAT_TAB_COMPLETE 0x00000080 #define OPT_CHAT_OLD_STYLE_TAB 0x00000100 #define OPT_CHAT_COLORIZE 0x00000200 @@ -1072,10 +1071,6 @@ chat_options & OPT_CHAT_LOGON); gaim_prefs_set_bool("/gaim/gtk/conversations/chat/raise_on_events", chat_options & OPT_CHAT_POPUP); - gaim_prefs_set_bool("/gaim/gtk/conversations/chat/tab_completion", - chat_options & OPT_CHAT_TAB_COMPLETE); - gaim_prefs_set_bool("/gaim/gtk/conversations/chat/old_tab_complete", - chat_options & OPT_CHAT_OLD_STYLE_TAB); gaim_prefs_set_bool("/gaim/gtk/conversations/chat/color_nicks", chat_options & OPT_CHAT_COLORIZE); @@ -1401,7 +1396,6 @@ chat_options = OPT_CHAT_LOGON | OPT_CHAT_BUTTON_XPM | - OPT_CHAT_TAB_COMPLETE | OPT_CHAT_ONE_WINDOW; font_options = 0; diff -r b875f5d57b81 -r 71fddf3f340d src/gtkconv.c --- a/src/gtkconv.c Sun May 16 00:06:25 2004 +0000 +++ b/src/gtkconv.c Sun May 16 00:26:08 2004 +0000 @@ -1462,8 +1462,7 @@ break; case GDK_Tab: - if (gaim_conversation_get_type(conv) == GAIM_CONV_CHAT && - gaim_prefs_get_bool("/gaim/gtk/conversations/chat/tab_completion")) + if (gaim_conversation_get_type(conv) == GAIM_CONV_CHAT) { tab_complete(conv); return TRUE; @@ -2992,14 +2991,6 @@ entered = gtk_text_buffer_get_text(gtkconv->entry_buffer, &word_start, &cursor, FALSE); - if (gaim_prefs_get_bool("/gaim/gtk/conversations/chat/old_tab_complete")) { - if (strlen(entered) >= 2 && - !strncmp(": ", entered + strlen(entered) - 2, 2)) { - - entered[strlen(entered) - 2] = 0; - } - } - if (!g_utf8_strlen(entered, -1)) { g_free(entered); return; @@ -3020,41 +3011,6 @@ /* if we're here, it's a possible completion */ - /* if we're doing old-style, just fill in the completion */ - if (gaim_prefs_get_bool("/gaim/gtk/conversations/chat/old_tab_complete")) { - gtk_text_buffer_delete(gtkconv->entry_buffer, - &word_start, &cursor); - - if (strlen(nick) == strlen(entered)) { - nicks = (nicks->next - ? nicks->next - : gaim_conv_chat_get_users(chat)); - - nick = nicks->data; - } - - gtk_text_buffer_get_start_iter(gtkconv->entry_buffer, - &start_buffer); - gtk_text_buffer_get_iter_at_mark(gtkconv->entry_buffer, &cursor, - gtk_text_buffer_get_insert(gtkconv->entry_buffer)); - - if (!gtk_text_iter_compare(&cursor, &start_buffer)) { - char *tmp = g_strdup_printf("%s: ", nick); - gtk_text_buffer_insert_at_cursor(gtkconv->entry_buffer, - tmp, -1); - g_free(tmp); - } - else - gtk_text_buffer_insert_at_cursor(gtkconv->entry_buffer, - nick, -1); - - g_free(nick_partial); - g_free(entered); - - return; - } - - /* we're only here if we're doing new style */ if (most_matched == -1) { /* * this will only get called once, since from now @@ -5919,9 +5875,7 @@ gaim_prefs_add_int("/gaim/gtk/conversations/chat/button_type", GAIM_BUTTON_TEXT_IMAGE); gaim_prefs_add_bool("/gaim/gtk/conversations/chat/color_nicks", TRUE); - gaim_prefs_add_bool("/gaim/gtk/conversations/chat/old_tab_complete", FALSE); gaim_prefs_add_bool("/gaim/gtk/conversations/chat/raise_on_events", FALSE); - gaim_prefs_add_bool("/gaim/gtk/conversations/chat/tab_completion", TRUE); gaim_prefs_add_int("/gaim/gtk/conversations/chat/default_width", 410); gaim_prefs_add_int("/gaim/gtk/conversations/chat/default_height", 160); gaim_prefs_add_int("/gaim/gtk/conversations/chat/entry_height", 50); diff -r b875f5d57b81 -r 71fddf3f340d src/gtkprefs.c --- a/src/gtkprefs.c Sun May 16 00:06:25 2004 +0000 +++ b/src/gtkprefs.c Sun May 16 00:26:08 2004 +0000 @@ -1050,20 +1050,8 @@ gtk_size_group_add_widget(sg, dd); gtk_misc_set_alignment(GTK_MISC(dd), 0, 0); - gaim_gtk_prefs_labeled_spin_button(vbox, _("New window _width:"), - "/gaim/gtk/conversations/chat/default_width", 25, 9999, sg); - gaim_gtk_prefs_labeled_spin_button(vbox, _("New window _height:"), - "/gaim/gtk/conversations/chat/default_height", 25, 9999, sg); - gaim_gtk_prefs_labeled_spin_button(vbox, _("_Entry field height:"), - "/gaim/gtk/conversations/chat/entry_height", 25, 9999, sg); gaim_gtk_prefs_checkbox(_("_Raise window on events"), "/gaim/gtk/conversations/chat/raise_on_events", vbox); - - vbox = gaim_gtk_make_frame (ret, _("Tab Completion")); - gaim_gtk_prefs_checkbox(_("_Tab-complete nicks"), - "/gaim/gtk/conversations/chat/tab_completion", vbox); - gaim_gtk_prefs_checkbox(_("_Old-style tab completion"), - "/gaim/gtk/conversations/chat/old_tab_complete", vbox); #endif /* PREFSLASH04 */ vbox = gaim_gtk_make_frame (ret, _("Display")); #if 0 /* PREFSLASH04 */ @@ -3016,4 +3004,6 @@ /* Remove some no-longer-used prefs */ gaim_prefs_remove("/gaim/gtk/conversations/show_urls_as_links"); gaim_prefs_remove("/gaim/gtk/conversations/show_smileys"); + gaim_prefs_remove("/gaim/gtk/conversations/chat/tab_completion"); + gaim_prefs_remove("/gaim/gtk/conversations/chat/old_tab_complete"); }