Skip to content

ermalkaleci/CarbonTransition

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CarbonTransition

CarbonTransition v0.1

This version is unstable. Use at your own risk!

CarbonMaterialTransition

img

SAMPLE CODE

class YourViewController: UIViewController, UIViewControllerTransitioningDelegate {

    func animationControllerForPresentedController(presented: UIViewController, presentingController presenting: UIViewController, sourceController source: UIViewController) -> UIViewControllerAnimatedTransitioning? {
        return CarbonMaterialTransaction(fromPoint: startPoint)
    }

    func animationControllerForDismissedController(dismissed: UIViewController) -> UIViewControllerAnimatedTransitioning? {
        return CarbonMaterialTransaction().reverseToPoint(endPoint)
    }

    override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
        segue.destinationViewController.modalPresentationStyle = .Custom
        segue.destinationViewController.transitioningDelegate = self
    }

LICENSE

The MIT License (MIT)

About

iOS view controller transitions in Swift

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages