diff options
Diffstat (limited to 'addressbook/gui/widgets')
-rw-r--r-- | addressbook/gui/widgets/e-addressbook-view.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/addressbook/gui/widgets/e-addressbook-view.c b/addressbook/gui/widgets/e-addressbook-view.c index 37d1376340..bcf6ed6277 100644 --- a/addressbook/gui/widgets/e-addressbook-view.c +++ b/addressbook/gui/widgets/e-addressbook-view.c @@ -587,6 +587,12 @@ addressbook_view_update_actions (ESelectable *selectable, gtk_action_set_sensitive (action, sensitive); gtk_action_set_tooltip (action, tooltip); + action = e_focus_tracker_get_delete_selection_action (focus_tracker); + sensitive = source_is_editable && (n_selected > 0); + tooltip = _("Delete selected contacts"); + gtk_action_set_sensitive (action, sensitive); + gtk_action_set_tooltip (action, tooltip); + action = e_focus_tracker_get_select_all_action (focus_tracker); sensitive = (n_contacts > 0); tooltip = _("Select all visible contacts"); @@ -660,6 +666,16 @@ addressbook_view_paste_clipboard (ESelectable *selectable) } static void +addressbook_view_delete_selection (ESelectable *selectable) +{ + EAddressbookView *view; + + view = E_ADDRESSBOOK_VIEW (selectable); + + e_addressbook_view_delete_selection (view, TRUE); +} + +static void addressbook_view_select_all (ESelectable *selectable) { EAddressbookView *view; @@ -782,6 +798,7 @@ addressbook_view_selectable_init (ESelectableInterface *interface) interface->cut_clipboard = addressbook_view_cut_clipboard; interface->copy_clipboard = addressbook_view_copy_clipboard; interface->paste_clipboard = addressbook_view_paste_clipboard; + interface->delete_selection = addressbook_view_delete_selection; interface->select_all = addressbook_view_select_all; } |