mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-14 19:59:05 +01:00
Don't use messaging group ID as proxy for contact ID.
This commit is contained in:
@@ -7,10 +7,7 @@ import android.support.annotation.UiThread;
|
||||
import org.briarproject.R;
|
||||
import org.briarproject.android.BriarActivity;
|
||||
import org.briarproject.android.fragment.BaseFragment.BaseFragmentListener;
|
||||
import org.briarproject.api.contact.Contact;
|
||||
import org.briarproject.api.contact.ContactId;
|
||||
import org.briarproject.api.db.DatabaseExecutor;
|
||||
import org.briarproject.api.db.DbException;
|
||||
import org.briarproject.api.sync.GroupId;
|
||||
|
||||
import java.util.ArrayList;
|
||||
@@ -58,10 +55,6 @@ public abstract class ContactSelectorActivity extends BriarActivity implements
|
||||
this.contacts = contacts;
|
||||
}
|
||||
|
||||
@DatabaseExecutor
|
||||
public abstract boolean isDisabled(GroupId groupId, Contact c)
|
||||
throws DbException;
|
||||
|
||||
static ArrayList<Integer> getContactsFromIds(
|
||||
Collection<ContactId> contacts) {
|
||||
// transform ContactIds to Integers so they can be added to a bundle
|
||||
|
||||
@@ -11,7 +11,7 @@ import org.briarproject.api.sync.GroupId;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
public interface ContactSelectorListener extends DestroyableContext {
|
||||
interface ContactSelectorListener extends DestroyableContext {
|
||||
|
||||
@Deprecated
|
||||
void runOnDbThread(Runnable runnable);
|
||||
|
||||
@@ -8,26 +8,26 @@ import javax.annotation.concurrent.NotThreadSafe;
|
||||
|
||||
@NotThreadSafe
|
||||
@NotNullByDefault
|
||||
public class SelectableContactItem extends ContactItem {
|
||||
class SelectableContactItem extends ContactItem {
|
||||
|
||||
private boolean selected, disabled;
|
||||
|
||||
public SelectableContactItem(Contact contact, boolean connected,
|
||||
SelectableContactItem(Contact contact, boolean connected,
|
||||
boolean selected, boolean disabled) {
|
||||
super(contact, connected);
|
||||
this.selected = selected;
|
||||
this.disabled = disabled;
|
||||
}
|
||||
|
||||
public boolean isSelected() {
|
||||
boolean isSelected() {
|
||||
return selected;
|
||||
}
|
||||
|
||||
public void toggleSelected() {
|
||||
void toggleSelected() {
|
||||
selected = !selected;
|
||||
}
|
||||
|
||||
public boolean isDisabled() {
|
||||
boolean isDisabled() {
|
||||
return disabled;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user