mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-03 17:36:49 +00:00
Hide taskbar on lockscreen
Add new animated float to disable taskbar background value when keyguard is visible. Fixes: 191857724 Test: Tested w/ and w/o bouncer for gesture + 3 button Tested w/ IME pw on lock screen. Change-Id: I2e1696fd25f4c170bfb2bc0694ccd644e453b1fe
This commit is contained in:
@@ -39,6 +39,7 @@ public class TaskbarDragLayerController {
|
||||
// Alpha properties for taskbar background.
|
||||
private final AnimatedFloat mBgTaskbar = new AnimatedFloat(this::updateBackgroundAlpha);
|
||||
private final AnimatedFloat mBgNavbar = new AnimatedFloat(this::updateBackgroundAlpha);
|
||||
private final AnimatedFloat mKeyguardBgTaskbar = new AnimatedFloat(this::updateBackgroundAlpha);
|
||||
// Translation property for taskbar background.
|
||||
private final AnimatedFloat mBgOffset = new AnimatedFloat(this::updateBackgroundOffset);
|
||||
|
||||
@@ -56,6 +57,7 @@ public class TaskbarDragLayerController {
|
||||
public void init(TaskbarControllers controllers) {
|
||||
mControllers = controllers;
|
||||
mTaskbarDragLayer.init(new TaskbarDragLayerCallbacks());
|
||||
mKeyguardBgTaskbar.value = 1;
|
||||
}
|
||||
|
||||
public void onDestroy() {
|
||||
@@ -80,12 +82,18 @@ public class TaskbarDragLayerController {
|
||||
return mBgNavbar;
|
||||
}
|
||||
|
||||
public AnimatedFloat getKeyguardBgTaskbar() {
|
||||
return mKeyguardBgTaskbar;
|
||||
}
|
||||
|
||||
public AnimatedFloat getTaskbarBackgroundOffset() {
|
||||
return mBgOffset;
|
||||
}
|
||||
|
||||
private void updateBackgroundAlpha() {
|
||||
mTaskbarDragLayer.setTaskbarBackgroundAlpha(Math.max(mBgNavbar.value, mBgTaskbar.value));
|
||||
mTaskbarDragLayer.setTaskbarBackgroundAlpha(
|
||||
Math.max(mBgNavbar.value, mBgTaskbar.value * mKeyguardBgTaskbar.value)
|
||||
);
|
||||
}
|
||||
|
||||
private void updateBackgroundOffset() {
|
||||
|
||||
Reference in New Issue
Block a user