UI : Improve consistency

https://gitlab.com/AuroraOSS/AuroraStore/issues/92
This commit is contained in:
Mr. Dragon
2019-07-26 02:38:35 +05:30
parent 20847aecde
commit ac35db0d56
13 changed files with 200 additions and 302 deletions

View File

@@ -35,7 +35,6 @@ import androidx.recyclerview.widget.GridLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import com.aurora.store.R;
import com.aurora.store.activity.AuroraActivity;
import com.aurora.store.adapter.CategoriesListAdapter;
import com.aurora.store.manager.CategoryManager;
import com.aurora.store.task.CategoryList;
@@ -66,8 +65,6 @@ public class CategoriesFragment extends Fragment {
private CategoryManager categoryManager;
private CompositeDisposable disposable = new CompositeDisposable();
private CategoriesListAdapter categoriesListAdapter;
private BottomNavigationView bottomNavigationView;
private ActionBar actionBar;
private String categoryType = APPS;
@Override
@@ -101,10 +98,6 @@ public class CategoriesFragment extends Fragment {
@Override
public void onActivityCreated(@Nullable Bundle savedInstanceState) {
super.onActivityCreated(savedInstanceState);
if (getActivity() instanceof AuroraActivity) {
bottomNavigationView = ((AuroraActivity) getActivity()).getBottomNavigation();
actionBar = ((AuroraActivity) getActivity()).getSupportActionBar();
}
}
@Override
@@ -117,10 +110,6 @@ public class CategoriesFragment extends Fragment {
@Override
public void onDestroy() {
Glide.with(this).pauseAllRequests();
if (actionBar != null)
actionBar.setTitle(getString(R.string.app_name));
if (bottomNavigationView != null)
ViewUtil.showBottomNav(bottomNavigationView, true);
super.onDestroy();
}

View File

@@ -39,9 +39,9 @@ import com.aurora.store.adapter.SubCategoryAdapter;
import com.aurora.store.sheet.FilterBottomSheet;
import com.aurora.store.utility.Log;
import com.aurora.store.utility.Util;
import com.aurora.store.utility.ViewUtil;
import com.bumptech.glide.Glide;
import com.google.android.material.bottomnavigation.BottomNavigationView;
import com.google.android.material.floatingactionbutton.ExtendedFloatingActionButton;
import com.google.android.material.floatingactionbutton.FloatingActionButton;
import com.google.android.material.tabs.TabLayout;
@@ -57,13 +57,12 @@ public class CategoryAppsFragment extends Fragment {
@BindView(R.id.category_tabs)
TabLayout tabLayout;
@BindView(R.id.filter_fab)
FloatingActionButton filterFab;
ExtendedFloatingActionButton filterFab;
private Context context;
private BottomNavigationView bottomNavigationView;
private ActionBar actionBar;
public FloatingActionButton getFilterFab() {
public ExtendedFloatingActionButton getFilterFab() {
return filterFab;
}
@@ -99,10 +98,6 @@ public class CategoryAppsFragment extends Fragment {
filterFab.setOnClickListener(v -> {
getFilterDialog();
});
if (getActivity() instanceof AuroraActivity) {
bottomNavigationView = ((AuroraActivity) getActivity()).getBottomNavigation();
ViewUtil.hideBottomNav(bottomNavigationView, true);
}
}
@Override
@@ -110,8 +105,6 @@ public class CategoryAppsFragment extends Fragment {
Glide.with(this).pauseAllRequests();
if (actionBar != null)
actionBar.setTitle(getString(R.string.app_name));
if (bottomNavigationView != null)
ViewUtil.showBottomNav(bottomNavigationView, true);
if (Util.filterSearchNonPersistent(context))
new Filter(context).resetFilterPreferences();
super.onDestroy();

View File

@@ -36,7 +36,6 @@ import androidx.recyclerview.widget.RecyclerView;
import com.aurora.store.ErrorType;
import com.aurora.store.R;
import com.aurora.store.SharedPreferencesTranslator;
import com.aurora.store.activity.AuroraActivity;
import com.aurora.store.adapter.FeaturedAppsAdapter;
import com.aurora.store.adapter.TopCategoriesAdapter;
import com.aurora.store.manager.CategoryManager;
@@ -46,7 +45,6 @@ import com.aurora.store.utility.ContextUtil;
import com.aurora.store.utility.Log;
import com.aurora.store.utility.Util;
import com.dragons.aurora.playstoreapiv2.GooglePlayAPI;
import com.google.android.material.bottomnavigation.BottomNavigationView;
import com.google.android.material.button.MaterialButton;
import butterknife.BindView;
@@ -80,7 +78,6 @@ public class HomeFragment extends BaseFragment {
private FeaturedAppsAdapter topAppsAdapter;
private FeaturedAppsAdapter topGamesAdapter;
private FeaturedAppsAdapter topFamilyAdapter;
private BottomNavigationView bottomNavigationView;
private CategoryManager categoryManager;
private FeaturedAppsTask featuredAppsTask;
private SharedPreferencesTranslator translator;
@@ -119,10 +116,6 @@ public class HomeFragment extends BaseFragment {
super.onViewCreated(view, savedInstanceState);
setErrorView(ErrorType.UNKNOWN);
init();
if (getActivity() instanceof AuroraActivity) {
bottomNavigationView = ((AuroraActivity) getActivity()).getBottomNavigation();
setBaseBottomNavigationView(bottomNavigationView);
}
}
@Override

View File

@@ -37,14 +37,11 @@ import com.aurora.store.Constants;
import com.aurora.store.ErrorType;
import com.aurora.store.ListType;
import com.aurora.store.R;
import com.aurora.store.activity.AuroraActivity;
import com.aurora.store.adapter.InstalledAppsAdapter;
import com.aurora.store.task.InstalledAppsTask;
import com.aurora.store.utility.Log;
import com.aurora.store.utility.PrefUtil;
import com.aurora.store.utility.ViewUtil;
import com.aurora.store.view.CustomSwipeToRefresh;
import com.google.android.material.bottomnavigation.BottomNavigationView;
import com.google.android.material.switchmaterial.SwitchMaterial;
import org.jetbrains.annotations.NotNull;
@@ -58,14 +55,13 @@ import io.reactivex.schedulers.Schedulers;
public class InstalledFragment extends BaseFragment {
@BindView(R.id.swipe_layout)
CustomSwipeToRefresh mSwipeRefreshLayout;
CustomSwipeToRefresh customSwipeToRefresh;
@BindView(R.id.recycler)
RecyclerView recyclerView;
@BindView(R.id.switch_system)
SwitchMaterial switchSystem;
private Context context;
private BottomNavigationView bottomNavigationView;
private View view;
private InstalledAppsAdapter adapter;
private InstalledAppsTask installedAppTask;
@@ -98,19 +94,14 @@ public class InstalledFragment extends BaseFragment {
fetchData();
});
mSwipeRefreshLayout.setOnRefreshListener(() -> fetchData());
if (getActivity() instanceof AuroraActivity) {
bottomNavigationView = ((AuroraActivity) getActivity()).getBottomNavigation();
setBaseBottomNavigationView(bottomNavigationView);
}
customSwipeToRefresh.setOnRefreshListener(() -> fetchData());
setupRecycler();
}
@Override
public void onPause() {
super.onPause();
mSwipeRefreshLayout.setRefreshing(false);
customSwipeToRefresh.setRefreshing(false);
}
@Override
@@ -134,8 +125,8 @@ public class InstalledFragment extends BaseFragment {
.getInstalledApps(switchSystem.isChecked()))
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.doOnSubscribe(subscription -> mSwipeRefreshLayout.setRefreshing(true))
.doOnTerminate(() -> mSwipeRefreshLayout.setRefreshing(false))
.doOnSubscribe(subscription -> customSwipeToRefresh.setRefreshing(true))
.doOnTerminate(() -> customSwipeToRefresh.setRefreshing(false))
.subscribe((appList) -> {
if (view != null) {
if (appList.isEmpty()) {
@@ -158,19 +149,6 @@ public class InstalledFragment extends BaseFragment {
recyclerView.setAdapter(adapter);
recyclerView.setLayoutManager(new LinearLayoutManager(context, RecyclerView.VERTICAL, false));
recyclerView.setLayoutAnimation(AnimationUtils.loadLayoutAnimation(context, R.anim.anim_falldown));
recyclerView.setOnFlingListener(new RecyclerView.OnFlingListener() {
@Override
public boolean onFling(int velocityX, int velocityY) {
if (velocityY < 0) {
if (bottomNavigationView != null)
ViewUtil.showBottomNav(bottomNavigationView, true);
} else if (velocityY > 0) {
if (bottomNavigationView != null)
ViewUtil.hideBottomNav(bottomNavigationView, true);
}
return false;
}
});
}
@Override

View File

@@ -45,6 +45,7 @@ import com.aurora.store.task.CategoryAppsTask;
import com.aurora.store.utility.ContextUtil;
import com.dragons.aurora.playstoreapiv2.GooglePlayAPI;
import com.dragons.aurora.playstoreapiv2.IteratorGooglePlayException;
import com.google.android.material.floatingactionbutton.ExtendedFloatingActionButton;
import com.google.android.material.floatingactionbutton.FloatingActionButton;
import java.util.List;
@@ -61,7 +62,7 @@ public class TopFreeApps extends BaseFragment {
@BindView(R.id.endless_apps_list)
RecyclerView recyclerView;
private Context context;
private FloatingActionButton filterFab;
private ExtendedFloatingActionButton filterFab;
private EndlessAppsAdapter endlessAppsAdapter;
public CustomAppListIterator getIterator() {

View File

@@ -37,7 +37,6 @@ import androidx.recyclerview.widget.RecyclerView;
import com.aurora.store.ErrorType;
import com.aurora.store.R;
import com.aurora.store.activity.AuroraActivity;
import com.aurora.store.adapter.UpdatableAppsAdapter;
import com.aurora.store.download.DownloadManager;
import com.aurora.store.exception.MalformedRequestException;
@@ -50,7 +49,6 @@ import com.aurora.store.utility.ContextUtil;
import com.aurora.store.utility.Log;
import com.aurora.store.utility.ViewUtil;
import com.aurora.store.view.CustomSwipeToRefresh;
import com.google.android.material.bottomnavigation.BottomNavigationView;
import com.google.android.material.snackbar.Snackbar;
import com.tonyodev.fetch2.Fetch;
@@ -80,7 +78,6 @@ public class UpdatesFragment extends BaseFragment {
TextView txtUpdateAll;
private Context context;
private BottomNavigationView bottomNavigationView;
private View view;
private List<App> updatableAppList = new ArrayList<>();
private UpdatableAppsAdapter adapter;
@@ -110,10 +107,6 @@ public class UpdatesFragment extends BaseFragment {
updatableAppTask = new UpdatableAppsTask(context);
setErrorView(ErrorType.UNKNOWN);
customSwipeToRefresh.setOnRefreshListener(() -> fetchData());
if (getActivity() instanceof AuroraActivity) {
bottomNavigationView = ((AuroraActivity) getActivity()).getBottomNavigation();
setBaseBottomNavigationView(bottomNavigationView);
}
setupRecycler();
}
@@ -168,19 +161,6 @@ public class UpdatesFragment extends BaseFragment {
recyclerView.setAdapter(adapter);
recyclerView.setLayoutManager(new LinearLayoutManager(context, RecyclerView.VERTICAL, false));
recyclerView.setLayoutAnimation(AnimationUtils.loadLayoutAnimation(context, R.anim.anim_falldown));
recyclerView.setOnFlingListener(new RecyclerView.OnFlingListener() {
@Override
public boolean onFling(int velocityX, int velocityY) {
if (velocityY < 0) {
if (bottomNavigationView != null)
ViewUtil.showBottomNav(bottomNavigationView, true);
} else if (velocityY > 0) {
if (bottomNavigationView != null)
ViewUtil.hideBottomNav(bottomNavigationView, true);
}
return false;
}
});
}
@Override
@@ -245,7 +225,7 @@ public class UpdatesFragment extends BaseFragment {
.doOnError(throwable -> {
if (throwable instanceof MalformedRequestException) {
ContextUtil.runOnUiThread(() -> btnUpdateAll.setOnClickListener(updateAllListener()));
notifyStatusBlacklist(coordinatorLayout, bottomNavigationView, throwable.getMessage());
notifyStatusBlacklist(coordinatorLayout, null, throwable.getMessage());
} else
Log.e(throwable.getMessage());
})

View File

@@ -31,22 +31,17 @@
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior">
<View
android:id="@+id/gradient_view"
android:layout_width="match_parent"
android:layout_height="32dp"
android:background="@drawable/gradient_bg"
android:translationZ="10dp" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/category_recycler"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false"
android:nestedScrollingEnabled="false"
android:overScrollMode="never"
android:paddingTop="@dimen/margin_small"
android:paddingBottom="@dimen/bottom_nav_padding"
android:scrollbars="none"
android:splitMotionEvents="false"
tools:listitem="@layout/item_category_list" />
</FrameLayout>
</androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@@ -51,15 +51,18 @@
android:layout_height="match_parent" />
</LinearLayout>
<com.google.android.material.floatingactionbutton.FloatingActionButton
<com.google.android.material.floatingactionbutton.ExtendedFloatingActionButton
android:id="@+id/filter_fab"
style="@style/Widget.MaterialComponents.FloatingActionButton"
style="@style/Widget.MaterialComponents.ExtendedFloatingActionButton.Icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="end|bottom"
android:layout_gravity="center_horizontal|bottom"
android:layout_margin="@dimen/margin_normal"
app:fabSize="auto"
app:layout_anchorGravity="top|end"
app:srcCompat="@drawable/ic_filter" />
android:text="@string/action_filter"
android:textAppearance="@style/TextAppearance.Aurora.Button"
android:textColor="@color/colorWhite"
app:backgroundTint="@color/colorAccent"
app:icon="@drawable/ic_filter"
app:iconTint="@color/colorWhite" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@@ -54,18 +54,10 @@
android:layout_height="match_parent"
android:orientation="vertical">
<View
android:id="@+id/gradient_view"
android:layout_width="match_parent"
android:layout_height="32dp"
android:background="@drawable/gradient_bg"
android:translationZ="10dp" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/search_apps_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="-32dp"
android:clipToPadding="false"
android:paddingTop="@dimen/margin_small"
android:scrollbarStyle="outsideOverlay"

View File

@@ -30,208 +30,199 @@
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
<androidx.core.widget.NestedScrollView
android:id="@+id/content_view"
android:layout_width="match_parent"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
android:clipToPadding="false"
android:overScrollMode="never"
android:paddingTop="@dimen/margin_small"
android:paddingBottom="@dimen/bottom_nav_padding"
android:scrollbars="none">
<View
android:id="@+id/gradient_view"
<LinearLayout
android:layout_width="match_parent"
android:layout_height="32dp"
android:background="@drawable/gradient_bg"
android:translationZ="10dp" />
<androidx.core.widget.NestedScrollView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="-32dp"
android:clipToPadding="false"
android:paddingTop="@dimen/margin_normal"
android:paddingBottom="@dimen/bottom_nav_padding"
android:scrollbars="none">
android:orientation="vertical">
<LinearLayout
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
android:layout_height="wrap_content">
<RelativeLayout
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/txt_top_categories"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBaseline="@id/btn_all_categories"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/btn_all_categories"
android:ellipsize="end"
android:maxLines="1"
android:paddingStart="@dimen/margin_medium"
android:paddingEnd="@dimen/margin_xxsmall"
android:text="@string/cat_top_categories"
android:textAppearance="@style/TextAppearance.Aurora.Header" />
<com.google.android.material.button.MaterialButton
android:id="@+id/btn_all_categories"
style="@style/Widget.MaterialComponents.Button.TextButton.Dialog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:maxLines="1"
android:text="@string/action_filter_all"
android:textAllCaps="false"
app:rippleColor="@color/colorScrimAccent" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_top_categories"
android:layout_width="match_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:layout_below="@id/btn_all_categories"
android:clipToPadding="false"
android:orientation="horizontal"
android:paddingStart="@dimen/margin_small"
android:splitMotionEvents="false"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tool:listitem="@layout/item_category_top" />
</RelativeLayout>
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/txt_top_categories"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBaseline="@id/btn_all_categories"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/btn_all_categories"
android:ellipsize="end"
android:maxLines="1"
android:paddingStart="@dimen/margin_medium"
android:paddingEnd="@dimen/margin_xxsmall"
android:text="@string/cat_top_categories"
android:textAppearance="@style/TextAppearance.Aurora.Header" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<com.google.android.material.button.MaterialButton
android:id="@+id/btn_all_categories"
style="@style/Widget.MaterialComponents.Button.TextButton.Dialog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:maxLines="1"
android:text="@string/action_filter_all"
android:textAllCaps="false"
app:rippleColor="@color/colorScrimAccent" />
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/top_apps_name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBaseline="@id/btn_top_apps"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/btn_top_apps"
android:ellipsize="end"
android:maxLines="1"
android:paddingStart="@dimen/margin_medium"
android:paddingEnd="@dimen/margin_xxsmall"
android:text="@string/cat_top_apps"
android:textAppearance="@style/TextAppearance.Aurora.Header" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_top_categories"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/btn_all_categories"
android:clipToPadding="false"
android:orientation="horizontal"
android:paddingStart="@dimen/margin_small"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tool:listitem="@layout/item_category_top" />
</RelativeLayout>
<com.google.android.material.button.MaterialButton
android:id="@+id/btn_top_apps"
style="@style/Widget.MaterialComponents.Button.TextButton.Dialog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:maxLines="1"
android:text="@string/action_more"
android:textAllCaps="false"
app:rippleColor="@color/colorScrimAccent" />
<RelativeLayout
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_top_apps"
android:layout_width="match_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:layout_below="@id/btn_top_apps"
android:clipToPadding="false"
android:orientation="horizontal"
android:paddingStart="@dimen/margin_small"
android:splitMotionEvents="false"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tool:listitem="@layout/item_featured" />
</RelativeLayout>
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/top_apps_name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBaseline="@id/btn_top_apps"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/btn_top_apps"
android:ellipsize="end"
android:maxLines="1"
android:paddingStart="@dimen/margin_medium"
android:paddingEnd="@dimen/margin_xxsmall"
android:text="@string/cat_top_apps"
android:textAppearance="@style/TextAppearance.Aurora.Header" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<com.google.android.material.button.MaterialButton
android:id="@+id/btn_top_apps"
style="@style/Widget.MaterialComponents.Button.TextButton.Dialog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:maxLines="1"
android:text="@string/action_more"
android:textAllCaps="false"
app:rippleColor="@color/colorScrimAccent" />
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/top_apps_games"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBaseline="@id/btn_top_games"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/btn_top_games"
android:ellipsize="end"
android:maxLines="1"
android:paddingStart="@dimen/margin_medium"
android:paddingEnd="@dimen/margin_xxsmall"
android:text="@string/cat_top_games"
android:textAppearance="@style/TextAppearance.Aurora.Header" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_top_apps"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/btn_top_apps"
android:clipToPadding="false"
android:orientation="horizontal"
android:paddingStart="@dimen/margin_small"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tool:listitem="@layout/item_featured" />
</RelativeLayout>
<com.google.android.material.button.MaterialButton
android:id="@+id/btn_top_games"
style="@style/Widget.MaterialComponents.Button.TextButton.Dialog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:maxLines="1"
android:text="@string/action_more"
android:textAllCaps="false"
app:rippleColor="@color/colorScrimAccent" />
<RelativeLayout
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_top_games"
android:layout_width="match_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:layout_below="@id/btn_top_games"
android:clipToPadding="false"
android:orientation="horizontal"
android:paddingStart="@dimen/margin_small"
android:splitMotionEvents="false"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tool:listitem="@layout/item_featured" />
</RelativeLayout>
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/top_apps_games"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBaseline="@id/btn_top_games"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/btn_top_games"
android:ellipsize="end"
android:maxLines="1"
android:paddingStart="@dimen/margin_medium"
android:paddingEnd="@dimen/margin_xxsmall"
android:text="@string/cat_top_games"
android:textAppearance="@style/TextAppearance.Aurora.Header" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<com.google.android.material.button.MaterialButton
android:id="@+id/btn_top_games"
style="@style/Widget.MaterialComponents.Button.TextButton.Dialog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:maxLines="1"
android:text="@string/action_more"
android:textAllCaps="false"
app:rippleColor="@color/colorScrimAccent" />
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/top_apps_family"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBaseline="@id/btn_top_family"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/btn_top_family"
android:ellipsize="end"
android:maxLines="1"
android:paddingStart="@dimen/margin_medium"
android:paddingEnd="@dimen/margin_xxsmall"
android:text="@string/cat_top_family"
android:textAppearance="@style/TextAppearance.Aurora.Header" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_top_games"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/btn_top_games"
android:clipToPadding="false"
android:orientation="horizontal"
android:paddingStart="@dimen/margin_small"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tool:listitem="@layout/item_featured" />
</RelativeLayout>
<com.google.android.material.button.MaterialButton
android:id="@+id/btn_top_family"
style="@style/Widget.MaterialComponents.Button.TextButton.Dialog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:maxLines="1"
android:text="@string/action_more"
android:textAllCaps="false"
app:rippleColor="@color/colorScrimAccent" />
<RelativeLayout
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_top_family"
android:layout_width="match_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:layout_below="@id/btn_top_family"
android:clipToPadding="false"
android:orientation="horizontal"
android:paddingStart="@dimen/margin_small"
android:splitMotionEvents="false"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tool:listitem="@layout/item_featured" />
</RelativeLayout>
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/top_apps_family"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBaseline="@id/btn_top_family"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/btn_top_family"
android:ellipsize="end"
android:maxLines="1"
android:paddingStart="@dimen/margin_medium"
android:paddingEnd="@dimen/margin_xxsmall"
android:text="@string/cat_top_family"
android:textAppearance="@style/TextAppearance.Aurora.Header" />
<com.google.android.material.button.MaterialButton
android:id="@+id/btn_top_family"
style="@style/Widget.MaterialComponents.Button.TextButton.Dialog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
android:maxLines="1"
android:text="@string/action_more"
android:textAllCaps="false"
app:rippleColor="@color/colorScrimAccent" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_top_family"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/btn_top_family"
android:clipToPadding="false"
android:orientation="horizontal"
android:paddingStart="@dimen/margin_small"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tool:listitem="@layout/item_featured" />
</RelativeLayout>
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</LinearLayout>
</LinearLayout>
</androidx.core.widget.NestedScrollView>
<LinearLayout
android:id="@+id/err_view"

View File

@@ -51,27 +51,21 @@
app:autoSizeTextType="uniform"
app:useMaterialThemeColors="false" />
<View
android:id="@+id/gradient_view"
android:layout_width="match_parent"
android:layout_height="32dp"
android:background="@drawable/gradient_bg"
android:translationZ="10dp" />
<com.aurora.store.view.CustomSwipeToRefresh
android:id="@+id/swipe_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="-32dp"
android:clipToPadding="false">
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false"
android:overScrollMode="never"
android:paddingTop="@dimen/margin_small"
android:paddingBottom="@dimen/margin_bottom"
android:scrollbars="vertical"
android:splitMotionEvents="false"
tools:listitem="@layout/item_installed" />
<androidx.appcompat.widget.AppCompatTextView
@@ -79,7 +73,6 @@
android:layout_height="wrap_content"
android:gravity="center"
android:textAppearance="?android:attr/textAppearanceLarge" />
</com.aurora.store.view.CustomSwipeToRefresh>
</LinearLayout>

View File

@@ -100,12 +100,11 @@
android:layout_gravity="center_horizontal|bottom"
android:layout_marginEnd="@dimen/margin_normal"
android:layout_marginBottom="@dimen/margin_bottom"
android:text="Filter"
android:text="@string/action_filter"
android:textAppearance="@style/TextAppearance.Aurora.Button"
android:textColor="@color/colorWhite"
android:visibility="gone"
app:backgroundTint="@color/colorAccent"
app:icon="@drawable/ic_filter"
app:iconTint="@color/colorWhite"
app:layout_anchorGravity="top|end" />
app:iconTint="@color/colorWhite" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@@ -68,30 +68,23 @@
android:layout_marginEnd="@dimen/margin_small"
android:maxLines="1"
android:text="@string/list_update_all" />
</RelativeLayout>
<View
android:id="@+id/gradient_view"
android:layout_width="match_parent"
android:layout_height="32dp"
android:background="@drawable/gradient_bg"
android:translationZ="10dp" />
<com.aurora.store.view.CustomSwipeToRefresh
android:id="@+id/swipe_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="-32dp"
android:clipToPadding="false">
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false"
android:overScrollMode="never"
android:paddingTop="@dimen/margin_small"
android:paddingBottom="@dimen/margin_bottom"
android:scrollbars="vertical"
android:splitMotionEvents="false"
tools:listitem="@layout/item_updatable" />
<androidx.appcompat.widget.AppCompatTextView
@@ -99,7 +92,6 @@
android:layout_height="wrap_content"
android:gravity="center"
android:textAppearance="?android:attr/textAppearanceLarge" />
</com.aurora.store.view.CustomSwipeToRefresh>
</LinearLayout>
@@ -109,5 +101,4 @@
android:layout_height="match_parent"
android:orientation="vertical" />
</ViewSwitcher>
</androidx.coordinatorlayout.widget.CoordinatorLayout>