Skip to content

Commit

Permalink
PSCycle.MNT: fix bug in button enumeration
Browse files Browse the repository at this point in the history
  • Loading branch information
anacso17 committed Jan 7, 2025
1 parent 9a240af commit e1aae39
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions pyqt-apps/siriushla/as_ps_cycle/cycle_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -207,8 +207,7 @@ def _setup_ui(self):
lb_cycle = QLabel('<h4>Cycle</h4>', self,
alignment=Qt.AlignCenter)

self.cycle_trims_bt = QPushButton(
'9. Cycle Trims', self)
self.cycle_trims_bt = QPushButton('9. Cycle Trims', self)
self.cycle_trims_bt.setToolTip(
'Cycle trims:\nStep 1) CH, QS and QTrims\nStep 2) CV')
self.cycle_trims_bt.clicked.connect(
Expand All @@ -220,8 +219,7 @@ def _setup_ui(self):
self.cycle_trims_lb.setPixmap(self._pixmap_check)
self.cycle_trims_lb.setVisible(False)

self.cycle_bt = QPushButton(
'10. Cycle', self)
self.cycle_bt = QPushButton('10. Cycle', self)
self.cycle_bt.setToolTip(
'Check all configurations,\nenable triggers and run cycle.')
self.cycle_bt.clicked.connect(
Expand Down Expand Up @@ -565,16 +563,16 @@ def _update_setup(self):
has_sifam |= item.checkState(0) != 0

if not has_sifam:
self.cycle_bt.setText('8. Cycle')
self.cycle_bt.setText('9. Cycle')
self.restore_timing_bt.setText(
'9. Restore Timing Initial State')
'10. Restore Timing Initial State')
self.cycle_trims_bt.setVisible(False)
self.cycle_trims_lb.setVisible(False)
self._prepared['trims'] = True
else:
self.cycle_bt.setText('9. Cycle')
self.cycle_bt.setText('10. Cycle')
self.restore_timing_bt.setText(
'10. Restore Timing Initial State')
'11. Restore Timing Initial State')
self.cycle_trims_bt.setVisible(True)
self.cycle_trims_lb.setVisible(True)
self._prepared['trims'] = False
Expand Down

0 comments on commit e1aae39

Please sign in to comment.