Fix issue #1130 - Use Pixelfed layout

This commit is contained in:
Thomas 2025-03-01 16:23:07 +01:00
parent e0b8b60fed
commit c6494d7e04
2 changed files with 5 additions and 2 deletions

View file

@ -3117,7 +3117,8 @@ public class StatusAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
} else { } else {
if (isVisible(timelineType, statusList.get(position), statusList)) { if (isVisible(timelineType, statusList.get(position), statusList)) {
if (visiblePixelfed && isVisiblePixelfed(statusList.get(position)) && timelineType != Timeline.TimeLineEnum.UNKNOWN) { if (visiblePixelfed && isVisiblePixelfed(statusList.get(position)) && timelineType != Timeline.TimeLineEnum.UNKNOWN) {
return STATUS_PIXELFED;
} else if(timelineType == Timeline.TimeLineEnum.REMOTE && pinnedTimeline != null && pinnedTimeline.remoteInstance != null && pinnedTimeline.remoteInstance.type == RemoteInstance.InstanceType.PIXELFED){
return STATUS_PIXELFED; return STATUS_PIXELFED;
}else { }else {
if(timelineType != Timeline.TimeLineEnum.UNKNOWN && getCurrentAccount(context).software != null && getCurrentAccount(context).software.trim().toLowerCase().equals("pixelfed")) { if(timelineType != Timeline.TimeLineEnum.UNKNOWN && getCurrentAccount(context).software != null && getCurrentAccount(context).software.trim().toLowerCase().equals("pixelfed")) {

View file

@ -1131,6 +1131,8 @@ public class FragmentMastodonTimeline extends Fragment implements StatusAdapter.
if (direction == null) { if (direction == null) {
timelinesVM.getPixelfedDiscoverTrending(remoteInstance) timelinesVM.getPixelfedDiscoverTrending(remoteInstance)
.observe(getViewLifecycleOwner(), this::initializeStatusesCommonView); .observe(getViewLifecycleOwner(), this::initializeStatusesCommonView);
} else {
binding.swipeContainer.setRefreshing(false);
} }
}else { //Other remote timelines }else { //Other remote timelines
routeCommon(direction, fetchingMissing, fetchStatus); routeCommon(direction, fetchingMissing, fetchStatus);