iOS 7 Weather app expand/collapse transition

前端 未结 3 542
执念已碎
执念已碎 2020-12-11 14:10

I\'m trying to achieve a view transition like the new iOS7 weather app transition, using a collapsing/expanding view.

Does anyone know if a lib already exist for tha

3条回答
  •  抹茶落季
    2020-12-11 14:42

    EDIT

    Check out this project. It demonstrates how to do the first part of the Weather app's transition using normal View Controllers and the transitioning API.


    I know this is a little late for a follow up, but I've looked for a library to do this, as well, but haven't found one.

    https://github.com/chefnobody/Colors

    I was able to do this using the new UIViewController Transitioning API. This example should get you started:

    http://www.teehanlax.com/blog/custom-uiviewcontroller-transitions/

    To augment this example to get the pinch/pull table view cell separation animation you would need to identify the table view cell that was selected (or "selected" relative to the pinch gesture"), then in -animateTransition: you would animate the cells above and below the selected cell out of view, revealing your details view controller.

提交回复
热议问题