OSDN Git Service

表示エリアの右中央がうまく表示できなかった不具合を修正。
authorMRSa <mrsa@myad.jp>
Fri, 11 Aug 2017 02:42:33 +0000 (11:42 +0900)
committerMRSa <mrsa@myad.jp>
Fri, 11 Aug 2017 02:42:33 +0000 (11:42 +0900)
AF/MF表示エリアの準備。

wear/src/main/java/jp/sfjp/gokigen/a01c/liveview/CameraLiveImageView.java
wear/src/main/java/jp/sfjp/gokigen/a01c/olycamerawrapper/indicator/CameraStatusDisplay.java

index a4a1d79..b6fc648 100644 (file)
@@ -779,7 +779,6 @@ public class CameraLiveImageView extends View implements CameraLiveViewListenerI
             paint.setTextSize(messageHolder.getSize(ShowMessageHolder.MessageArea.CENTERLEFT));
             paint.setAntiAlias(true);
             paint.setShadowLayer(5.0f, 3.0f, 3.0f, Color.BLACK);  // これで文字に影をつけたい
-            float width = paint.measureText(message) / 2.0f;
             Paint.FontMetrics fontMetrics = paint.getFontMetrics();
             float cy = (canvas.getHeight() / 2.0f) - ((fontMetrics.ascent + fontMetrics.descent) / 2.0f);
             canvas.drawText(message, viewRect.left + 3.0f, cy, paint);
@@ -794,7 +793,7 @@ public class CameraLiveImageView extends View implements CameraLiveViewListenerI
             paint.setTextSize(messageHolder.getSize(ShowMessageHolder.MessageArea.CENTERRIGHT));
             paint.setAntiAlias(true);
             paint.setShadowLayer(5.0f, 3.0f, 3.0f, Color.BLACK);  // これで文字に影をつけたい
-            float width = paint.measureText(message) / 2.0f;
+            float width = paint.measureText(message);
             Paint.FontMetrics fontMetrics = paint.getFontMetrics();
             float cy = (canvas.getHeight() / 2.0f) - ((fontMetrics.ascent + fontMetrics.descent) / 2.0f);
             canvas.drawText(message, (viewRect.right - 3.0f) - width, cy, paint);
index be4fe24..954cbee 100644 (file)
@@ -38,7 +38,7 @@ public class CameraStatusDisplay implements  ICameraStatusDisplay
     private int shortMovieLengthArea = IShowInformation.AREA_NONE;       // 動画撮影時のショートムービー長さ表示エリア指定
     private int movieTakeModeArea = IShowInformation.AREA_NONE;      // 動画撮影時の撮影モード表示エリア指定
 
-    private int stillFocusArea =  IShowInformation.AREA_NONE;        // スチル用フォーカスモード表示エリア指定
+    private int stillFocusArea =  IShowInformation.AREA_NONE;           // スチル用フォーカスモード表示エリア指定 (AF/MF)
     private int movieFocusArea = IShowInformation.AREA_NONE;         // ムービー用フォーカスモード表示エリア指定
     private int fullTimeAfArea = IShowInformation.AREA_NONE;         // フルタイムAF表示エリア指定
 
@@ -255,9 +255,15 @@ public class CameraStatusDisplay implements  ICameraStatusDisplay
         String propertyValue = propertyProxy.getCameraPropertyValueTitle(propertyProxy.getCameraPropertyValue(IOlyCameraProperty.FOCUS_STILL));
         if (propertyValue != null)
         {
-            informationObject.setMessage(stillFocusArea, Color.WHITE, propertyValue);
+            if ("S-AF".equals(propertyValue))
+            {
+                informationObject.setMessage(stillFocusArea, Color.WHITE, "");
+            }
+            else
+            {
+                informationObject.setMessage(stillFocusArea, Color.WHITE, propertyValue);
+            }
         }
-
     }
 
     /**
@@ -567,7 +573,7 @@ public class CameraStatusDisplay implements  ICameraStatusDisplay
                 movieQualityArea = IShowInformation.AREA_NONE;        // 動画モードの品質表示エリア指定
                 shortMovieLengthArea = IShowInformation.AREA_NONE;    // 動画のショーとクリップ撮影秒数設定表示エリア指定
                 movieTakeModeArea = IShowInformation.AREA_NONE;       // 動画モード時の撮影モード表示エリア指定
-                stillFocusArea = IShowInformation.AREA_NONE;          // フォーカスモード静止画用の表示エリア指定
+                stillFocusArea = IShowInformation.AREA_NONE;              // フォーカスモード静止画用の表示エリア指定
                 movieFocusArea = IShowInformation.AREA_NONE;          // フォーカスモードムービー用の表示エリア指定
                 fullTimeAfArea = IShowInformation.AREA_NONE;          // フルタイムAFモード表示エリア指定
                 informationObject.setMessage(IShowInformation.AREA_8, Color.WHITE, "");
@@ -603,5 +609,6 @@ public class CameraStatusDisplay implements  ICameraStatusDisplay
         updateAeMode();
         updateAeLockState();
         updateArtFilter();
+        //updateStillFocusMode();
     }
 }