Skip to content

Add QR code login, recording bitrate control, and settings updates to main - #524

Merged
Kief5555 merged 18 commits into
mainfrom
dev
Jun 27, 2026
Merged

Add QR code login, recording bitrate control, and settings updates to main#524
Kief5555 merged 18 commits into
mainfrom
dev

Conversation

@Kief5555

@Kief5555 Kief5555 commented Jun 27, 2026

Copy link
Copy Markdown
Collaborator

This pull request introduces several improvements and new features across the OpenNOW codebase, focusing on native streamer shortcut support, enhanced persistent storage and video settings UI, and build system modernization. The most important changes are grouped below.


Native Streamer Shortcut Support

  • Added a new update_shortcuts method to the NativeStreamerBackend trait and implemented it for both the stub and GStreamer backends, enabling dynamic updating of native shortcut bindings. (native/opennow-streamer/src/backend.rs, native/opennow-streamer/src/gstreamer_backend.rs) [1] [2] [3] [4] [5]
  • Integrated shortcut event handling into the input pipeline, forwarding shortcut actions immediately and ensuring they are processed outside the main input readiness flow. (native/opennow-streamer/src/gstreamer_input.rs) [1] [2] [3] [4] [5] [6] [7] [8]
  • Updated test context creation to include default shortcut bindings. (native/opennow-streamer/src/backend.rs) [1] [2]

UI and Localization Enhancements

  • Added new persistent storage UI strings, including usage, location, and reset messages, to support a more comprehensive persistent storage management interface. (locales/en.json)
  • Introduced QR code login UI strings to enable sign-in via QR code. (locales/en.json)
  • Expanded video settings with new options and hints, such as recording bitrate controls and Linux hardware acceleration guidance. (locales/en.json) [1] [2]
  • Added new contributor and sponsor role labels for the community section. (locales/en.json)
  • Added an "Account" section label for settings navigation. (locales/en.json)

Build System Modernization

  • Updated the GitHub Actions workflow to use Bun instead of npm for dependency installation, improving install speed and reliability. (.github/workflows/auto-build.yml)

Platform and Rendering Improvements

  • Ensured that the external renderer window surface is updated when using an external renderer, improving rendering consistency. (native/opennow-streamer/src/gstreamer_pipeline.rs, native/opennow-streamer/src/gstreamer_platform.rs) [1] [2] [3]
  • Modified the external renderer window guard to run until explicitly stopped, increasing reliability. (native/opennow-streamer/src/gstreamer_platform.rs)

Documentation

  • Added a reference in the README to the OpenNOW-Mac repository for macOS users seeking a more performant version. (README.md)

Summary by CodeRabbit

  • New Features
    • Added QR-based sign-in, device-login flow, and new shortcut controls for streaming.
    • Introduced persistent storage management in Settings, including location lookup and reset.
    • Added a recording bitrate setting and improved video acceleration options.
    • Enhanced controller/home/library screens with smoother animations and navigation.
  • Bug Fixes
    • Improved shortcut handling, pointer-lock behavior, and keyboard input reliability.
    • Better support for Linux-specific updater and codec diagnostics.
  • Documentation
    • Updated README notes for macOS users.

Jayian1890 and others added 15 commits June 1, 2026 13:56
* Add QR code login with device authorization flow

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Fix QR login cancellation race

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Address QR login review findings

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Fix QR login cleanup edge cases

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Match QR login panel colors

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

---------

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
* Add native streamer app shortcut integration

* fix codex review stuff

* fix review stuff

* further review fix

* Fix native streamer shortcut capture

Made by codex

* fix

* Fix native shortcut review feedback

Made by codex

---------

