[evolution-patches] Patch for #61544



This patch fixes #61544 by setting the mnemonic widget of the label to
the source selector. This requires the name change in the glade, and a
few lines added to the code, because we can't specify the mnemonic
widget to be a custom widget in glade.

-- dobey

Index: gui/contact-editor/contact-editor.glade
===================================================================
RCS file: /cvs/gnome/evolution/addressbook/gui/contact-editor/contact-editor.glade,v
retrieving revision 1.66
diff -u -r1.66 contact-editor.glade
--- gui/contact-editor/contact-editor.glade	23 Jun 2004 23:38:41 -0000	1.66
+++ gui/contact-editor/contact-editor.glade	16 Jul 2004 20:38:33 -0000
@@ -197,7 +197,7 @@
 		      </child>
 
 		      <child>
-			<widget class="GtkLabel" id="label398">
+			<widget class="GtkLabel" id="where-label">
 			  <property name="visible">True</property>
 			  <property name="label" translatable="yes">_Where:</property>
 			  <property name="use_underline">True</property>
Index: gui/contact-editor/e-contact-editor.c
===================================================================
RCS file: /cvs/gnome/evolution/addressbook/gui/contact-editor/e-contact-editor.c,v
retrieving revision 1.211
diff -u -r1.211 e-contact-editor.c
--- gui/contact-editor/e-contact-editor.c	30 Jun 2004 15:32:37 -0000	1.211
+++ gui/contact-editor/e-contact-editor.c	16 Jul 2004 20:38:33 -0000
@@ -2913,7 +2913,7 @@
 e_contact_editor_init (EContactEditor *e_contact_editor)
 {
 	GladeXML *gui;
-	GtkWidget *widget;
+	GtkWidget *widget, *label;
 	char *icon_path;
 
 	e_contact_editor->name = e_contact_name_new();
@@ -2951,6 +2951,8 @@
 	g_signal_connect (widget, "clicked", G_CALLBACK (categories_clicked), e_contact_editor);
 	widget = glade_xml_get_widget (e_contact_editor->gui, "source-option-menu-source");
 	g_signal_connect (widget, "source_selected", G_CALLBACK (source_selected), e_contact_editor);
+	label = glade_xml_get_widget (e_contact_editor->gui, "where-label");
+	gtk_label_set_mnemonic_widget (GTK_LABEL (label), widget);
 	widget = glade_xml_get_widget (e_contact_editor->gui, "button-ok");
 	g_signal_connect (widget, "clicked", G_CALLBACK (file_save_and_close_cb), e_contact_editor);
 	widget = glade_xml_get_widget (e_contact_editor->gui, "button-cancel");


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]