mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-13 03:09:04 +01:00
Add visibility and OPTIONS button to private group join notices
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
package org.briarproject.android.privategroup;
|
||||
|
||||
import android.support.annotation.StringRes;
|
||||
|
||||
import org.briarproject.R;
|
||||
import org.briarproject.api.privategroup.Visibility;
|
||||
|
||||
public class VisibilityStringProvider {
|
||||
|
||||
@StringRes
|
||||
public static int getVisibilityString(Visibility v) {
|
||||
switch (v) {
|
||||
case VISIBLE:
|
||||
return R.string.groups_reveal_visible;
|
||||
case REVEALED_BY_US:
|
||||
return R.string.groups_reveal_visible_revealed_by_us;
|
||||
case REVEALED_BY_CONTACT:
|
||||
return R.string.groups_reveal_visible_revealed_by_contact;
|
||||
case INVISIBLE:
|
||||
return R.string.groups_reveal_invisible;
|
||||
default:
|
||||
throw new IllegalArgumentException("Unknown visibility");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user