mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-11 18:29:05 +01:00
Remember when declines were automatic due to deletion
so they can be shown differently for sender
This commit is contained in:
@@ -15,7 +15,7 @@ public class BlogInvitationResponse extends InvitationResponse {
|
||||
SessionId sessionId, boolean accept, GroupId shareableId,
|
||||
long autoDeleteTimer) {
|
||||
super(id, groupId, time, local, read, sent, seen, sessionId,
|
||||
accept, shareableId, autoDeleteTimer);
|
||||
accept, shareableId, autoDeleteTimer, false);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -12,14 +12,16 @@ import javax.annotation.concurrent.Immutable;
|
||||
public abstract class ConversationResponse extends ConversationMessageHeader {
|
||||
|
||||
private final SessionId sessionId;
|
||||
private final boolean accepted;
|
||||
private final boolean accepted, isAutoDecline;
|
||||
|
||||
public ConversationResponse(MessageId id, GroupId groupId, long time,
|
||||
boolean local, boolean read, boolean sent, boolean seen,
|
||||
SessionId sessionId, boolean accepted, long autoDeleteTimer) {
|
||||
SessionId sessionId, boolean accepted, long autoDeleteTimer,
|
||||
boolean isAutoDecline) {
|
||||
super(id, groupId, time, local, read, sent, seen, autoDeleteTimer);
|
||||
this.sessionId = sessionId;
|
||||
this.accepted = accepted;
|
||||
this.isAutoDecline = isAutoDecline;
|
||||
}
|
||||
|
||||
public SessionId getSessionId() {
|
||||
@@ -30,4 +32,7 @@ public abstract class ConversationResponse extends ConversationMessageHeader {
|
||||
return accepted;
|
||||
}
|
||||
|
||||
public boolean isAutoDecline() {
|
||||
return isAutoDecline;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ public class ForumInvitationResponse extends InvitationResponse {
|
||||
SessionId sessionId, boolean accept, GroupId shareableId,
|
||||
long autoDeleteTimer) {
|
||||
super(id, groupId, time, local, read, sent, seen, sessionId,
|
||||
accept, shareableId, autoDeleteTimer);
|
||||
accept, shareableId, autoDeleteTimer, false);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
package org.briarproject.briar.api.introduction;
|
||||
|
||||
import org.briarproject.bramble.api.identity.Author;
|
||||
import org.briarproject.briar.api.identity.AuthorInfo;
|
||||
import org.briarproject.bramble.api.nullsafety.NotNullByDefault;
|
||||
import org.briarproject.bramble.api.sync.GroupId;
|
||||
import org.briarproject.bramble.api.sync.MessageId;
|
||||
import org.briarproject.briar.api.client.SessionId;
|
||||
import org.briarproject.briar.api.conversation.ConversationMessageVisitor;
|
||||
import org.briarproject.briar.api.conversation.ConversationResponse;
|
||||
import org.briarproject.briar.api.identity.AuthorInfo;
|
||||
|
||||
import javax.annotation.concurrent.Immutable;
|
||||
|
||||
@@ -28,7 +28,7 @@ public class IntroductionResponse extends ConversationResponse {
|
||||
AuthorInfo introducedAuthorInfo, Role role, boolean canSucceed,
|
||||
long autoDeleteTimer) {
|
||||
super(messageId, groupId, time, local, read, sent, seen, sessionId,
|
||||
accepted, autoDeleteTimer);
|
||||
accepted, autoDeleteTimer, false);
|
||||
this.introducedAuthor = author;
|
||||
this.introducedAuthorInfo = introducedAuthorInfo;
|
||||
this.ourRole = role;
|
||||
|
||||
@@ -16,9 +16,9 @@ public class GroupInvitationResponse extends InvitationResponse {
|
||||
public GroupInvitationResponse(MessageId id, GroupId groupId, long time,
|
||||
boolean local, boolean read, boolean sent, boolean seen,
|
||||
SessionId sessionId, boolean accept, GroupId shareableId,
|
||||
long autoDeleteTimer) {
|
||||
long autoDeleteTimer, boolean isAutoDecline) {
|
||||
super(id, groupId, time, local, read, sent, seen, sessionId,
|
||||
accept, shareableId, autoDeleteTimer);
|
||||
accept, shareableId, autoDeleteTimer, isAutoDecline);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -12,9 +12,9 @@ public abstract class InvitationResponse extends ConversationResponse {
|
||||
public InvitationResponse(MessageId id, GroupId groupId, long time,
|
||||
boolean local, boolean read, boolean sent, boolean seen,
|
||||
SessionId sessionId, boolean accepted, GroupId shareableId,
|
||||
long autoDeleteTimer) {
|
||||
long autoDeleteTimer, boolean isAutoDecline) {
|
||||
super(id, groupId, time, local, read, sent, seen, sessionId, accepted,
|
||||
autoDeleteTimer);
|
||||
autoDeleteTimer, isAutoDecline);
|
||||
this.shareableId = shareableId;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user