Polish transport spacing, drop shortcut hints, add Detect Next Clap button
- PlayerPanel now leaves an 8px bottom margin so the transport row isn't flush against the tab's edge. - Frame-step buttons read '⏮ Frame' / 'Frame ⏭' instead of '⏮ Frame (,)' / 'Frame ⏭ (.)' -- the shortcuts still work, just not spelled out on the buttons. - Detect Next Clap is now a button in the Sync markers panel next to Detect All Claps (still also in the Tools menu), kept in sync with its menu action's enabled state the same way Detect All Claps was.
This commit is contained in:
@@ -133,6 +133,11 @@ class MainWindow(QMainWindow):
|
||||
self.detect_all_button.clicked.connect(self._on_detect_all_clicked)
|
||||
marker_layout.addWidget(self.detect_all_button)
|
||||
|
||||
self.detect_next_button = QPushButton("Detect Next Clap")
|
||||
self.detect_next_button.setEnabled(False)
|
||||
self.detect_next_button.clicked.connect(self._on_detect_next_clicked)
|
||||
marker_layout.addWidget(self.detect_next_button)
|
||||
|
||||
layout.addWidget(marker_group)
|
||||
|
||||
# Offset + preview + export row
|
||||
@@ -241,6 +246,7 @@ class MainWindow(QMainWindow):
|
||||
self.detect_all_action.setEnabled(True)
|
||||
self.detect_all_button.setEnabled(True)
|
||||
self.detect_next_action.setEnabled(True)
|
||||
self.detect_next_button.setEnabled(True)
|
||||
|
||||
# A loaded preview belongs to the *previous* source/offset -- drop it.
|
||||
if self._preview_temp_path and os.path.exists(self._preview_temp_path):
|
||||
@@ -357,6 +363,7 @@ class MainWindow(QMainWindow):
|
||||
self.detect_all_action.setEnabled(False)
|
||||
self.detect_all_button.setEnabled(False)
|
||||
self.detect_next_action.setEnabled(False)
|
||||
self.detect_next_button.setEnabled(False)
|
||||
self.statusBar().showMessage(label)
|
||||
|
||||
self._detect_worker = DetectWorker(self.input_path, start_offset=start_offset, max_results=max_results)
|
||||
@@ -368,6 +375,7 @@ class MainWindow(QMainWindow):
|
||||
self.detect_all_action.setEnabled(True)
|
||||
self.detect_all_button.setEnabled(True)
|
||||
self.detect_next_action.setEnabled(True)
|
||||
self.detect_next_button.setEnabled(True)
|
||||
|
||||
existing = set(self.source_panel.marker_strip.markers())
|
||||
existing.update(e.time_sec for e in events)
|
||||
@@ -386,6 +394,7 @@ class MainWindow(QMainWindow):
|
||||
self.detect_all_action.setEnabled(True)
|
||||
self.detect_all_button.setEnabled(True)
|
||||
self.detect_next_action.setEnabled(True)
|
||||
self.detect_next_button.setEnabled(True)
|
||||
self.statusBar().showMessage("Detection failed (see log).", 8000)
|
||||
self.log_view.appendPlainText(f"Clap detection FAILED: {message}")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user