Skip to content
This repository was archived by the owner on Aug 30, 2023. It is now read-only.
This repository was archived by the owner on Aug 30, 2023. It is now read-only.

Add support for interactive transitioning #3

@jverkoey

Description

@jverkoey

This issue requires answering the following questions:

  1. How do we determine whether a transition is initially interactive

UIViewControllerTransitioningDelegate expects us to have an answer to this question.

  1. How should the Transition implementation communicate changes in interactivity state?

Notably, UIKit expects us to inform it when the transition stops and starts being interactive so that Core Animation can resume its animations.

It may be reasonable to expose the vanilla UIKit APIs to the transition object, but we should explore whether there are alternative representations of these APIs. E.g. if we can generally say "interactivity is a product of whether any gesture recognizer is currently active" then we can build a simple API that allows you to register gesture recognizers with the transition context and the transition context in turn informs UIKit when states change.

At minimal, the following must be done:

  • Implement isInteractive in MDMPresentationTransitionController.
  • Make MDMViewControllerTransitionContext conform to UIViewControllerInteractiveTransitioning and implement startInteractiveTransition.

We must then do one or both of:

  • Expose the interactivity state APIs to the transition.
  • Provide a higher order API that federates the interactivity state to the transition, e.g. something that observes a set of gesture recognizers.

Metadata

Metadata

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions