Merge "Disable 3-Button NavBar Recents key when launch secure camera" into udc-dev am: d41919d2ab am: 816bdcb37d
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/22700065 Change-Id: I7be750ada4ac7be0ec278f9692ef1a24919a19d4 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -28,6 +28,8 @@
|
||||
<!-- Will display the bouncer on one side of the display, and the current user icon and
|
||||
user switcher on the other side -->
|
||||
<bool name="config_enableBouncerUserSwitcher">false</bool>
|
||||
<!-- Will enable custom clocks on the lockscreen -->
|
||||
<bool name="config_enableLockScreenCustomClocks">true</bool>
|
||||
<!-- Time to be considered a consecutive fingerprint failure in ms -->
|
||||
<integer name="fp_consecutive_failure_time_ms">3500</integer>
|
||||
</resources>
|
||||
|
||||
@@ -120,7 +120,12 @@ object Flags {
|
||||
resourceBooleanFlag(204, R.bool.config_enableBouncerUserSwitcher, "bouncer_user_switcher")
|
||||
|
||||
// TODO(b/254512676): Tracking Bug
|
||||
@JvmField val LOCKSCREEN_CUSTOM_CLOCKS = releasedFlag(207, "lockscreen_custom_clocks")
|
||||
@JvmField
|
||||
val LOCKSCREEN_CUSTOM_CLOCKS = resourceBooleanFlag(
|
||||
207,
|
||||
R.bool.config_enableLockScreenCustomClocks,
|
||||
"lockscreen_custom_clocks"
|
||||
)
|
||||
|
||||
// TODO(b/275694445): Tracking Bug
|
||||
@JvmField
|
||||
|
||||
@@ -1501,13 +1501,17 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable,
|
||||
notifyFinishedGoingToSleep();
|
||||
|
||||
if (cameraGestureTriggered) {
|
||||
|
||||
// Just to make sure, make sure the device is awake.
|
||||
mContext.getSystemService(PowerManager.class).wakeUp(SystemClock.uptimeMillis(),
|
||||
PowerManager.WAKE_REASON_CAMERA_LAUNCH,
|
||||
"com.android.systemui:CAMERA_GESTURE_PREVENT_LOCK");
|
||||
setPendingLock(false);
|
||||
mPendingReset = false;
|
||||
mPowerGestureIntercepted = true;
|
||||
if (DEBUG) {
|
||||
Log.d(TAG, "cameraGestureTriggered=" + cameraGestureTriggered
|
||||
+ ",mPowerGestureIntercepted=" + mPowerGestureIntercepted);
|
||||
}
|
||||
}
|
||||
|
||||
if (mPendingReset) {
|
||||
@@ -1706,7 +1710,13 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable,
|
||||
mAnimatingScreenOff = false;
|
||||
cancelDoKeyguardLaterLocked();
|
||||
cancelDoKeyguardForChildProfilesLocked();
|
||||
if (DEBUG) Log.d(TAG, "onStartedWakingUp, seq = " + mDelayedShowingSequence);
|
||||
if (cameraGestureTriggered) {
|
||||
mPowerGestureIntercepted = true;
|
||||
}
|
||||
if (DEBUG) {
|
||||
Log.d(TAG, "onStartedWakingUp, seq = " + mDelayedShowingSequence
|
||||
+ ", mPowerGestureIntercepted = " + mPowerGestureIntercepted);
|
||||
}
|
||||
notifyStartedWakingUp();
|
||||
}
|
||||
mUiEventLogger.logWithInstanceIdAndPosition(
|
||||
@@ -1933,12 +1943,19 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable,
|
||||
startKeyguardExitAnimation(0, 0);
|
||||
}
|
||||
|
||||
mPowerGestureIntercepted = mUpdateMonitor.isSecureCameraLaunchedOverKeyguard();
|
||||
|
||||
if (mOccluded != isOccluded) {
|
||||
mOccluded = isOccluded;
|
||||
mKeyguardViewControllerLazy.get().setOccluded(isOccluded, animate
|
||||
&& mDeviceInteractive);
|
||||
adjustStatusBarLocked();
|
||||
}
|
||||
|
||||
if (DEBUG) {
|
||||
Log.d(TAG, "isOccluded=" + isOccluded + ",mPowerGestureIntercepted="
|
||||
+ mPowerGestureIntercepted);
|
||||
}
|
||||
}
|
||||
Trace.endSection();
|
||||
}
|
||||
@@ -3056,6 +3073,10 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable,
|
||||
flags |= StatusBarManager.DISABLE_RECENT;
|
||||
}
|
||||
|
||||
if (mPowerGestureIntercepted) {
|
||||
flags |= StatusBarManager.DISABLE_RECENT;
|
||||
}
|
||||
|
||||
if (DEBUG) {
|
||||
Log.d(TAG, "adjustStatusBarLocked: mShowing=" + mShowing + " mOccluded=" + mOccluded
|
||||
+ " isSecure=" + isSecure() + " force=" + forceHideHomeRecentsButtons
|
||||
|
||||
@@ -418,7 +418,7 @@ JTvInputHal::TvInputCallback::TvInputCallback(JTvInputHal* hal) {
|
||||
::ndk::ScopedAStatus JTvInputHal::TvInputCallback::notifyTvMessageEvent(
|
||||
const AidlTvMessageEvent& event) {
|
||||
const std::string DEVICE_ID_SUBTYPE = "device_id";
|
||||
if (sizeof(event.messages) > 0 && event.messages[0].subType == DEVICE_ID_SUBTYPE) {
|
||||
if (event.messages.size() > 1 && event.messages[0].subType == DEVICE_ID_SUBTYPE) {
|
||||
mHal->mLooper
|
||||
->sendMessage(new NotifyTvMessageHandler(mHal,
|
||||
TvMessageEventWrapper::createEventWrapper(
|
||||
|
||||
@@ -34,6 +34,8 @@ import android.os.SystemProperties;
|
||||
import android.os.UpdateEngine;
|
||||
import android.os.UpdateEngineCallback;
|
||||
import android.provider.DeviceConfig;
|
||||
import android.provider.Settings;
|
||||
import android.provider.Settings.SettingNotFoundException;
|
||||
import android.util.Log;
|
||||
|
||||
import com.android.internal.R;
|
||||
@@ -332,8 +334,17 @@ public final class ProfcollectForwardingService extends SystemService {
|
||||
Context context = getContext();
|
||||
BackgroundThread.get().getThreadHandler().post(() -> {
|
||||
try {
|
||||
int usageSetting = -1;
|
||||
try {
|
||||
// Get "Usage & diagnostics" checkbox status. 1 is for enabled, 0 is for
|
||||
// disabled.
|
||||
usageSetting = Settings.Global.getInt(context.getContentResolver(), "multi_cb");
|
||||
} catch (SettingNotFoundException e) {
|
||||
Log.i(LOG_TAG, "Usage setting not found: " + e.getMessage());
|
||||
}
|
||||
|
||||
// Prepare profile report
|
||||
String reportName = mIProfcollect.report() + ".zip";
|
||||
String reportName = mIProfcollect.report(usageSetting) + ".zip";
|
||||
|
||||
if (!context.getResources().getBoolean(
|
||||
R.bool.config_profcollectReportUploaderEnabled)) {
|
||||
|
||||
@@ -2539,10 +2539,14 @@ public class UsageStatsService extends SystemService implements
|
||||
}
|
||||
|
||||
@Override
|
||||
public void reportChooserSelection(String packageName, int userId, String contentType,
|
||||
String[] annotations, String action) {
|
||||
public void reportChooserSelection(@NonNull String packageName, int userId,
|
||||
String contentType, String[] annotations, String action) {
|
||||
if (packageName == null) {
|
||||
Slog.w(TAG, "Event report user selecting a null package");
|
||||
throw new IllegalArgumentException("Package selection must not be null.");
|
||||
}
|
||||
// Verify if this package exists before reporting an event for it.
|
||||
if (mPackageManagerInternal.getPackageUid(packageName, 0, userId) < 0) {
|
||||
Slog.w(TAG, "Event report user selecting an invalid package");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user