query notifications on load posts
closes sk22#471
This commit is contained in:
@@ -298,9 +298,6 @@ public class HomeFragment extends AppKitFragment implements OnBackPressedListene
|
|||||||
try {
|
try {
|
||||||
long newestId = Long.parseLong(notifications.get(0).id);
|
long newestId = Long.parseLong(notifications.get(0).id);
|
||||||
long lastSeenId = Long.parseLong(session.markers.notifications.lastReadId);
|
long lastSeenId = Long.parseLong(session.markers.notifications.lastReadId);
|
||||||
System.out.println("NEWEST: " + newestId);
|
|
||||||
System.out.println("LAST SEEN: " + lastSeenId);
|
|
||||||
|
|
||||||
setNotificationBadge(newestId > lastSeenId);
|
setNotificationBadge(newestId > lastSeenId);
|
||||||
} catch (Exception ignored) {
|
} catch (Exception ignored) {
|
||||||
setNotificationBadge(false);
|
setNotificationBadge(false);
|
||||||
|
|||||||
@@ -166,6 +166,10 @@ public class HomeTimelineFragment extends StatusListFragment {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
.exec(accountID);
|
.exec(accountID);
|
||||||
|
|
||||||
|
if (parent.getParentFragment() instanceof HomeFragment homeFragment) {
|
||||||
|
homeFragment.updateNotificationBadge();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in New Issue
Block a user