mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-07 03:34:15 +02:00
[view] improvement: not requesting confirmation for custom package actions that do not require it
This commit is contained in:
@@ -169,10 +169,10 @@ class PackagesTable(QTableWidget):
|
|||||||
else:
|
else:
|
||||||
body = '{} ?'.format(self.i18n[action.i18n_label_key])
|
body = '{} ?'.format(self.i18n[action.i18n_label_key])
|
||||||
|
|
||||||
if ConfirmationDialog(icon=QIcon(pkg.model.get_type_icon_path()),
|
if not action.requires_confirmation or ConfirmationDialog(icon=QIcon(pkg.model.get_type_icon_path()),
|
||||||
title=self.i18n[action.i18n_label_key],
|
title=self.i18n[action.i18n_label_key],
|
||||||
body=self._parag(body),
|
body=self._parag(body),
|
||||||
i18n=self.i18n).ask():
|
i18n=self.i18n).ask():
|
||||||
self.window.begin_execute_custom_action(pkg, action)
|
self.window.begin_execute_custom_action(pkg, action)
|
||||||
|
|
||||||
return QCustomMenuAction(parent=parent,
|
return QCustomMenuAction(parent=parent,
|
||||||
|
|||||||
Reference in New Issue
Block a user