mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-20 11:18:21 +00:00
Unifying multiple all-apps implementations
> Using a single layout for the all-apps content > Removing some unnecessary themes > Fixing search chashes in SecondaryDisplayLauncher Bug: 259733681 Test: Existing TAPL tests verify that Launcher/AllApps work properly Change-Id: Icd5310316499cd421bc039cdbd4d398b813cd477
This commit is contained in:
@@ -17,6 +17,7 @@ package com.android.launcher3.taskbar.allapps;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.AttributeSet;
|
||||
import android.view.View;
|
||||
import android.view.WindowInsets;
|
||||
|
||||
import com.android.launcher3.DeviceProfile;
|
||||
@@ -42,6 +43,19 @@ public class TaskbarAllAppsContainerView extends
|
||||
return super.onApplyWindowInsets(insets);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected View inflateSearchBox() {
|
||||
// Remove top padding of header, since we do not have any search
|
||||
mHeader.setPadding(mHeader.getPaddingLeft(), 0,
|
||||
mHeader.getPaddingRight(), mHeader.getPaddingBottom());
|
||||
|
||||
TaskbarAllAppsFallbackSearchContainer searchView =
|
||||
new TaskbarAllAppsFallbackSearchContainer(getContext(), null);
|
||||
searchView.setId(R.id.search_container_all_apps);
|
||||
searchView.setVisibility(GONE);
|
||||
return searchView;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isSearchSupported() {
|
||||
return false;
|
||||
@@ -53,4 +67,10 @@ public class TaskbarAllAppsContainerView extends
|
||||
// TODO(b/240670050): Remove this and add header protection for the taskbar entrypoint.
|
||||
mBottomSheetBackground.setBackgroundResource(R.drawable.bg_rounded_corner_bottom_sheet);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isInAllApps() {
|
||||
// All apps is always open
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user