如果通过语音命令打开相机,左上角会显示意外的“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);
相关推荐
Cao_Shixin攻城狮3 小时前
Flutter运行Android项目时显示java版本不兼容(Unsupported class file major version 65)的处理
android·java·flutter
呼啦啦呼啦啦啦啦啦啦6 小时前
利用pdfjs实现的pdf预览简单demo(包含翻页功能)
android·javascript·pdf
idjl8 小时前
Mysql测试题
android·adb
游戏开发爱好者810 小时前
iOS App 电池消耗管理与优化 提升用户体验的完整指南
android·ios·小程序·https·uni-app·iphone·webview
人生游戏牛马NPC1号11 小时前
学习 Flutter (四):玩安卓项目实战 - 中
android·学习·flutter
星辰也为你祝福h12 小时前
Android原生Dialog
android
梁同学与Android13 小时前
Android ---【CPU优化】需要优化的原因及优化的地方
android
Misha韩13 小时前
React Native 基础tabBar和自定义tabBar - bottom-tabs
android·react native
iHero14 小时前
【Nextcloud】在 Ubuntu 22.04.3 LTS 上的 Nextcloud Hub 10 (31.0.2) 后台任务cron 的优化
android·linux·ubuntu·nextcloud
yuanlaile17 小时前
Flutter Android打包学习指南
android·flutter·flutter打包·flutter android