set focus to ok button in delete confirmation dialog(history manager)
This commit is contained in:
parent
769ce99f6c
commit
79e9d96b39
|
@ -573,9 +573,11 @@ class HistoryManager:
|
|||
'Do you really want to delete logs of the selected contact?',
|
||||
'Do you really want to delete logs of the selected contacts?',
|
||||
paths_len)
|
||||
dialogs.ConfirmationDialog(pri_text,
|
||||
dialog = dialogs.ConfirmationDialog(pri_text,
|
||||
_('This is an irreversible operation.'), on_response_ok = (on_ok,
|
||||
liststore, list_of_paths))
|
||||
ok_button = dialog.get_children()[0].get_children()[1].get_children()[0]
|
||||
ok_button.grab_focus()
|
||||
|
||||
def _delete_logs(self, liststore, list_of_paths):
|
||||
paths_len = len(list_of_paths)
|
||||
|
@ -608,9 +610,11 @@ class HistoryManager:
|
|||
pri_text = i18n.ngettext(
|
||||
'Do you really want to delete the selected message?',
|
||||
'Do you really want to delete the selected messages?', paths_len)
|
||||
dialogs.ConfirmationDialog(pri_text,
|
||||
dialog = dialogs.ConfirmationDialog(pri_text,
|
||||
_('This is an irreversible operation.'), on_response_ok = (on_ok,
|
||||
liststore, list_of_paths))
|
||||
ok_button = dialog.get_children()[0].get_children()[1].get_children()[0]
|
||||
ok_button.grab_focus()
|
||||
|
||||
def on_search_db_button_clicked(self, widget):
|
||||
text = self.search_entry.get_text().decode('utf-8')
|
||||
|
|
Loading…
Reference in New Issue