/TheElements/src/sand/falling/opengl/Splash.java
Java | 42 lines | 35 code | 6 blank | 1 comment | 0 complexity | 15be4c1998d221f4351c4c1f89c61523 MD5 | raw file
1package sand.falling.opengl; 2 3import android.app.Activity; 4import android.content.Intent; 5import android.os.Bundle; 6import android.os.Handler; 7 8public class Splash extends Activity 9{ 10 @Override 11 protected void onCreate (Bundle savedInstanceState) 12 { 13 super.onCreate(savedInstanceState); //Call the super method 14 15 setContentView(R.layout.splash); 16 17 new Handler().postDelayed( 18 new Runnable() 19 { 20 @Override 21 public void run() 22 { 23 //Create an Intent to start DemoActivity 24 Intent mainIntent = new Intent(Splash.this, MainActivity.class); 25 Splash.this.startActivity(mainIntent); 26 Splash.this.finish(); 27 } 28 }, 5); 29 } 30 31 @Override 32 protected void onResume() 33 { 34 super.onResume(); 35 } 36 37 @Override 38 protected void onPause() 39 { 40 super.onPause(); 41 } 42}