Domanda

I'm trying to call an ibaction method when an NSButton is clicked down, but I can't figure out how to get do to that instead of having it called when clicked up.

È stato utile?

Soluzione

[yourButton sendActionOn:NSLeftMouseDownMask];

Altri suggerimenti

[btn setAction:@selector(Method:)];

[btn setTarget:objectThatRespondsToMethod];
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top