Skip to content

Comments

Fix --custom-progress to register 0 as a valid input#182

Merged
ErikReider merged 1 commit intoErikReider:mainfrom
justssd:fix-custom-progress
Nov 21, 2025
Merged

Fix --custom-progress to register 0 as a valid input#182
ErikReider merged 1 commit intoErikReider:mainfrom
justssd:fix-custom-progress

Conversation

@justssd
Copy link
Contributor

@justssd justssd commented Nov 12, 2025

--custom-progress seems to ignore argument when value is 0 or 0.0. Running swayosd-client --custom-progress=0 would exit with error message No args provided....

I suspect it has something to do with how GLib handles 0 as an argument value when the argument type is Double.
Instead used String and validated the value inside handle_application_args, consistent with how the other numeric arguments are parsed.

New to Rust, sorry if I overlooked something obvious.

Copy link
Owner

@ErikReider ErikReider left a comment

Choose a reason for hiding this comment

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

Thanks! :D

@ErikReider ErikReider merged commit c029d5f into ErikReider:main Nov 21, 2025
2 checks passed
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