Add checks for FeatureFlags.QSB_ON_FIRST_SCREEN
When false, it correctly does not show the QSB but leaves a default style search bar which cannot be removed. Add checks to control default view visibility in device profile layout & re-layout, QSB container and in Workspace's onMeasure Bug: 35967694 Change-Id: I3d0f89e1022d838eeb95762fd1fb3f7257956c41
This commit is contained in:
1 parent
3ba48fa019
commit
b07a355fe2
3 files changed
+21
-6
No files matched your search
@@ -32,6 +32,7 @@ import android.widget.FrameLayout;
|
||||
|
||||
import com.android.launcher3.CellLayout.ContainerType;
|
||||
import com.android.launcher3.badge.BadgeRenderer;
|
||||
import com.android.launcher3.config.FeatureFlags;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
@@ -530,10 +531,13 @@ public class DeviceProfile {
|
||||
workspacePadding.bottom);
|
||||
workspace.setPageSpacing(getWorkspacePageSpacing());
|
||||
|
||||
View qsbContainer = launcher.getQsbContainer();
|
||||
lp = (FrameLayout.LayoutParams) qsbContainer.getLayoutParams();
|
||||
lp.topMargin = mInsets.top + workspacePadding.top;
|
||||
qsbContainer.setLayoutParams(lp);
|
||||
// Only display when enabled
|
||||
if (FeatureFlags.QSB_ON_FIRST_SCREEN) {
|
||||
View qsbContainer = launcher.getQsbContainer();
|
||||
lp = (FrameLayout.LayoutParams) qsbContainer.getLayoutParams();
|
||||
lp.topMargin = mInsets.top + workspacePadding.top;
|
||||
qsbContainer.setLayoutParams(lp);
|
||||
}
|
||||
|
||||
// Layout the hotseat
|
||||
Hotseat hotseat = (Hotseat) launcher.findViewById(R.id.hotseat);
|
||||
|
||||
Reference in new issue
Block a user