Saturday, 5 August 2017

Splash Screen creation

                      class 1                                   class name:     SplashActivity



public class SplashScreen extends AppCompatActivity {
    // Splash screen timer
    private static int SPLASH_TIME_OUT = 3000;
    @Override
  protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_splash);
        new Handler().postDelayed(new Runnable() {
  @Override
            public void run() {
               
    Intent i = new Intent(SplashScreen.this, MainActivity.class);
               
 startActivity(i);
          // close this activity
             finish();
            }
        }, SPLASH_TIME_OUT);
    }
}

No comments:

Post a Comment

HOW TO CREATE CIRCLE IMAGE VIEW

Step 1: implementation 'de.hdodenhof:circleimageview:3.0.0' Step 2: <de.hdodenhof.circleimageview.CircleImageView xmlns:ap...