Преглед на файлове

gradle update; fix null pointer; added volley init

develop
Robin Thoni преди 8 години
родител
ревизия
e573116b42

+ 4
- 0
app/src/main/java/com/rthoni/camotion/ui/AddAccountActivity.java Целия файл

@@ -12,6 +12,7 @@ import android.widget.CheckBox;
12 12
 import android.widget.EditText;
13 13
 import android.widget.Toast;
14 14
 
15
+import com.crashlytics.android.Crashlytics;
15 16
 import com.luticate.auth.dbo.LuLoginDbo;
16 17
 import com.luticate.utils.business.LuPromise;
17 18
 import com.luticate.utils.business.LuRequest;
@@ -21,6 +22,8 @@ import com.rthoni.camotion.ui.dialogs.LoginDialog;
21 22
 
22 23
 import org.json.JSONObject;
23 24
 
25
+import io.fabric.sdk.android.Fabric;
26
+
24 27
 public class AddAccountActivity extends AppCompatActivity {
25 28
 
26 29
     private EditText _nameInput;
@@ -34,6 +37,7 @@ public class AddAccountActivity extends AppCompatActivity {
34 37
     @Override
35 38
     protected void onCreate(Bundle savedInstanceState) {
36 39
         super.onCreate(savedInstanceState);
40
+        Fabric.with(this, new Crashlytics());
37 41
         LuRequest.init(this);
38 42
         setContentView(R.layout.activity_add_account);
39 43
         _nameInput = (EditText) findViewById(R.id.name_input);

+ 4
- 0
app/src/main/java/com/rthoni/camotion/ui/AddCommandShortcutActivity.java Целия файл

@@ -5,6 +5,7 @@ import android.content.Intent;
5 5
 import android.os.Bundle;
6 6
 import android.widget.Toast;
7 7
 
8
+import com.crashlytics.android.Crashlytics;
8 9
 import com.luticate.auth.dbo.LuFullLoginDbo;
9 10
 import com.luticate.utils.business.LuPromise;
10 11
 import com.luticate.utils.business.LuRequest;
@@ -15,11 +16,14 @@ import com.rthoni.camotion.ui.dialogs.LocationPickerDialog;
15 16
 import com.rthoni.camotion.ui.dialogs.LoginDialog;
16 17
 import com.rthoni.camotion.ui.fragments.AbstractCommandsFragment;
17 18
 
19
+import io.fabric.sdk.android.Fabric;
20
+
18 21
 public class AddCommandShortcutActivity extends Activity {
19 22
 
20 23
     @Override
21 24
     protected void onCreate(Bundle savedInstanceState) {
22 25
         super.onCreate(savedInstanceState);
26
+        Fabric.with(this, new Crashlytics());
23 27
         LuRequest.init(this);
24 28
         setContentView(R.layout.content_main);
25 29
         selectLocation();

+ 6
- 0
app/src/main/java/com/rthoni/camotion/ui/CommandExecActivity.java Целия файл

@@ -6,8 +6,10 @@ import android.os.Bundle;
6 6
 import android.support.v7.app.AlertDialog;
7 7
 import android.widget.Toast;
8 8
 
9
+import com.crashlytics.android.Crashlytics;
9 10
 import com.luticate.auth.dbo.LuLoginDbo;
10 11
 import com.luticate.utils.business.LuPromise;
12
+import com.luticate.utils.business.LuRequest;
11 13
 import com.rthoni.camotion.R;
12 14
 import com.rthoni.camotion.business.CamotionBusiness;
13 15
 import com.rthoni.camotion.dbo.CommandDbo;
@@ -19,11 +21,15 @@ import org.json.JSONObject;
19 21
 
20 22
 import java.util.List;
21 23
 
24
+import io.fabric.sdk.android.Fabric;
25
+
22 26
 public class CommandExecActivity extends Activity {
23 27
 
24 28
     @Override
25 29
     protected void onCreate(Bundle savedInstanceState) {
26 30
         super.onCreate(savedInstanceState);
31
+        Fabric.with(this, new Crashlytics());
32
+        LuRequest.init(this);
27 33
         setContentView(R.layout.activity_command_exec);
28 34
 
29 35
         CommandDbo command = new CommandDbo();

+ 5
- 0
app/src/main/java/com/rthoni/camotion/ui/MainActivity.java Целия файл

@@ -170,6 +170,11 @@ public class MainActivity extends AppCompatActivity
170 170
 
171 171
     private void showView(int view)
172 172
     {
173
+        if (_fullLoginDbo == null || _currentLocation == null)
174
+        {
175
+            init();
176
+            return;
177
+        }
173 178
         CamotionFragment fragment;
174 179
         if (view == R.id.nav_cameras) {
175 180
             fragment = new CamerasFragment();

+ 1
- 1
app/src/main/res/values/strings.xml Целия файл

@@ -27,7 +27,7 @@
27 27
     <string name="error_domain">Domain is required</string>
28 28
 
29 29
     <string name="loading">Loading…</string>
30
-    <string name="login_progress">Logging in…</string>
30
+    <string name="login_progress">Login in progress…</string>
31 31
 
32 32
     <string name="command_confirm">Do you really want to execute \'%1$s\' ?</string>
33 33
     <string name="command_loading">Executing \'%1$s\'&#8230;</string>

+ 2
- 2
gradle/wrapper/gradle-wrapper.properties Целия файл

@@ -1,6 +1,6 @@
1
-#Wed Oct 21 11:34:03 PDT 2015
1
+#Sat Apr 16 15:29:43 CEST 2016
2 2
 distributionBase=GRADLE_USER_HOME
3 3
 distributionPath=wrapper/dists
4 4
 zipStoreBase=GRADLE_USER_HOME
5 5
 zipStorePath=wrapper/dists
6
-distributionUrl=https\://services.gradle.org/distributions/gradle-2.8-all.zip
6
+distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip

Loading…
Отказ
Запис