0

I am developing an iPad app which presents to the user a set of zoomable pages. There is a (paged) UIScrollView used for scrolling between pages, and each page consists of another UIScrollView which allows pinch&zoom, and contains as subview the actual page content which is a custom UIView subclass with CALayer drawings.

Everything was working fine as of iOS 7.0.x. Unfortunately, when running the app on iPads updated to iOS 7.1, the pages'UIView is completely unresponsive to touch events: none of the UIGestureRecognizers attached to it is ever fired, touchesBegan/Moved/Ended methods are never called, and even pinch gestures that should be captured by the parent ScrollView are not recognized anymore if they happen inside the UIView's bounds (outside of it, they work).

When i set to NO the parent Scrollviews' scrollEnabled property, the touch events properly reach the UIView but of course this is not the behavior I need.

Apple documentation doesn't say anything about changes in UIKit framework, and I also have no clue on how to debug this, since on previous iOS releases everything was working as expected.

Any idea?

Edit 31/03/2014:

I was able to do some more debug, and noted that if I omit to add to the UIView's CALayer a couple of sublayers (that come from two custom subclasses of UIView), the problem doesn't occur.

1 Answer 1

2

I ended up solving my issue.

What I did was to stop adding the CALayers as sub-layers to the UIVIew, and instead adding the CALayers' parent views as sub-views to the main UIView.

I still have no idea on why this is happening in 7.1, given that no changes from 7.0 was mentioned in the documentation for this topic.

Anyhow, hope this can help...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.