Skip to content

Conversation

@TheVoidBlock
Copy link

This pull request fixes a bug that causes the small checkbox component to not toggle when you click on it. Upon clicking the checkbox, the code checks if you left clicked with click.isLeft(). Since Click extends AbstractInput, AbstractInput.isLeft() checks if this.getKeycode() == 263. Clicks implementation of getKeycode() returns this.button(), which will be 0 if the user left-clicked, NOT 263. To fix this, I simply check if click.button() == 0.

@TheVoidBlock
Copy link
Author

Closes #444

@Noaaan
Copy link
Member

Noaaan commented Dec 2, 2025

Does this really fix this issue? The Click class is vanilla code. To me this seems more like a patch for the symptom and not the problem, which is the fact that the click event doesn't return the correct number

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