Merge "Small tweak to floating search on phone." into udc-qpr-dev am: 4c4f9b67a7
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/23670474 Change-Id: I75f6c2a5b7fb863a3226c3ff7c53dc0014ea8264 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -102,6 +102,12 @@ public class LauncherAllAppsContainerView extends ActivityAllAppsContainerView<L
|
||||
|
||||
StateManager<LauncherState> stateManager = mActivityContext.getStateManager();
|
||||
|
||||
// Special case to not expand the search bar when exiting All Apps on phones.
|
||||
if (stateManager.getCurrentStableState() == LauncherState.ALL_APPS
|
||||
&& mActivityContext.getDeviceProfile().isPhone) {
|
||||
return LauncherState.ALL_APPS.getFloatingSearchBarRestingMarginStart(mActivityContext);
|
||||
}
|
||||
|
||||
if (stateManager.isInTransition() && stateManager.getTargetState() != null) {
|
||||
return stateManager.getTargetState()
|
||||
.getFloatingSearchBarRestingMarginStart(mActivityContext);
|
||||
@@ -118,6 +124,12 @@ public class LauncherAllAppsContainerView extends ActivityAllAppsContainerView<L
|
||||
|
||||
StateManager<LauncherState> stateManager = mActivityContext.getStateManager();
|
||||
|
||||
// Special case to not expand the search bar when exiting All Apps on phones.
|
||||
if (stateManager.getCurrentStableState() == LauncherState.ALL_APPS
|
||||
&& mActivityContext.getDeviceProfile().isPhone) {
|
||||
return LauncherState.ALL_APPS.getFloatingSearchBarRestingMarginEnd(mActivityContext);
|
||||
}
|
||||
|
||||
if (stateManager.isInTransition() && stateManager.getTargetState() != null) {
|
||||
return stateManager.getTargetState()
|
||||
.getFloatingSearchBarRestingMarginEnd(mActivityContext);
|
||||
|
||||
Reference in New Issue
Block a user