aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMengjie Yu <meng-jie.yu@sun.com>2004-12-01 13:55:39 +0800
committerHarry Lu <haip@src.gnome.org>2004-12-01 13:55:39 +0800
commit604919b2ce39088d0e458eb193c064a027569504 (patch)
treeebc88ee1196085669c6cc2b338557dd66c4d03f0
parent80f08642d2c4dc8636e9fb90c935734703a54c78 (diff)
downloadgsoc2013-evolution-604919b2ce39088d0e458eb193c064a027569504.tar
gsoc2013-evolution-604919b2ce39088d0e458eb193c064a027569504.tar.gz
gsoc2013-evolution-604919b2ce39088d0e458eb193c064a027569504.tar.bz2
gsoc2013-evolution-604919b2ce39088d0e458eb193c064a027569504.tar.lz
gsoc2013-evolution-604919b2ce39088d0e458eb193c064a027569504.tar.xz
gsoc2013-evolution-604919b2ce39088d0e458eb193c064a027569504.tar.zst
gsoc2013-evolution-604919b2ce39088d0e458eb193c064a027569504.zip
add mnemonic for buttons. add atk name for the popup button. add access
2004-12-01 Mengjie Yu <meng-jie.yu@sun.com> * em-account-editor.c: (emae_option_toggle), (emae_receive_options_item):add mnemonic for buttons. * em-format-html-display.c: (efhd_attachment_button):add atk name for the popup button. * mail-account-gui.c: (mail_account_gui_build_extra_conf):add access key for checkbox. * message-list.c: (message_list_construct):add a atk name for the message list. svn path=/trunk/; revision=28029
-rw-r--r--mail/ChangeLog11
-rw-r--r--mail/em-account-editor.c12
-rw-r--r--mail/em-format-html-display.c6
-rw-r--r--mail/mail-account-gui.c9
-rw-r--r--mail/message-list.c6
5 files changed, 33 insertions, 11 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 23fc490568..4990848fe5 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,14 @@
+2004-12-01 Mengjie Yu <meng-jie.yu@sun.com>
+
+ * em-account-editor.c: (emae_option_toggle),
+ (emae_receive_options_item):add mnemonic for buttons.
+ * em-format-html-display.c: (efhd_attachment_button):add atk name
+ for the popup button.
+ * mail-account-gui.c: (mail_account_gui_build_extra_conf):add
+ access key for checkbox.
+ * message-list.c: (message_list_construct):add a atk name for the
+ message list.
+
2004-11-22 Not Zed <NotZed@Ximian.com>
** See bug #69339.
diff --git a/mail/em-account-editor.c b/mail/em-account-editor.c
index c4857432d4..6542911b18 100644
--- a/mail/em-account-editor.c
+++ b/mail/em-account-editor.c
@@ -1639,10 +1639,8 @@ emae_option_toggle(EMAccountEditorService *service, CamelURL *url, const char *t
GtkWidget *w;
/* FIXME: how do we get the default value ever? */
- w = g_object_new(gtk_check_button_get_type(),
- "label", text,
- "active", camel_url_get_param(url, name) != NULL,
- NULL);
+ w = gtk_check_button_new_with_mnemonic (text);
+ g_object_set_data ((GObject *)w, "active", camel_url_get_param (url, name) != NULL);
g_object_set_data((GObject *)w, "option-name", (void *)name);
g_signal_connect(w, "toggled", G_CALLBACK(emae_option_toggle_changed), service);
gtk_widget_show(w);
@@ -1785,7 +1783,7 @@ emae_receive_options_item(EConfig *ec, EConfigItem *item, struct _GtkWidget *par
row = ((GtkTable *)parent)->nrows;
box = gtk_hbox_new(FALSE, 4);
- w = gtk_check_button_new_with_label(_("Automatically check for _new mail every"));
+ w = gtk_check_button_new_with_mnemonic (_("Automatically check for _new mail every"));
emae_account_toggle_widget(emae, (GtkToggleButton *)w, E_ACCOUNT_SOURCE_AUTO_CHECK);
gtk_box_pack_start((GtkBox *)box, w, FALSE, FALSE, 0);
@@ -2067,7 +2065,7 @@ static EMConfigItem emae_editor_items[] = {
{ E_CONFIG_SECTION, "10.receive/30.auth", "vbox179", emae_widget_glade },
/* Most sections for this is auto-generated fromt the camel config */
- { E_CONFIG_PAGE, "20.receive_options", N_("Receiving Options"), },
+ { E_CONFIG_PAGE, "20.receive_options", N_("Receiving O_ptions"), },
{ E_CONFIG_SECTION_TABLE, "20.receive_options/10.mailcheck", N_("Checking for New Mail"), },
{ E_CONFIG_ITEM_TABLE, "20.receive_options/10.mailcheck/00.autocheck", NULL, emae_receive_options_item, },
@@ -2145,7 +2143,7 @@ static EMConfigItem emae_druid_items[] = {
{ E_CONFIG_SECTION, "10.receive/30.auth", "vbox179", emae_widget_glade },
/* Most sections for this is auto-generated fromt the camel config */
- { E_CONFIG_PAGE, "20.receive_options", N_("Receiving Options"), },
+ { E_CONFIG_PAGE, "20.receive_options", N_("Receiving O_ptions"), },
{ E_CONFIG_SECTION_TABLE, "20.receive_options/10.mailcheck", N_("Checking for New Mail"), },
{ E_CONFIG_ITEM_TABLE, "20.receive_options/10.mailcheck/00.autocheck", NULL, emae_receive_options_item, },
diff --git a/mail/em-format-html-display.c b/mail/em-format-html-display.c
index 5d58bf63b6..dee72303d6 100644
--- a/mail/em-format-html-display.c
+++ b/mail/em-format-html-display.c
@@ -1213,6 +1213,7 @@ efhd_attachment_button(EMFormatHTML *efh, GtkHTMLEmbedded *eb, EMFormatHTMLPObje
{ NULL, 0, 0 },
{ "text/uri-list", 0, 1 },
};
+ AtkObject *a11y;
/* FIXME: handle default shown case */
d(printf("adding attachment button/content\n"));
@@ -1292,6 +1293,11 @@ efhd_attachment_button(EMFormatHTML *efh, GtkHTMLEmbedded *eb, EMFormatHTMLPObje
button = gtk_button_new();
/*GTK_WIDGET_UNSET_FLAGS(button, GTK_CAN_FOCUS);*/
gtk_container_add((GtkContainer *)button, gtk_arrow_new(GTK_ARROW_DOWN, GTK_SHADOW_NONE));
+
+ a11y = gtk_widget_get_accessible (button);
+ atk_object_set_name (a11y, _("Attachment Button"));
+
+
g_signal_connect(button, "button_press_event", G_CALLBACK(efhd_attachment_popup), info);
g_signal_connect(button, "popup_menu", G_CALLBACK(efhd_attachment_popup_menu), info);
g_signal_connect(button, "clicked", G_CALLBACK(efhd_attachment_popup_menu), info);
diff --git a/mail/mail-account-gui.c b/mail/mail-account-gui.c
index 7f11421929..1335af7833 100644
--- a/mail/mail-account-gui.c
+++ b/mail/mail-account-gui.c
@@ -1091,7 +1091,7 @@ mail_account_gui_build_extra_conf (MailAccountGui *gui, const char *url_string)
enable_widget = path_label;
} else {
/* make a new label */
- label = gtk_label_new (entries[i].text);
+ label = gtk_label_new_with_mnemonic (entries[i].text);
gtk_table_resize (cur_table, cur_table->nrows + 1, 2);
gtk_table_attach (cur_table, label, 0, 2, rows, rows + 1,
GTK_EXPAND | GTK_FILL, 0, 0, 0);
@@ -1106,7 +1106,7 @@ mail_account_gui_build_extra_conf (MailAccountGui *gui, const char *url_string)
GtkWidget *checkbox;
gboolean active;
- checkbox = gtk_check_button_new_with_label (entries[i].text);
+ checkbox = gtk_check_button_new_with_mnemonic (entries[i].text);
if (url)
active = camel_url_get_param (url, entries[i].name) != NULL;
else
@@ -1143,9 +1143,10 @@ mail_account_gui_build_extra_conf (MailAccountGui *gui, const char *url_string)
entry = path;
} else {
/* make a new text entry with label */
- label = gtk_label_new (entries[i].text);
+ label = gtk_label_new_with_mnemonic (entries[i].text);
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.0);
entry = gtk_entry_new ();
+ gtk_label_set_mnemonic_widget (label, entry);
gtk_table_attach (cur_table, label, 0, 1, rows, rows + 1,
GTK_FILL, 0, 0, 0);
@@ -1211,7 +1212,7 @@ mail_account_gui_build_extra_conf (MailAccountGui *gui, const char *url_string)
}
hbox = gtk_hbox_new (FALSE, 0);
- checkbox = gtk_check_button_new_with_label (pre);
+ checkbox = gtk_check_button_new_with_mnemonic (pre);
g_free (pre);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (checkbox), enable);
adj = gtk_adjustment_new (def, min, max, 1, 1, 1);
diff --git a/mail/message-list.c b/mail/message-list.c
index 590e58f0ad..4dbca08a7f 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -1997,6 +1997,7 @@ message_list_class_init (MessageListClass *message_list_class)
static void
message_list_construct (MessageList *message_list)
{
+ AtkObject *a11y;
gboolean construct_failed;
message_list->model =
e_tree_memory_callbacks_new (ml_tree_icon_at,
@@ -2038,6 +2039,11 @@ message_list_construct (MessageList *message_list)
if (!construct_failed)
e_tree_root_node_set_visible (message_list->tree, FALSE);
+ if (atk_get_root () != NULL) {
+ a11y = gtk_widget_get_accessible (message_list->tree);
+ atk_object_set_name (a11y, _("Message List"));
+ }
+
g_signal_connect((message_list->tree), "cursor_activated",
G_CALLBACK (on_cursor_activated_cmd),
message_list);