Do not let magisk hide's apps list blink

This commit is contained in:
tonymanou 2017-01-08 17:59:35 +01:00 committed by topjohnwu
parent c1e7d74b96
commit 0b59bb1a29

View File

@ -55,10 +55,7 @@ public class MagiskHideFragment extends Fragment implements CallbackHandler.Even
PackageManager packageManager = getActivity().getPackageManager();
mSwipeRefreshLayout.setRefreshing(true);
mSwipeRefreshLayout.setOnRefreshListener(() -> {
recyclerView.setVisibility(View.GONE);
new Async.LoadApps(packageManager).exec();
});
mSwipeRefreshLayout.setOnRefreshListener(() -> new Async.LoadApps(packageManager).exec());
appAdapter = new ApplicationAdapter(packageManager);
recyclerView.setAdapter(appAdapter);
@ -111,7 +108,6 @@ public class MagiskHideFragment extends Fragment implements CallbackHandler.Even
Logger.dev("MagiskHideFragment: UI refresh");
Async.LoadApps.Result result = (Async.LoadApps.Result) event.getResult();
appAdapter.setLists(result.listApps, result.hideList);
recyclerView.setVisibility(View.VISIBLE);
mSwipeRefreshLayout.setRefreshing(false);
if (!TextUtils.isEmpty(lastFilter)) {
appAdapter.filter(lastFilter);