feat: add utility functions with tests

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-06 11:14:01 +02:00
parent a3e2cb4d3b
commit 5819ea2970
2 changed files with 34 additions and 0 deletions
+12
View File
@@ -1,7 +1,19 @@
import os
import sys
from PyQt6.QtWidgets import QApplication, QMainWindow
def build_export_path(folder: str, basename: str, counter: int) -> str:
filename = f"{basename}_{counter:03d}.mp4"
return os.path.join(folder, filename)
def format_time(seconds: float) -> str:
m = int(seconds) // 60
s = seconds - m * 60
return f"{m}:{s:04.1f}"
def main():
app = QApplication(sys.argv)
win = MainWindow()