New Activity in Android “enter from the side”

后端 未结 5 912
谎友^
谎友^ 2020-12-12 19:24

What\'s the best way to go to a new activity but make it look like the activity slides to the left and the new activity enters the screen? I am using intents to call the new

5条回答
  •  悲哀的现实
    2020-12-12 20:13

    Jems is correct. By default, you will get a sliding animation when launching a new intent.

    If you are looking for a more custom animation, you can use overridePendingTransition. Keep in mind it was added in API Level 5. See this API demo for sample usage.

提交回复
热议问题