mirror of
https://github.com/ClaytonWWilson/Listify.git
synced 2025-12-16 02:38:47 +00:00
Can now display splashscreen when first entering the app v.5
This commit is contained in:
parent
838db000af
commit
8512fbc3d4
@ -33,24 +33,17 @@ public class MainActivity extends AppCompatActivity implements CreateListDialogF
|
|||||||
|
|
||||||
public static AuthManager am = new AuthManager();
|
public static AuthManager am = new AuthManager();
|
||||||
|
|
||||||
boolean showSplash = true;
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
|
setContentView(R.layout.activity_splashscreen);
|
||||||
if(showSplash) {
|
try {
|
||||||
showSplash = false;
|
Thread.sleep(3000);
|
||||||
|
|
||||||
new Handler().postDelayed(new Runnable() {
|
|
||||||
@Override
|
|
||||||
public void run() {
|
|
||||||
Intent intent = new Intent(MainActivity.this, SplashActivity.class);
|
|
||||||
startActivity(intent);
|
|
||||||
finish();
|
|
||||||
}
|
|
||||||
}, 1);
|
|
||||||
}
|
}
|
||||||
|
catch (Exception e) {
|
||||||
|
Log.i("Authentication", e.toString());
|
||||||
|
}
|
||||||
|
setContentView(R.layout.activity_main);
|
||||||
|
|
||||||
|
|
||||||
//------------------------------Auth Testing---------------------------------------------//
|
//------------------------------Auth Testing---------------------------------------------//
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user