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

Fix RadioButtons double event emissions #189

Merged
merged 1 commit into from
Mar 23, 2021

Conversation

tlambert03
Copy link
Member

@tlambert03 tlambert03 commented Mar 21, 2021

fixes #188

This introduces a new problem, which is that if someone programmatically sets widget.value to None, then no event will be emitted (in the GUI, this isn't possible since once a radio button is checked it can't be unchecked). quick solutions to this are made slightly challenging by the fact that we don't know if a non-None value is about to be set in the near future. Anyway, that's probably less problematic than the current behavior, so we'll leave that fix for a later PR.

@tlambert03 tlambert03 changed the title fix radio events Fix RadioButtons double event emissions Mar 21, 2021
@codecov
Copy link

codecov bot commented Mar 21, 2021

Codecov Report

Merging #189 (965cbf4) into master (260f63e) will decrease coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #189      +/-   ##
==========================================
- Coverage   90.07%   90.07%   -0.01%     
==========================================
  Files          29       29              
  Lines        2982     2981       -1     
==========================================
- Hits         2686     2685       -1     
  Misses        296      296              
Impacted Files Coverage Δ
magicgui/backends/_qtpy/widgets.py 86.87% <100.00%> (-0.03%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 260f63e...965cbf4. Read the comment docs.

@jni jni merged commit f06e44a into pyapp-kit:master Mar 23, 2021
@tlambert03 tlambert03 added the bug Something isn't working label Apr 3, 2021
@tlambert03 tlambert03 deleted the fix-radio-events branch November 13, 2022 01:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Duplicate change events for RadioButtons widget
2 participants