OSDN Git Service

なんとなく問題点を明らかにする。(通信回り)
[gokigen/FujiCam.git] / app / src / main / java / net / osdn / gokigen / cameratest / camtest / InformationView.java
index 439a327..1386bb3 100644 (file)
@@ -17,7 +17,7 @@ public class InformationView extends AppCompatImageView
     private final String TAG = toString();
     private Point focusPoint;
     private int sd_remain_size;
-    private String shooting_mode;
+    private String shooting_mode = null;
     private boolean focus_lock;
     private boolean isDeviceError;
     private int battery_level;
@@ -76,6 +76,15 @@ public class InformationView extends AppCompatImageView
             framePaint.setColor(Color.WHITE);
             framePaint.setTextSize(24);
 
+
+            if (shooting_mode == null)
+            {
+                String message = "NOT CONNECTED";
+                canvas.drawText(message, centerX, centerY, framePaint);
+                Log.v(TAG, message);
+                return;
+            }
+
             String message = shooting_mode + " REMAIN : " + sd_remain_size  + " ISO : " + iso  + " BATT: ";
             if (battery_level < 0)
             {