Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use cosmic-settings-subscriptions for some iced subscriptions #492

Merged
merged 10 commits into from
Jul 2, 2024

Conversation

ids1024
Copy link
Member

@ids1024 ids1024 commented Jun 13, 2024

cosmic-applets and cosmic-osd both have some iced subscription code that could be useful in the other, so a library to share this makes sense.

Also we should avoid duplicating dbus bindings that are present in dbus-settings-bindings. (Currently cosmic-settings-subscriptions is using a branch of dbus-settings-bindings, pending pop-os/dbus-settings-bindings#15.)

This should help to address several open issues in cosmic-applets and cosmic-osd.

@ids1024
Copy link
Member Author

ids1024 commented Jun 14, 2024

With pop-os/cosmic-settings-subscriptions@29b8d3f, changing the keyboard backlight with keybindings now is reflected in the applet while the applet is open. Though looks like that will need more fixes here to make sure it behaves cleanly when changing the keyboard backlight with the slider in the applet.

That isn't hugely important, but is generally good, and something the OSD will need.

@ids1024 ids1024 force-pushed the cosmic-settings-subscriptions branch from 6228b8f to e132917 Compare June 25, 2024 01:38
These should be useful in `cosmic-osd` as well.
There's no need to deviate from a functional pattern here.
Fixes #301.

Should be combined with the subscription code here to avoid duplication,
and two things using pulse.
This shares a subscription with cosmic-osd, avoiding some duplication.
It's also important that things like selection of the display brightness
device are done consistency, and handling this in cosmic-settings-daemon
is one way to ensure consistency.
Being able to define sliders this way seems like an advantage of using a
seperate `brightness`/`max_brightness` instead of a float.

Now the `step` of the slider is a single unit as supported by the
display.
@ids1024 ids1024 marked this pull request as ready for review July 2, 2024 02:05
@ids1024 ids1024 requested a review from a team July 2, 2024 02:06
@ids1024
Copy link
Member Author

ids1024 commented Jul 2, 2024

This and pop-os/cosmic-osd#44 should now be good to improve various issues, avoid duplication, and ensure consistency between applets and OSDs.

Some things could be refactored a bit still, but that can be done later.

@ids1024 ids1024 merged commit a0145bf into master Jul 2, 2024
10 checks passed
@ids1024 ids1024 deleted the cosmic-settings-subscriptions branch July 2, 2024 03:07
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.

2 participants