objective c - How to make a uibutton with touch down action and touch up inside action -
i need make 1 button 2 actions, touch down used play sound , touch inside stop playing sound when let go of button
connect 2 methods both these actions.
[self.yourbtn addtarget:self action:@selector(touchdownmethod:) forcontrolevents:uicontroleventtouchdown]; [self.yourbtn addtarget:self action:@selector(touchupinsidemethod:) forcontrolevents:uicontroleventtouchupinside];
Comments
Post a Comment