Android: per-bookmark "Show whisper controls", off by default
Whispering can't be gated on permissions: our i_client_whisper_power is never reported (and guests may not permget it), and whether a whisper gets through depends on the target's needed whisper power, which clients can't see. So the whisper menu and the Whisper / Add to whisper list actions are shown only for servers connected from a bookmark that asks for them; an edit of that bookmark applies without reconnecting. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -26,6 +26,8 @@ public final class Bookmark {
|
||||
public boolean connectOnStartup = false;
|
||||
/** TeamSpeak's "Enable myTeamSpeak features" ({@code Bookmark_Data.send_mytsid_on_server}). */
|
||||
public boolean myTeamSpeakFeatures = true;
|
||||
/** Offer whispering in this server's menus. */
|
||||
public boolean showWhisperControls = false;
|
||||
/** The server's icon as last seen there, 0 for none or not yet known. */
|
||||
public long iconId = 0;
|
||||
|
||||
@@ -49,6 +51,7 @@ public final class Bookmark {
|
||||
b.channelPassword = channelPassword;
|
||||
b.connectOnStartup = connectOnStartup;
|
||||
b.myTeamSpeakFeatures = myTeamSpeakFeatures;
|
||||
b.showWhisperControls = showWhisperControls;
|
||||
b.iconId = iconId;
|
||||
return b;
|
||||
}
|
||||
|
||||
@@ -89,6 +89,7 @@ public final class Bookmarks {
|
||||
bm.channelPassword = p.getProperty(prefix + "channelPassword", "");
|
||||
bm.connectOnStartup = Boolean.parseBoolean(p.getProperty(prefix + "connectOnStartup", "false"));
|
||||
bm.myTeamSpeakFeatures = Boolean.parseBoolean(p.getProperty(prefix + "myTeamSpeakFeatures", "true"));
|
||||
bm.showWhisperControls = Boolean.parseBoolean(p.getProperty(prefix + "showWhisperControls", "false"));
|
||||
bm.iconId = parseLong(p.getProperty(prefix + "iconId"));
|
||||
if (bm.address != null && !bm.address.isBlank()) b.entries.add(bm);
|
||||
}
|
||||
@@ -112,6 +113,7 @@ public final class Bookmarks {
|
||||
p.setProperty(prefix + "channelPassword", nullToEmpty(bm.channelPassword));
|
||||
p.setProperty(prefix + "connectOnStartup", Boolean.toString(bm.connectOnStartup));
|
||||
p.setProperty(prefix + "myTeamSpeakFeatures", Boolean.toString(bm.myTeamSpeakFeatures));
|
||||
p.setProperty(prefix + "showWhisperControls", Boolean.toString(bm.showWhisperControls));
|
||||
p.setProperty(prefix + "iconId", Long.toString(bm.iconId));
|
||||
}
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user