jibysthomas
jibysthomas

Reputation: 1621

Android Screen Animation


In my application i need one animation in which the exit animation is from sliding the screen from top to bottom and the entring animation will be like hold, ie, the entering screen remind in its own position no animation required for it but when the previous page slide downs it must be in the under of the new screen.
thanks
jibysthomas

Upvotes: 2

Views: 1449

Answers (1)

Hardik Gajjar
Hardik Gajjar

Reputation: 5058

you can use the following

public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        getWindow().setBackgroundDrawableResource(R.drawable.mainbg_);
       // overridePendingTransition (R.anim.push_up_in,0);

        overridePendingTransition (R.anim.fade_out,R.anim.fade_in);
  • Its take two parameters as entertains animation and exit animation of existing activity and other coming activity.
  • if you not need to animation you can use the "0" as parameter
  • Its as oncreate time ..you can also put as after finish()calling for activity close time.

Upvotes: 1

Related Questions