locker: watch xkb_config for live layout updates and show active layout label#439
Open
utrumo wants to merge 1 commit intopop-os:masterfrom
Open
locker: watch xkb_config for live layout updates and show active layout label#439utrumo wants to merge 1 commit intopop-os:masterfrom
utrumo wants to merge 1 commit intopop-os:masterfrom
Conversation
- Subscribe to cosmic_config changes for com.system76.CosmicComp so active_layouts is refreshed whenever xkb_config changes at runtime (previously the locker cached active_layouts at startup and never updated, leaving the dropdown checkmark pointing at a stale layout). - Extract refresh_active_layouts() from update_user_data() and reuse it from the new XkbConfigChanged handler. - Show the active layout code (EN/RU/...) next to the keyboard icon on the lock screen so users don't have to open the dropdown to see which layout is currently active.
Open
8 tasks
Member
|
The PR template is mandatory |
Author
|
@jackpot51, I fixed the PR description |
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
com.system76.CosmicCompconfig changes so the lockerrefreshes
active_layoutswheneverxkb_configis modified at runtime(e.g. by
Super+Spacein the unlocked session). Previously the lockercached layouts at startup and never updated, leaving the dropdown
checkmark pointing at a stale layout after any switch.
the lock screen so users can see which layout is active without opening
the dropdown.
Test plan
Super+Spacein unlocked sessionSuper+Escorloginctl lock-session) — verifythe dropdown checkmark matches the actually active layout (type a
character to confirm)
xkb_config.layout— only the icon renders, no crash