Grouped notifications

This commit is contained in:
Grishka
2024-09-20 11:38:52 +03:00
parent 80323f8236
commit 26f7a75628
23 changed files with 758 additions and 251 deletions

View File

@@ -23,6 +23,7 @@ import org.joinmastodon.android.api.session.AccountSession;
import org.joinmastodon.android.api.session.AccountSessionManager;
import org.joinmastodon.android.model.Account;
import org.joinmastodon.android.model.Mention;
import org.joinmastodon.android.model.NotificationType;
import org.joinmastodon.android.model.PushNotification;
import org.joinmastodon.android.model.StatusPrivacy;
import org.joinmastodon.android.ui.utils.UiUtils;
@@ -183,7 +184,7 @@ public class PushNotificationReceiver extends BroadcastReceiver{
builder.setSubText(accountName);
}
String notificationTag=accountID+"_"+(notification==null ? 0 : notification.id);
if(notification!=null && (notification.type==org.joinmastodon.android.model.Notification.Type.MENTION)){
if(notification!=null && (notification.type==NotificationType.MENTION)){
ArrayList<String> mentions=new ArrayList<>();
String ownID=AccountSessionManager.getInstance().getAccount(accountID).self.id;
if(!notification.status.account.id.equals(ownID))