Advertisement
Guest User

Untitled

a guest
Mar 19th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. import android.content.Intent;
  2. import android.os.Handler;
  3. import android.support.v7.app.AppCompatActivity;
  4. import android.os.Bundle;
  5. import android.widget.TextView;
  6.  
  7. public class SplashScreen extends AppCompatActivity {
  8.  
  9. @Override
  10. protected void onCreate(Bundle savedInstanceState) {
  11. super.onCreate(savedInstanceState);
  12. setContentView(R.layout.activity_splash_screen);
  13.  
  14. // Without Lambda
  15. new Handler().postDelayed(new Runnable() {
  16. @Override
  17. public void run() {
  18. startActivity(new Intent(SplashScreen.this, MainActivity.class)
  19. }
  20. }, 2000);
  21.  
  22. }
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement