mirror of
https://github.com/kiwix/kiwix-android.git
synced 2025-09-10 07:48:30 -04:00
stop refreshing when no items exist
This commit is contained in:
parent
5602c3d9e6
commit
02dbea72d7
@ -30,7 +30,6 @@
|
|||||||
android:label="@string/app_name">
|
android:label="@string/app_name">
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="android.intent.action.MAIN" />
|
<action android:name="android.intent.action.MAIN" />
|
||||||
|
|
||||||
<category android:name="android.intent.category.LAUNCHER" />
|
<category android:name="android.intent.category.LAUNCHER" />
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
</activity>
|
</activity>
|
||||||
|
@ -114,10 +114,11 @@ public class LibraryFragment extends Fragment
|
|||||||
|
|
||||||
setupDagger();
|
setupDagger();
|
||||||
TestingUtils.bindResource(LibraryFragment.class);
|
TestingUtils.bindResource(LibraryFragment.class);
|
||||||
|
llLayout = (LinearLayout) inflater.inflate(R.layout.activity_library, container, false);
|
||||||
ButterKnife.bind(this, llLayout);
|
ButterKnife.bind(this, llLayout);
|
||||||
presenter.attachView(this);
|
presenter.attachView(this);
|
||||||
|
|
||||||
faActivity = (ZimManageActivity) super.getActivity();
|
faActivity = (ZimManageActivity) super.getActivity();
|
||||||
llLayout = (LinearLayout) inflater.inflate(R.layout.activity_library, container, false);
|
|
||||||
swipeRefreshLayout.setOnRefreshListener(() -> refreshFragment());
|
swipeRefreshLayout.setOnRefreshListener(() -> refreshFragment());
|
||||||
libraryAdapter = new LibraryAdapter(super.getContext());
|
libraryAdapter = new LibraryAdapter(super.getContext());
|
||||||
libraryList.setAdapter(libraryAdapter);
|
libraryList.setAdapter(libraryAdapter);
|
||||||
@ -169,6 +170,7 @@ public class LibraryFragment extends Fragment
|
|||||||
networkText.setText(R.string.no_items_msg);
|
networkText.setText(R.string.no_items_msg);
|
||||||
networkText.setVisibility(View.VISIBLE);
|
networkText.setVisibility(View.VISIBLE);
|
||||||
permissionButton.setVisibility(GONE);
|
permissionButton.setVisibility(GONE);
|
||||||
|
swipeRefreshLayout.setRefreshing(false);
|
||||||
TestingUtils.unbindResource(LibraryFragment.class);
|
TestingUtils.unbindResource(LibraryFragment.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user