Hi all!
I have this problem, in my layer I inserted 2 MenuItemImage with her own method on touched and the code works fine...
if I touch somewhere my screen, the application runs the code into ccTouchesEnded method... and also this works fine...
my problem is this.. how can I avoid to run the code into ccTouchesEnded if the touch touched a menuitem??
thanks in advance! ghiboz
Avoid the touches if a menuitem is touched
(5 posts) (5 voices)-
Posted 2 years ago #
-
Hum, you can test where the touch occur ? If its occur in the area of the images, you don't run the code...
Not very pretty but should workPosted 2 years ago # -
Same problem here
And another one: if you set menu.visible = NO it could still be touched
Posted 2 years ago # -
Isn't there a way to make the menu's swallow the touches if an item was initially clicked?
Posted 2 years ago # -
Any answer to this? I have the same type of problem. I have a "popup" box that I want the user to interact with - below it are a couple of menuItemImages. I don't want those buttons messed with while the user is interacting with this new object that is in the same layer, but a higher Z order. I suppose I can disable the menu items before popping up the box, but I'd like something cleaner if possible. Thanks.
~billy
Posted 2 years ago #
Reply
You must log in to post.