From bc1b2ed6d29f370a3de9e7b5401a50007a72b9ee Mon Sep 17 00:00:00 2001 From: jbellister-slac Date: Mon, 6 Mar 2023 10:33:28 -0800 Subject: [PATCH 1/2] FIX: Store added display actions --- slam/alarm_tree_view.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/slam/alarm_tree_view.py b/slam/alarm_tree_view.py index e35562e..22a732b 100644 --- a/slam/alarm_tree_view.py +++ b/slam/alarm_tree_view.py @@ -62,6 +62,7 @@ def __init__(self, kafka_producer: KafkaProducer, topic: str, plot_slot: Callabl self.plot_action = QAction('Draw Plot') self.enable_action = QAction('Enable') self.disable_action = QAction('Disable') + self.display_actions = [] self.acknowledge_action.triggered.connect(self.send_acknowledgement) self.unacknowledge_action.triggered.connect(self.send_unacknowledgement) @@ -111,11 +112,13 @@ def tree_menu(self, pos: QPoint) -> None: self.context_menu.addAction(self.unacknowledge_action) self.context_menu.addAction(self.enable_action) self.context_menu.addAction(self.disable_action) + self.display_actions.clear() if alarm_item.displays: for display in alarm_item.displays: display_action = QAction(display['title']) display_action.triggered.connect(partial(self.launch_pydm_display, display['details'])) self.context_menu.addAction(display_action) + self.display_actions.append(display_action) self.context_menu.popup(self.mapToGlobal(pos)) def create_alarm_configuration_widget(self, index: QModelIndex) -> None: From afb94c6774fc356b6e383f274a1c5372e2c03ed8 Mon Sep 17 00:00:00 2001 From: jbellister-slac Date: Mon, 6 Mar 2023 10:36:05 -0800 Subject: [PATCH 2/2] BLD: Bump version number --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 06d7daf..cbab595 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ setup( name='slac-alarm-manager', - version='1.1.1', + version='1.1.2', description='Python interface for managing alarms', long_description=long_description, long_description_content_type='text/markdown',