如果通过语音命令打开相机,左上角会显示意外的“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);
相关推荐
c***21293 小时前
Springboot3学习(5、Druid使用及配置)
android·学习
修炼者3 小时前
【Android 进阶】别再强转 Context 了!手把手教你优雅解耦 View 与 Activity
android·android studio
x***01063 小时前
SpringSecurity+jwt实现权限认证功能
android·前端·后端
程序员江同学4 小时前
线下活动|2025 Kotlin 中文开发者大会北京分会场
android·kotlin
李坤林5 小时前
Android Vulkan 开启VK_GOOGLE_DISPLAY_TIMING 后,一个vsync 会释放两个imageBuffer现象分析
android·vulkan
Jerry5 小时前
Compose 状态思维
android
k***45995 小时前
MySQL----case的用法
android·数据库·mysql
r***86987 小时前
Plugin ‘mysql_native_password‘ is not loaded`
android·数据库·mysql
v***59837 小时前
MySQL-mysql zip安装包配置教程
android·mysql·adb
不用89k8 小时前
Android无法区分USB摄像头是哪一个
android