jeudi 5 avril 2018

Allow mixed state but not on click

I have a checkbox (NSButton) that I set programmatically. This checkbox will be set to other on, off or mixed, but when the user clicks it I want it to only cycle between on and off.

Currently, when button.allowsMixedState = true when the user clicks on the checkbox it will cycle between all three states.

Is there a way to have button.allowsMixedState = true but only have the checkbox cycle between on and off when it's clicked?




Aucun commentaire:

Enregistrer un commentaire