Is there any way to have the back button have a different animation than Navigator.push? - flutter

Let's say I have a fade through transition going into another page, and then when I want to go back, it uses the same fade through transition but reversed.
How do I make it so that the animation is different upon the reversed animation?

Related

telegram scroll to load more animation

I make app that render list of objects
I want to make animation at the end of scroll like telegram
when scroll come to the end, the animation start to appear but not work, it only works when leave scroll, the animation will forward
Telegram animation

How to reverse SKTransition?

I have a button, that when pressed, moves to the next scene with the "doorway" transition. The doorway transition has no counterpart and opens differently when coming back. Is it possible for me to create a inverted doorway transition?

UIView animation

I have a UIView(first view) on top of which I would like to display another UIView(second view). I display the second view using animation which causes the second view to be displayed for about 3/4 of the iPhone screen. The first view is visible underneath the animated second view. I would like to make changes to the first view as the second view is displayed. Any ideas on how I can achieve this. Right now, the animation completes, the second view is displayed and then I can change the first view. I would like to change the layout of the first screen as the second screen is being displayed. Any help is much appreciated.
Basically, just do it.
You can start more than one animation at a time. If you are not animating the changes to the first view, then do them after calling commitAnimations or otherwise starting the animations on the second view. If you want to do them half way through the animation, set up a timer or delayed call.

How can I pause a currently running animation?

I have a Core Animation running and want to pause it when a button is pressed. So there is a method -pauseAnimation. When the animation is paused, I want the animated view to stay in the state as it currently was while animating. i.e. if a view moves from top left to bottom right, and somewhere in the middle the animation is paused, the view should stay in the middle.
Is there a way to do this?
as far as i can remember there is an setAnimationsEnabled=NO option, but that doesn't work when the animation runs, right?
You can pause layer animations by setting the speed of the animation to zero, see How to pause the animation of a layer tree.
You can do this by disabling animations and then setting the model layers' values to the presentation layers' values (for all properties that define your animation).
eg. layer.transform = layer.presentationLayer.transform;
Resuming the animation = re-enable animations and animate from current positions to the desired final positions (you might have to adjust curves, etc to get something acceptable).

How to get transition like Star Trek app?

I've modified the ViewTransitions app to use kCAScrollHorizontally. I've set transition in the app delegate to use kCATransitionPush rather than kCATransitionFade. However, I still get fading in and out. How can I get the views to slide in landscape just like the Star Trek app (http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=305916616&mt=8)?
I've done transitions like this before. Basically I have a big view that takes up the screen, with another view (the actual screen content) embedded within it. When I want to slide in a new page either from the left or right, I'll take the next page of content, place it offscreen, and embed it in the big backing view. Then I'll just animate (using a simple [UIView beginAnimations:context:] to change the frames of both pages simultaneously (really just changing the origins of the frames). The offscreen view slides to where the current view is, and the current view slides to an offscreen position. Once offscreen, I'll remove it from its superview. Works like a charm.
The simulator will still fade out rather than performing some complex transitions...
Did you try it on the device?