summaryrefslogtreecommitdiff
path: root/src/com/macaroon/piztor/InitAct.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/macaroon/piztor/InitAct.java')
-rw-r--r--src/com/macaroon/piztor/InitAct.java34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/com/macaroon/piztor/InitAct.java b/src/com/macaroon/piztor/InitAct.java
new file mode 100644
index 0000000..d5a6059
--- /dev/null
+++ b/src/com/macaroon/piztor/InitAct.java
@@ -0,0 +1,34 @@
+package com.macaroon.piztor;
+
+import android.content.Intent;
+import android.os.Bundle;
+import android.os.Handler;
+import android.view.Menu;
+
+public class InitAct extends PiztorAct {
+
+ @Override
+ protected void onCreate(Bundle savedInstanceState) {
+ id = "initAct";
+ super.onCreate(savedInstanceState);
+ AppMgr.init();
+ setContentView(R.layout.activity_init);
+ }
+
+ @Override
+ protected void onStart() {
+ super.onStart();
+ if (UserInfo.token == -1)
+ AppMgr.trigger(AppMgr.noToken);
+ else {
+ //TODO jump to main
+ }
+ }
+
+ @Override
+ public boolean onCreateOptionsMenu(Menu menu) {
+ getMenuInflater().inflate(R.menu.init, menu);
+ return true;
+ }
+
+}