如果通过语音命令打开相机,左上角会显示意外的“X”图标

Issue:

"
Actual Results:

Lanuch Google voice search,and say" Open camera", we observed:

A 'X' icon displays in left-upper corner in camera preview UI, and overlap with the Menu icon.

Expected Results:

Should no 'X' icon

Reproduction Steps:

  1. Launch Google voice search
  2. Say "open camera"

"

Solution:

"Solution: To invisible cancel button if open camera by voice command."

packages/apps/SnapdragonCamera/src/com/android/camera/CaptureUI.java

diff 复制代码
diff --git a/src/com/android/camera/CaptureUI.java b/src/com/android/camera/CaptureUI.java
index f39a5ec..03c5dcd 100644
--- a/src/com/android/camera/CaptureUI.java
+++ b/src/com/android/camera/CaptureUI.java
@@ -428,7 +428,12 @@
         if (intentMode != CaptureModule.INTENT_MODE_NORMAL) {
             mCameraControls.setIntentMode(intentMode);
             mCameraControls.setVideoMode(false);
-            mCancelButton.setVisibility(View.VISIBLE);
+            //BSPA-185897 'X' icon shouldn't show in left-upper corner if open camera by voice command.
+            if (XXXUtils.isXXX().orElse(false) && intentMode == CaptureModule.INTENT_MODE_STILL_IMAGE_CAMERA) {
+                Log.i(TAG,"Cancel icon shouldn't be show!");
+            } else {
+                mCancelButton.setVisibility(View.VISIBLE);
+            }
             mReviewCancelButton = mRootView.findViewById(R.id.preview_btn_cancel);
             mReviewDoneButton = mRootView.findViewById(R.id.done_button);
             mReviewRetakeButton = mRootView.findViewById(R.id.preview_btn_retake);
相关推荐
程序员码歌5 小时前
短思考第263天,每天复盘10分钟,胜过盲目努力一整年
android·前端·后端
安卓兼职framework应用工程师5 小时前
Android 10.0 按键智能机按键连续响两次的异常处理
android·audio·audioservice·按键音·按键声音
studyForMokey5 小时前
【Android 项目】个人学习demo随笔
android
吃喝不愁霸王餐APP开发者5 小时前
利用责任链模式解耦多平台(美团/饿了么)霸王餐接口的适配逻辑
android·责任链模式
百***78755 小时前
Step-Audio-2 轻量化接入全流程详解
android·java·gpt·php·llama
yangpipi-8 小时前
《C++并发编程实战》第5章 C++内存模型和原子操作
android·java·c++
云水木石10 小时前
Android 的下一个战场:Windows 应用与游戏?
android·windows·游戏
雨声不在10 小时前
Android文字渐变的实现
android·textview
GoldenPlayer10 小时前
KTS语法
android
GoldenPlayer10 小时前
后台服务Service销毁逻辑+单例造成的内存泄露
android