Skip to content

feat(launch): auto-start recording once a source is selected - #790

Open
nmzpy wants to merge 1 commit into
webadderallorg:mainfrom
nmzpy:feat/auto-start-record-after-source-select
Open

feat(launch): auto-start recording once a source is selected#790
nmzpy wants to merge 1 commit into
webadderallorg:mainfrom
nmzpy:feat/auto-start-record-after-source-select

Conversation

@nmzpy

@nmzpy nmzpy commented Aug 3, 2026

Copy link
Copy Markdown

Summary

Tightens the very first recording flow: when the user's first click is on the Record button but they haven't chosen a source yet, that click opens the source picker. After the user picks a source, the recording now starts immediately — they no longer have to click Record a second time.

Motivation (UX)

If the user's intent is already sitting on the Record button, the selection of a window/screen should finish the "start recording" action instead of forcing a redundant second click. This removes a source of confusion where the first click appears to "do nothing" (it only opened the picker).

How it works

  • The Record button (idle, no source chosen, non-Linux) opens the source popover and arms a one-shot pendingAutoStartRef.
  • Once a source is selected successfully, handleSourceSelect runs first (persisting the selection via selectSource, as before), then toggleRecording() is fired to begin recording while the popover closes in the background.
  • The pending flag is disarmed whenever the popover closes without a selection (outside click, Esc, blur), so a later pick from the dropdown cannot unexpectedly start a recording.

Behavior preserved

  • Picking a source from the dropdown source button still only changes the selection (no auto-start).
  • The Linux portal flow is untouched.
  • The user's countdown preference is still honored, since auto-start routes through the existing toggleRecording path.
  • No changes to recording internals (useScreenRecorder, useLaunchWindowActions, SourcePopover); this is a single-file composition change in LaunchWindow.tsx.

Validation

  • npm test: 106 files, 1027 tests passed (1 pre-existing skip).
  • npx tsc --noEmit: clean.

Summary by CodeRabbit

  • New Features
    • Recording now starts automatically after selecting a source when recording was initiated without one.
    • The source picker opens automatically when no recording source is selected.
  • Bug Fixes
    • Pending recording requests are cleared when the source picker closes or recording begins.

When the user's first click is on the Record button but no source is
chosen yet, the click opens the source picker. After the user picks a
source, start the recording immediately instead of requiring a second
click on Record. The auto-start only applies to the flow initiated from
the Record button; picking a source from the dropdown still just changes
the selection (no recording), and the countdown preference is still
honored.
@coderabbitai

coderabbitai Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 37e4db48-c887-49f3-b192-7278c0f7a7c8

📥 Commits

Reviewing files that changed from the base of the PR and between 54ae801 and 8e08644.

📒 Files selected for processing (1)
  • src/components/launch/LaunchWindow.tsx

📝 Walkthrough

Walkthrough

LaunchWindow now defers recording when no source is selected. It opens the source picker, tracks the pending request, and starts recording after source selection. The pending request is cleared when the picker closes or recording starts.

Changes

Deferred recording start

Layer / File(s) Summary
Source selection and recording coordination
src/components/launch/LaunchWindow.tsx
LaunchWindow tracks pending recording requests, opens the source picker when no source is selected, starts recording after source selection, and clears stale pending state when the picker closes.

Estimated code review effort: 2 (Simple) | ~10 minutes

Sequence Diagram(s)

sequenceDiagram
  participant User
  participant LaunchWindow
  participant SourcePopover
  User->>LaunchWindow: Request recording without a source
  LaunchWindow->>SourcePopover: Open source picker
  User->>SourcePopover: Select source
  SourcePopover->>LaunchWindow: Return selected source
  LaunchWindow->>LaunchWindow: Start recording
Loading

Possibly related PRs

Suggested reviewers: extrabinoss, meiiie, webadderall

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the main change: recording starts automatically after source selection.
Description check ✅ Passed The description explains the change, motivation, behavior, preserved flows, implementation scope, and validation results.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added the Slop label Aug 3, 2026
@github-actions

github-actions Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

⚠️ This pull request has been flagged by Anti-Slop.
Our automated checks detected patterns commonly associated with
low-quality or automated/AI submissions (failure count reached).
No automatic closure — a maintainer will review it.
If this is legitimate work, please add more context, link issues, or ping us.

@nmzpy

nmzpy commented Aug 5, 2026

Copy link
Copy Markdown
Author

Any maintainer ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant