Repository navigation
Fix dead device clicks in the default-device selector - #25
Closed
duketopceo wants to merge 1 commit into
Closed
duketopceo wants to merge 1 commit into
duketopceo wants to merge 1 commit into
Conversation
setDefaultDevice() silently returned false whenever the *current* default could not be resolved to a backend identity — a routine state after device churn (dock replug, USB audio flap, BT reconnect, suspend/resume) — leaving every row visually enabled but dead until something else changed the default. The backend recomputes the previous default from routing state on its own, so pass previous:null instead of aborting. Also: - Surface every early-return as the direction's error text so a dead click reports *why* instead of no-opping. - Narrow row disabling to an actual in-flight default.set or scene apply; the backend 'busy' flag flaps during unrelated PipeWire churn and left rows unclickable for long stretches.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
setDefaultDevice()silently returnedfalsewhenever the current defaultcould not be resolved to a backend identity — a routine state after device
churn (dock replug, USB audio flap, Bluetooth reconnect, suspend/resume).
The rows stayed visually enabled and the pointer still showed, but every
click was a no-op until something else changed the default. The backend
already recomputes the previous default from routing state when it isn't
supplied, so the panel now passes
previous: nullinstead of aborting.click reports why instead of no-opping.
default.setor scene apply;the backend
busyflag flaps during unrelated PipeWire churn and leftrows unclickable for stretches at a time.
Test plan
default.setwithprevious: null→{"outcome":"applied"}againsta live backend (aarch64)
from the graph
Generated with Devin