Revert "Disable blurs during critical thermal state"
This reverts commit 150831e.
Just no
Change-Id: Ibe98bd8b7cc5cc492d93bf767c73573a0b81d7d3
Signed-off-by: MOVZX <movzx@yahoo.com>
This commit is contained in:
@@ -16,7 +16,6 @@
|
||||
|
||||
package com.android.server.wm;
|
||||
|
||||
import static android.os.PowerManager.THERMAL_STATUS_CRITICAL;
|
||||
import static android.view.CrossWindowBlurListeners.CROSS_WINDOW_BLUR_SUPPORTED;
|
||||
|
||||
import android.content.BroadcastReceiver;
|
||||
@@ -46,7 +45,6 @@ final class BlurController {
|
||||
private final Object mLock = new Object();
|
||||
private volatile boolean mBlurEnabled;
|
||||
private boolean mInPowerSaveMode;
|
||||
private boolean mCriticalThermalStatus;
|
||||
private boolean mBlurDisabledSetting;
|
||||
private boolean mTunnelModeEnabled = false;
|
||||
|
||||
@@ -91,12 +89,6 @@ final class BlurController {
|
||||
});
|
||||
mBlurDisabledSetting = getBlurDisabledSetting();
|
||||
|
||||
powerManager.addThermalStatusListener((status) -> {
|
||||
mCriticalThermalStatus = status >= THERMAL_STATUS_CRITICAL;
|
||||
updateBlurEnabled();
|
||||
});
|
||||
mCriticalThermalStatus = powerManager.getCurrentThermalStatus() >= THERMAL_STATUS_CRITICAL;
|
||||
|
||||
TunnelModeEnabledListener.register(mTunnelModeListener);
|
||||
|
||||
updateBlurEnabled();
|
||||
@@ -120,7 +112,7 @@ final class BlurController {
|
||||
private void updateBlurEnabled() {
|
||||
synchronized (mLock) {
|
||||
final boolean newEnabled = CROSS_WINDOW_BLUR_SUPPORTED && !mBlurDisabledSetting
|
||||
&& !mInPowerSaveMode && !mTunnelModeEnabled && !mCriticalThermalStatus;
|
||||
&& !mInPowerSaveMode && !mTunnelModeEnabled;
|
||||
if (mBlurEnabled == newEnabled) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user