3 Commits
Author SHA1 Message Date
ThePendulum 105dd5be88 LosslessCut-style layout: File menu, timeline above transport, centered controls, right-click play/pause
- Load File moved from a button into a new File menu.
- Timeline now sits directly under the video; the transport row
  (frame-step/play/frame-step, centered as a group; mute pinned right)
  moved below it, matching LosslessCut's layout instead of the previous
  buttons-then-timeline order.
- Right-click on the video toggles play/pause.

The right-click implementation took two tries, worth recording: mpv
embeds via wid as its own native child window, which receives raw X11
input directly -- a real mouse click never reaches this QWidget's
mousePressEvent at all, even though a unit-style test that called the
handler directly passed and looked fine. Caught this by testing with
an actual xdotool click against a live running window instead of
trusting the synthetic test, which is what this project's smoke tests
have been doing throughout and what caught the bug here too. Fixed by
binding MBTN_RIGHT through mpv's own on_key_press input API instead,
which does receive the real clicks -- verified the same way, with a
real click on a live window, position/button-text actually changing.

Also fixed a genuinely flaky smoke test in the process: QShortcut's
active-window check races with real desktop window-manager focus,
especially with another instance of this same app already open
elsewhere (happened during this session). Switched that test to set
Qt's active-window state directly rather than relying on WM-level
activation, and independently confirmed the real key bindings with
live xdotool keypresses (both directions, plus end-of-file clamping).
2026-07-26 02:19:54 +02:00
ThePendulum 5a6c4e6e84 UI/UX polish: Tools menu, clickable timeline, live drag-seek, drag-and-drop load
- Clap detection moved from inline buttons to a Tools menu, plain labels
  (no more '(whole file)' / '(from cursor)' parentheticals) -- status
  messages moved to the window's status bar since the dedicated label
  widget went away with the button row.
- ClickableSlider subclass: clicking anywhere along the seek track jumps
  straight there instead of QSlider's default page-by-a-step behavior;
  reposition-then-delegate-to-super keeps native drag behavior intact.
- Dragging now seeks live via sliderMoved instead of waiting for
  sliderReleased.
- PlayerWidget accepts drag-and-drop of a local file to load it.

Verified with real Qt events (QMouseEvent clicks, a QDropEvent, a real
mouse click via xdotool opening the Tools menu on an actual running
window) rather than just calling the underlying methods directly.
2026-07-26 01:55:32 +02:00
ThePendulum 91390f751d Validate frame-accurate seeking with python-mpv (build order step 1)
Confirms single-frame stepping is reliable: monotonic frame counter
across steps, and the synthetic clip's 1-frame flash event lands on
exactly one frame with clean neighbors. Also documents/works around
three environment quirks hit along the way: locally-built libmpv not
in ldconfig's cache, QApplication resetting LC_NUMERIC and breaking
libmpv's locale requirement, and the playback-restart event not firing
reliably after frame-step (switched to polling estimated_frame_number).
2026-07-26 00:37:42 +02:00