Add transient taskbar UI

This change is only for the visual appearance of the
transient taskbar.

Bug: 252905206
Test: manual
Change-Id: I4990b20b39089a0c27ec2a72dd3010cf64ddba1d
This commit is contained in:
Jon Miranda
2022-10-20 13:15:19 -07:00
parent 0cf401d0eb
commit 184a04266d
15 changed files with 260 additions and 35 deletions

View File

@@ -20,6 +20,7 @@ import static android.view.Display.DEFAULT_DISPLAY;
import static android.view.WindowManager.LayoutParams.TYPE_APPLICATION;
import static com.android.launcher3.Utilities.dpiFromPx;
import static com.android.launcher3.config.FeatureFlags.ENABLE_TRANSIENT_TASKBAR;
import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
import static com.android.launcher3.util.PackageManagerHelper.getPackageFilter;
import static com.android.launcher3.util.window.WindowManagerProxy.MIN_TABLET_WIDTH;
@@ -123,6 +124,14 @@ public class DisplayController implements ComponentCallbacks, SafeCloseable {
return INSTANCE.get(context).getInfo().navigationMode;
}
/**
* Returns whether taskbar is transient.
*/
public static boolean isTransientTaskbar(Context context) {
return ENABLE_TRANSIENT_TASKBAR.get()
&& getNavigationMode(context) == NavigationMode.NO_BUTTON;
}
@Override
public void close() {
mDestroyed = true;