如果通过语音命令打开相机,左上角会显示意外的“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);
相关推荐
booboosui8 小时前
Android 上来电怎么判:7 个条件加 5 个中文词
android
MardaWang8 小时前
App 内嵌 H5 的信任边界设计(ArkWeb/HarmonyOS 实战)
android
石头慢慢说8 小时前
不写 XPath,让 AI 在真机上跑测试:Appium MCP 全流程实战
android
90后的晨仔10 小时前
解决 Android 构建报错:Unable to delete file .../file-map.txt
android·前端
QYR_1110 小时前
年复合增长率11.4%!机器人指端视触觉传感器加速迈向规模化应用
人工智能·数码相机
mg66811 小时前
安卓玩机工具----安卓手机变成桌面电脑!多窗口镜像+音频投射+游戏操控,无需 Root
android·智能手机·电脑
peakmain911 小时前
异常处理 - Native 层的崩溃捕获机制及实现 (一)
android·性能优化
木头左12 小时前
【Android】听写播放器改版:中英文书写速度拆项与「正在读」高亮
android·room·media3·jetpack compose·听写
好的佩奇13 小时前
Dart 之方法、操作符与可调用对象
android·flutter·dart