Co-authored-by: Kiefer <67562560+Kief5555@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
… German layouts (#502)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: OpenClaw <230910855+capy-ai[bot]@users.noreply.github.com>
* Fix controller mode button mapping by centralizing gamepad input handling

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Handle controller menu button alias

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

---------

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: OpenClaw <230910855+capy-ai[bot]@users.noreply.github.com>
…uppression for intentional lock (#509)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
* Fix native streamer fullscreen monitor placement

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Recompute native renderer target rect from HWND

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Upgrade Electron to 42.3.3 and remove npm lockfile.

The project uses bun.lock; drop the stale package-lock.json and refresh bun.lock for the Electron 42 dependency bump.

Co-authored-by: Cursor <cursoragent@cursor.com>

---------

Co-authored-by: OpenClaw <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: Zortos <zortosdev@proton.me>
Co-authored-by: zortos293 <65777760+zortos293@users.noreply.github.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
* Modernize settings modal UX and fix Electron dev install in worktrees.

Convert settings to a dismissible overlay with grouped navigation, tighter styling, scrollable content, and streamlined stream options that infer aspect ratio from resolution while moving decoder/encoder controls into Advanced. Add ensure-electron postinstall so Electron binaries download reliably when npm install scripts are blocked.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Remove Electron install tooling from settings modal PR

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Use Bun install in CI

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
* Implement active-session fallback using serverInfo region discovery.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

* Fix active-session fallback on HTTP errors

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

---------

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
@capy-ai

capy-ai Bot commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

Capy auto-review is paused for this organization because the usage-cycle auto-review limit has been reached. Increase the limit or turn it off in billing settings to resume automatic reviews.

@coderabbitai

coderabbitai Bot commented Jun 27, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Walkthrough

This PR adds native keyboard shortcut support end-to-end (Rust Win32 matcher + JS IPC bus), QR/device-code login for Steam Deck clients, persistent cloud storage management in Settings, a video acceleration command-line builder, Linux updater detection, configurable recording bitrate, controller gamepad search overlays with Motion animations, CloudMatch regional fallback discovery, and CI Bun migration.

Changes

Native Shortcuts, QR Login, Persistent Storage, Video Acceleration, Controller Search

Layer / File(s) Summary
Shared protocol and type contracts
native/opennow-streamer/src/protocol.rs, opennow-stable/src/shared/gfn.ts, opennow-stable/src/shared/ipc.ts, opennow-stable/src/shared/nativeStreamer.ts
Protocol version bumped to 3; adds NativeStreamerShortcutBindings/Action, device-login request/result types, persistent storage types, AuthTokens.authClientId, recordingBitrateMbps, ThankYouSupporter.source, and native-shortcut signaling event.
Native shortcut engine (Rust/Windows)
native/opennow-streamer/src/shortcuts.rs, native/opennow-streamer/src/gstreamer_platform.rs, native/opennow-streamer/src/gstreamer_backend.rs, native/opennow-streamer/src/gstreamer_input.rs, native/opennow-streamer/src/gstreamer_pipeline.rs, native/opennow-streamer/src/input.rs, native/opennow-streamer/src/backend.rs, native/opennow-streamer/src/main.rs
Implements NativeShortcutMatcher with VK/scancode/modifier parsing. Win32 platform layer adds key-suppression state, legacy shortcut handler, RenderTargetSurface, ClientToScreen conversion, and RIDEV_NOLEGACY. Wires shortcut bindings into backend session lifecycle and forwards Shortcut events through input pipeline bypassing the ready gate.
Shortcut JS/IPC wiring and Escape suppression
opennow-stable/src/renderer/src/streamShortcutActions.ts, opennow-stable/src/main/nativeStreamer/manager.ts, opennow-stable/src/main/signaling/signalingCoordinator.ts, opennow-stable/src/renderer/src/gfn/webrtcClient.ts, opennow-stable/src/renderer/src/App.tsx, opennow-stable/src/renderer/src/components/StreamView.tsx, opennow-stable/src/preload/index.ts, opennow-stable/src/shared/gfn.test.ts
Adds streamShortcutActions.ts window-event bus; NativeStreamerManager.updateShortcuts; NATIVE_UPDATE_SHORTCUTS IPC listener; timer-based suppressNextSyntheticEscapeOnPointerLockLoss; handleStreamShortcutAction in App; shortcut listener effect in StreamView.
QR/device login flow
opennow-stable/src/main/gfn/auth.ts, opennow-stable/src/main/ipc/accountCatalogHandlers.ts, opennow-stable/src/renderer/src/App.tsx, opennow-stable/src/renderer/src/components/LoginScreen.tsx, opennow-stable/src/preload/index.ts, locales/en.json, opennow-stable/src/renderer/src/styles.css
Adds Steam Deck client constants, buildAuthHeadersForClient, device authorization/exchange in AuthService; device-login IPC handlers; QR polling loop and cancel in App; LoginScreen QR panel with qrcode.toDataURL; localization and CSS.
Persistent cloud storage management
opennow-stable/src/main/gfn/persistentStorage.ts, opennow-stable/src/main/ipc/accountCatalogHandlers.ts, opennow-stable/src/renderer/src/components/SettingsPage.tsx, opennow-stable/src/preload/index.ts, locales/en.json, opennow-stable/src/renderer/src/styles.css
Adds fetchPersistentStorageLocations/resetPersistentStorage with paywall + Statuspage fallback; IPC handlers with sessionTokenCandidates/vpcId resolution; SettingsPage Account section UI and loadSubscriptionData flow; storage CSS.
Video acceleration, Linux updater, and recording bitrate
opennow-stable/src/main/videoAcceleration.ts, opennow-stable/src/main/videoAcceleration.test.ts, opennow-stable/src/main/index.ts, opennow-stable/src/main/linuxUpdaterSupport.ts, opennow-stable/src/main/linuxUpdaterSupport.test.ts, opennow-stable/src/main/updater.ts, opennow-stable/src/main/settings.ts, opennow-stable/src/renderer/src/components/StreamView.tsx
Extracts buildVideoAccelerationCommandLine; adds getLinuxUpdaterSupport with AppImage/deb detection and disabled updater stub; adds recordingBitrateMbps setting with normalization/migration and videoBitsPerSecond wiring in StreamView.
CloudMatch regional fallback discovery
opennow-stable/src/main/gfn/cloudmatch.ts, opennow-stable/src/main/gfn/cloudmatch.test.ts
Adds extractServerInfoRegionBases; refactors getActiveSessions to retry across discovered fallback region bases with structured error logging; adds two new test cases.
Controller gamepad utils, search overlays, and animated transitions
opennow-stable/src/renderer/src/utils/controllerGamepad.ts, opennow-stable/src/renderer/src/utils/controllerGamepad.test.ts, opennow-stable/src/renderer/src/components/HomePage.tsx, opennow-stable/src/renderer/src/components/LibraryPage.tsx, opennow-stable/src/renderer/src/components/MotionProvider.tsx, opennow-stable/src/renderer/src/main.tsx, opennow-stable/src/renderer/src/App.tsx, opennow-stable/src/renderer/src/styles.css
Adds controllerButton bitmask and readControllerGamepadButtons; animated search overlays in HomePage/LibraryPage; Framer Motion AnimatePresence/m.* for hero/grid/overlays; MotionProvider wrapping app root; page transition state and navigation helpers in App.
Settings UI overhaul, codec diagnostics, Thanks sponsors, and CSS
opennow-stable/src/renderer/src/components/SettingsPage.tsx, opennow-stable/src/renderer/src/lib/codecDiagnostics.ts, opennow-stable/src/renderer/src/lib/codecDiagnostics.test.ts, opennow-stable/src/main/index.ts, locales/en.json, opennow-stable/src/renderer/src/styles.css
Adds grouped sidebar nav, onClose, resolution-inferred aspect ratio, recording bitrate chip, Linux codec hint (shouldShowLinuxHardwareCodecHint), sponsor source labels, THANKS_CUSTOM_SUPPORTERS merge; portal-based overlay; full settings modal/nav/region/toggle/storage CSS overhaul.

CI Cache Update

Layer / File(s) Summary
CI Bun switch, Electron install script, and dependency updates
.github/workflows/auto-build.yml, opennow-stable/package.json, opennow-stable/scripts/ensure-electron-installed.mjs, README.md
Replaces npm ci with bun install --frozen-lockfile; adds ensure-electron-installed.mjs with installer + archive fallback; bumps Electron to ^42.3.3; adds qrcode/motion dependencies; adds README macOS note.

Sequence Diagram(s)

sequenceDiagram
  participant App as App.tsx
  participant AuthService as AuthService
  participant NVIDIA as NVIDIA Device Auth
  participant LoginScreen as LoginScreen

  App->>AuthService: startDeviceLogin()
  AuthService->>NVIDIA: POST /oauth2/device/authorize
  NVIDIA-->>AuthService: device_code + verification_uri_complete
  AuthService-->>App: AuthDeviceLoginChallenge { attemptId, userCode, verificationUri }
  App->>LoginScreen: qrLoginChallenge → QRCode.toDataURL()
  LoginScreen-->>App: QR image displayed
  loop poll
    App->>AuthService: pollDeviceLogin(attemptId)
    AuthService->>NVIDIA: POST /oauth2/token (device_code grant)
    NVIDIA-->>AuthService: pending | authorized | expired
  end
  App->>AuthService: completeDeviceLogin(attemptId)
  AuthService->>AuthService: saveLoginSession + pruneExpiredDeviceLogins
  AuthService-->>App: AuthSession
Loading
sequenceDiagram
  participant WndProc as Win32 WndProc
  participant NativeShortcutMatcher as NativeShortcutMatcher
  participant gstreamer_input as gstreamer_input
  participant NativeStreamerManager as NativeStreamerManager
  participant App as App.tsx
  participant GfnWebRtcClient as GfnWebRtcClient

  WndProc->>NativeShortcutMatcher: match_keydown(keycode, scancode, modifiers)
  NativeShortcutMatcher-->>WndProc: Some(NativeStreamerShortcutAction)
  WndProc->>WndProc: mark PressedKey.suppressed
  WndProc->>gstreamer_input: NativeWindowInputEvent::Shortcut { action }
  gstreamer_input->>NativeStreamerManager: Event::Shortcut { action }
  NativeStreamerManager->>App: emit native-shortcut { action }
  App->>App: handleStreamShortcutAction(action)
  App->>GfnWebRtcClient: suppressNextSyntheticEscapeOnPointerLockLoss()
Loading

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120 minutes

Possibly related issues

Possibly related PRs

  • OpenCloudGaming/OpenNOW#519: Directly overlaps with this PR at the code level, introducing the same native streamer update-shortcuts/shortcut protocol, session context shortcuts field, IPC plumbing, and related renderer wiring.

Poem

🐇 Hop hop, the rabbit taps F12 with glee,
A shortcut fires across the native stream!
QR codes bloom where passwords used to be,
Storage resets in a persistent dream.
With motion springs and controllers in hand,
This bunny leaps across a brighter land! ✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 11.31% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title captures key changes in QR login, recording bitrate, and settings, which are major parts of the PR.
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 docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dev

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

@Kief5555

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>

Copilot AI commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

I resolved the merge conflicts locally in commit 2b99ce4 (merged origin/main into dev, resolved styles.css, and finalized the merge). I’m currently blocked from pushing this commit because the dev branch is protected and rejects direct updates with Required status check "CodeQL" is expected.

@Kief5555

Copy link
Copy Markdown
Collaborator Author

Well, no, you didn't but ok..

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ec6ac9d0fc

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +110 to +112
const tarResult = spawnSync("tar", ["-xf", zipPath, "-C", resolvedDistRoot], {
stdio: "inherit",
shell: false,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Extract downloaded Electron zips without GNU tar

When the fallback path runs on Linux (for example after the Electron installer exits 0 but leaves no runtime binary), downloadArtifact returns Electron's .zip, but the Ubuntu runners use GNU tar and tar -xf does not extract zip archives (tar -tf on a zip reports “This does not look like a tar archive”). That makes the recovery path fail exactly in the Linux CI/dev environments it is meant to repair; use a zip-capable extractor here as is already done for Windows.

Useful? React with 👍 / 👎.

@zortos293

Copy link
Copy Markdown
Collaborator

@cursoragent fix issues

@cursor

cursor Bot commented Jun 27, 2026

Copy link
Copy Markdown

Fixed the Electron install fallback issue flagged in the PR review.

Problem

The archive fallback in ensure-electron-installed.mjs used tar -xf on Electron’s .zip downloads. GNU tar on Linux cannot extract zip archives, so the fallback failed on Linux CI when the primary installer didn’t leave a runtime binary.

Fix

Replaced the tar/PowerShell extraction logic with Electron’s bundled @electron-internal/extract-zip helper — the same extractor electron/install.js uses. This works cross-platform on Linux, macOS, and Windows.

Verification

  • node scripts/ensure-electron-installed.mjs — passes
  • npm --prefix opennow-stable run typecheck — passes
  • npm --prefix opennow-stable test — 96/96 pass

PR

dev is branch-protected, so the fix is on a separate branch: #525 (targets dev).

Once that merges, it will flow into the larger devmain PR (#524).

Open in Web Open in Cursor 

zortos293 and others added 2 commits June 27, 2026 21:44
…525)

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
# Conflicts:
#	opennow-stable/package-lock.json
#	opennow-stable/src/renderer/src/styles.css
@Kief5555
Kief5555 merged commit b977179 into main Jun 27, 2026
19 of 20 checks passed
@coderabbitai coderabbitai Bot mentioned this pull request Jun 29, 2026
Chizuui pushed a commit to Chizuui/OpenNOW-Modified that referenced this pull request Aug 11, 2026
Add QR code login, recording bitrate control, and settings updates to main
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants