- added developer preference to disable splash screen

- disable splash screen on login screen
This commit is contained in:
Philipp Schaefer
2013-07-24 00:49:21 +02:00
parent e2ab17fa81
commit f342aeab0a
7 changed files with 38 additions and 8 deletions

View File

@ -464,8 +464,7 @@ public class IITC_Mobile extends Activity {
// inject the iitc-script and load the intel url
// plugins are injected onPageFinished
public void loadUrl(String url) {
findViewById(R.id.imageLoading).setVisibility(View.VISIBLE);
findViewById(R.id.iitc_webview).setVisibility(View.GONE);
showSplashScreen();
url = addUrlParam(url);
loadIITC();
iitc_view.loadUrl(url);
@ -483,8 +482,6 @@ public class IITC_Mobile extends Activity {
}
public void toggleFullscreen() {
// TODO: Figure out how to handle this with new back stack?
if (fullscreen_mode) {
if (fullscreen_actionbar)
this.getActionBar().show();
@ -546,6 +543,7 @@ public class IITC_Mobile extends Activity {
public void loginSucceeded() {
// garbage collection
mLogin = null;
showSplashScreen();
}
// disable/enable some menu buttons...
@ -578,4 +576,11 @@ public class IITC_Mobile extends Activity {
dialogStack.remove(id);
}
}
public void showSplashScreen() {
if (!sharedPref.getBoolean("pref_disable_splash", false)) {
findViewById(R.id.iitc_webview).setVisibility(View.GONE);
findViewById(R.id.imageLoading).setVisibility(View.VISIBLE);
}
}
}