diff options
author | Linux Build Service Account <lnxbuild@localhost> | 2023-02-27 14:57:40 -0800 |
---|---|---|
committer | Linux Build Service Account <lnxbuild@localhost> | 2023-02-27 14:57:40 -0800 |
commit | ddca2ed252dc0b2f3c72d388dac663d9e3c8e904 (patch) | |
tree | 03d527112c59850b57ac6231a29be8c98f8cc53b | |
parent | 5562ac7eb525c632774914eb2b1ee2152521e046 (diff) | |
parent | 9c1a07b890f15755012ad0cba42208a4074b2b32 (diff) |
Merge 9c1a07b890f15755012ad0cba42208a4074b2b32 on remote branch
Change-Id: I6d42e8643bc299bc14328434ad84c4ef1dcbbb00
8 files changed, 28 insertions, 16 deletions
diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml index 365808b77253..7693014d588a 100644 --- a/core/res/AndroidManifest.xml +++ b/core/res/AndroidManifest.xml @@ -6564,6 +6564,13 @@ <permission android:name="android.permission.MAKE_UID_VISIBLE" android:protectionLevel="signature" /> + <!-- Used for permissions that are associated with enabling secondary SIM do not disturb feature + @hide --> + <permission android:name="com.qualcomm.qti.qesdk.permission.CALL_CONTROL_SECONDARY_DND" + android:label="@string/permlabel_sec_dnd" + android:description="@string/permdesc_sec_dnd" + android:protectionLevel="dangerous" /> + <!-- Attribution for Geofencing service. --> <attribution android:tag="GeofencingService" android:label="@string/geofencing_service"/> <!-- Attribution for Country Detector. --> diff --git a/core/res/res/values/strings.xml b/core/res/res/values/strings.xml index 36d9ea0ac343..095a6a3cd46a 100644 --- a/core/res/res/values/strings.xml +++ b/core/res/res/values/strings.xml @@ -4105,6 +4105,11 @@ <!-- Description of an application permission that lets it query all other packages. [CHAR LIMIT=NONE] --> <string name="permdesc_queryAllPackages">Allows an app to see all installed packages.</string> + <!-- Description of an application permission that grants access to secondary SIM do not disturb feature. --> + <string name="permdesc_sec_dnd">enable do not disturb feature on secondary SIM</string> + <!-- Title of an application permission that grants access to secondary SIM do not disturb feature. --> + <string name="permlabel_sec_dnd">Secondary SIM Do Not Disturb</string> + <!-- Shown in the tutorial for tap twice for zoom control. --> <string name="tutorial_double_tap_to_zoom_message_short">Tap twice for zoom control</string> diff --git a/packages/SettingsLib/res/values/arrays.xml b/packages/SettingsLib/res/values/arrays.xml index abeec759cfa7..d361547e1bd4 100644 --- a/packages/SettingsLib/res/values/arrays.xml +++ b/packages/SettingsLib/res/values/arrays.xml @@ -172,7 +172,6 @@ <item>Opus</item> <item><xliff:g id="qualcomm">Qualcomm®</xliff:g> <xliff:g id="aptx_adaptive">aptX™ Adaptive</xliff:g> audio</item> <item><xliff:g id="qualcomm">Qualcomm®</xliff:g> <xliff:g id="aptx_twsp">aptX™ TWS+</xliff:g> audio</item> - <item>LC3</item> </string-array> <!-- Values for Bluetooth Audio Codec selection preference. --> @@ -202,7 +201,6 @@ <item>Opus</item> <item><xliff:g id="qualcomm">Qualcomm®</xliff:g> <xliff:g id="aptx_adaptive">aptX™ Adaptive</xliff:g> audio</item> <item><xliff:g id="qualcomm">Qualcomm®</xliff:g> <xliff:g id="aptx_twsp">aptX™ TWS+</xliff:g> audio</item> - <item>LC3</item> </string-array> <!-- Titles for Bluetooth Audio Codec Sample Rate selection preference. [CHAR LIMIT=50] --> diff --git a/packages/SettingsLib/src/com/android/settingslib/bluetooth/A2dpProfile.java b/packages/SettingsLib/src/com/android/settingslib/bluetooth/A2dpProfile.java index ebec2d23768f..0e818c672838 100644 --- a/packages/SettingsLib/src/com/android/settingslib/bluetooth/A2dpProfile.java +++ b/packages/SettingsLib/src/com/android/settingslib/bluetooth/A2dpProfile.java @@ -368,16 +368,16 @@ public class A2dpProfile implements LocalBluetoothProfile { case BluetoothCodecConfig.SOURCE_CODEC_TYPE_LDAC: index = 5; break; - case BluetoothCodecConfig.SOURCE_CODEC_TYPE_APTX_ADAPTIVE: + case BluetoothCodecConfig.SOURCE_CODEC_TYPE_LC3: index = 6; break; - case BluetoothCodecConfig.SOURCE_CODEC_TYPE_APTX_TWSP: + case SOURCE_CODEC_TYPE_OPUS: // TODO update in U index = 7; break; - case BluetoothCodecConfig.SOURCE_CODEC_TYPE_LC3: + case BluetoothCodecConfig.SOURCE_CODEC_TYPE_APTX_ADAPTIVE: index = 8; break; - case SOURCE_CODEC_TYPE_OPUS: // TODO update in U + case BluetoothCodecConfig.SOURCE_CODEC_TYPE_APTX_TWSP: index = 9; break; } diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/fragment/CollapsedStatusBarFragment.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/fragment/CollapsedStatusBarFragment.java index c9ce757270a9..6b41b619d380 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/fragment/CollapsedStatusBarFragment.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/fragment/CollapsedStatusBarFragment.java @@ -112,7 +112,6 @@ public class CollapsedStatusBarFragment extends Fragment implements CommandQueue private final NotificationPanelViewController mNotificationPanelViewController; private final NetworkController mNetworkController; private LinearLayout mSystemIconArea; - private boolean mSystemIconAreaPendingToShow; private LinearLayout mEndSideContent; private View mClockView; private View mOngoingCallChip; @@ -500,7 +499,6 @@ public class CollapsedStatusBarFragment extends Fragment implements CommandQueue } private void hideSystemIconArea(boolean animate) { - mSystemIconAreaPendingToShow = false; animateHide(mSystemIconArea, animate); } @@ -514,7 +512,6 @@ public class CollapsedStatusBarFragment extends Fragment implements CommandQueue if (state == IDLE || state == SHOWING_PERSISTENT_DOT) { animateShow(mEndSideContent, animate); } else { - mSystemIconAreaPendingToShow = true; // We are in the middle of a system status event animation, which will animate the // alpha (but not the visibility). Allow the view to become visible again mEndSideContent.setVisibility(View.VISIBLE); @@ -677,10 +674,6 @@ public class CollapsedStatusBarFragment extends Fragment implements CommandQueue @Nullable @Override public Animator onSystemEventAnimationFinish(boolean hasPersistentDot) { - if (mSystemIconAreaPendingToShow) { - mSystemIconAreaPendingToShow = false; - animateShow(mSystemIconArea, false); - } return mSystemEventAnimator.onSystemEventAnimationFinish(hasPersistentDot); } diff --git a/services/core/java/com/android/server/wm/ActivityClientController.java b/services/core/java/com/android/server/wm/ActivityClientController.java index d2a00af245f6..4a4a22596fea 100644 --- a/services/core/java/com/android/server/wm/ActivityClientController.java +++ b/services/core/java/com/android/server/wm/ActivityClientController.java @@ -447,6 +447,7 @@ class ActivityClientController extends IActivityClientController.Stub { final long origId = Binder.clearCallingIdentity(); Trace.traceBegin(TRACE_TAG_WINDOW_MANAGER, "finishActivity"); try { + r.releaseActivityBoost(); final boolean res; final boolean finishWithRootActivity = finishTask == Activity.FINISH_TASK_WITH_ROOT_ACTIVITY; diff --git a/services/core/java/com/android/server/wm/ActivityRecord.java b/services/core/java/com/android/server/wm/ActivityRecord.java index 34526e90f3d5..eac838d50d8f 100644 --- a/services/core/java/com/android/server/wm/ActivityRecord.java +++ b/services/core/java/com/android/server/wm/ActivityRecord.java @@ -6687,14 +6687,18 @@ public final class ActivityRecord extends WindowToken implements WindowManagerSe } } - /** Called when the windows associated app window container are drawn. */ - private void onWindowsDrawn(long timestampNs) { + protected void releaseActivityBoost() { if (mPerf != null && perfActivityBoostHandler > 0) { mPerf.perfLockReleaseHandler(perfActivityBoostHandler); perfActivityBoostHandler = -1; } else if (perfActivityBoostHandler > 0) { Slog.w(TAG, "activity boost didn't release as expected"); } + } + + /** Called when the windows associated app window container are drawn. */ + private void onWindowsDrawn(long timestampNs) { + releaseActivityBoost(); final TransitionInfoSnapshot info = mTaskSupervisor .getActivityMetricsLogger().notifyWindowsDrawn(this, timestampNs); final boolean validInfo = info != null; diff --git a/services/core/java/com/android/server/wm/RootWindowContainer.java b/services/core/java/com/android/server/wm/RootWindowContainer.java index ca0be88c8eb7..9587653b6e2e 100644 --- a/services/core/java/com/android/server/wm/RootWindowContainer.java +++ b/services/core/java/com/android/server/wm/RootWindowContainer.java @@ -2302,7 +2302,11 @@ public class RootWindowContainer extends WindowContainer<DisplayContent> /* Acquire perf lock *only* during new app launch */ if ((mTmpFindTaskResult.mIdealRecord == null) || (mTmpFindTaskResult.mIdealRecord.getState() == DESTROYED)) { - acquireAppLaunchPerfLock(r); + if (r != null && r.isMainIntent(r.intent)) { + acquireAppLaunchPerfLock(r); + } else if (r == null) { + Slog.w(TAG, "Should not happen! Didn't apply launch boost"); + } } final ActivityRecord idealMatchActivity = getItemFromTaskDisplayAreas(taskDisplayArea -> { |