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 inability to change color after black color is set #269

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

XakerTwo
Copy link

In codehere is check for NULL(0) of COLORREF, but it CAN be 0 since it's an A,R,G,B components, packed into Int32

So to fix issue, this check was simply removed
Additionally check for value change was added to prevent useless updates when nothing was actually changed

when selected color is black next attempt to change it would be rejected
zero is valid for CHOOSECOLOR because COLORREF is A,R,G,B, packed into Int32
additionally skip value updating if it's actually not changed
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.

1 participant