Skip to content

Create SettingsToggle widget#333

Merged
danirabbit merged 3 commits intomasterfrom
danirabbit/settings-toggle
Apr 25, 2025
Merged

Create SettingsToggle widget#333
danirabbit merged 3 commits intomasterfrom
danirabbit/settings-toggle

Conversation

@danirabbit
Copy link
Member

@danirabbit danirabbit commented Apr 23, 2025

Can be rebase merged

Creates a SettingsToggle widget like we did in Quick Settings. This should eventually be moved into Wingpanel, but kind of prototyping in indicators first to make sure it covers all the cases before proposing to the library. Couple things different here from the one in Quick Settings:

  • Not a FlowBoxChild. We're using FlowBox now, but we might want to use GridView later or a box or something else. Just future proofing ourselves
  • All properties are set and none construct. This is in case we want to create these widgets from a model like in GridView where we recycle widgets.
  • Use action-name instead of active. Avoids some jank. This is the recommended way to handle ToggleButtons in GTK and it means we can set disabled states more cleanly etc

@danirabbit danirabbit requested a review from a team April 23, 2025 22:14
Remove extra whitespace
@danirabbit danirabbit force-pushed the danirabbit/settings-toggle branch from 2a1e9c6 to 5bb4cff Compare April 24, 2025 18:34
@danirabbit danirabbit moved this to Needs Review in GTK4 Porting Apr 25, 2025
@danirabbit danirabbit merged commit 0b493a9 into master Apr 25, 2025
4 checks passed
@danirabbit danirabbit deleted the danirabbit/settings-toggle branch April 25, 2025 22:38
@github-project-automation github-project-automation bot moved this from Needs Review to Done in GTK4 Porting Apr 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants