From 389d996b830f01f598433a2cd4301d4518683f33 Mon Sep 17 00:00:00 2001 From: Matthew Brush Date: Fri, 14 Oct 2011 21:19:06 -0700 Subject: [PATCH] Show the correct Preferences tab when activated from the VTE context menu --- src/vte.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/vte.c b/src/vte.c index 12037eb2..deb0287b 100644 --- a/src/vte.c +++ b/src/vte.c @@ -490,13 +490,16 @@ static void vte_popup_menu_clicked(GtkMenuItem *menuitem, gpointer user_data) } case POPUP_PREFERENCES: { - GtkWidget *notebook; + GObject *notebook, *tab_page; prefs_show_dialog(); - notebook = ui_lookup_widget(ui_widgets.prefs_dialog, "notebook2"); + notebook = ui_lookup_object("notebook2"); + tab_page = ui_lookup_object("frame_term"); + + gtk_notebook_set_current_page(GTK_NOTEBOOK(notebook), + gtk_notebook_page_num(GTK_NOTEBOOK(notebook), GTK_WIDGET(tab_page))); - gtk_notebook_set_current_page(GTK_NOTEBOOK(notebook), vte_prefs_tab_num); break; } }