mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-03 09:26:51 +00:00
Show 3 button nav on phone in Taskbar (1/2)
* TODO: Landscape/seascape support,
Separate nav spacing out into
separate class/add tests
Bug: 219035565
Change-Id: I8f5c007f04ea4d6df15962772806356181d764ff
This commit is contained in:
@@ -119,7 +119,7 @@ public class TaskbarActivityContext extends BaseTaskbarContext {
|
||||
// The size we should return to when we call setTaskbarWindowFullscreen(false)
|
||||
private int mLastRequestedNonFullscreenHeight;
|
||||
|
||||
private final NavigationMode mNavMode;
|
||||
private NavigationMode mNavMode;
|
||||
private final boolean mImeDrawsImeNavBar;
|
||||
private final ViewCache mViewCache = new ViewCache();
|
||||
|
||||
@@ -235,7 +235,8 @@ public class TaskbarActivityContext extends BaseTaskbarContext {
|
||||
}
|
||||
|
||||
/** Updates {@link DeviceProfile} instances for any Taskbar windows. */
|
||||
public void updateDeviceProfile(DeviceProfile dp) {
|
||||
public void updateDeviceProfile(DeviceProfile dp, NavigationMode navMode) {
|
||||
mNavMode = navMode;
|
||||
mControllers.taskbarAllAppsController.updateDeviceProfile(dp);
|
||||
mDeviceProfile = dp.copy(this);
|
||||
updateIconSize(getResources());
|
||||
@@ -608,7 +609,10 @@ public class TaskbarActivityContext extends BaseTaskbarContext {
|
||||
*/
|
||||
public int getDefaultTaskbarWindowHeight() {
|
||||
if (FLAG_HIDE_NAVBAR_WINDOW && mDeviceProfile.isPhone) {
|
||||
return getResources().getDimensionPixelSize(R.dimen.taskbar_stashed_size);
|
||||
Resources resources = getResources();
|
||||
return isThreeButtonNav() ?
|
||||
resources.getDimensionPixelSize(R.dimen.taskbar_size) :
|
||||
resources.getDimensionPixelSize(R.dimen.taskbar_stashed_size);
|
||||
}
|
||||
return mDeviceProfile.taskbarSize + Math.max(getLeftCornerRadius(), getRightCornerRadius());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user