views:

16

answers:

1

Hey all!

I have a UIView subclass where hitTest: withEvent: is overridden. Every time a hit test registers, the view logs its tag.

Ex: Click

Console: You Touched View: 3 You Touched View: 3 You Touched View: 3

My question: Why does it do it three times? I need it to trigger something other than an NSLog and I'm afraid that it will trigger that three times also. I could easily work around the triple trigger, but I was wondering if there was a better explanation.

A: 

I suggest you log the event information as well as the uiview's tag. It could be getting called by multiple events - touchDown, touchUp, etc.

Sam Dufel