iOS dev iOS dev - 3 months ago 47x
iOS Question

objective c how to set exclusive touch for all UIbuttons on the whole app

My app has many buttons through out the application

I want to set Exclusive Touch all of them together at one time. or all views in the app

we can set individually by

[button setExclusiveTouch:YES];

But i want to set at a time for all the buttons in the application

Can we set all view exclusive touch ?

any body have any idea please suggest me.


You can try this

// Not tested
for (UIView * button in [myView subviews]) {
    if([button isKindOfClass:[UIButton class]])
        [((UIButton *)button) setExclusiveTouch:YES];