kopia lustrzana https://github.com/ryukoposting/Signal-Android
Remove Universal Expire Timer flag and fix bug with SMS.
rodzic
5e3bbb0e64
commit
b6c653ff77
|
@ -138,7 +138,6 @@ class PrivacySettingsFragment : DSLSettingsFragment(R.string.preferences__privac
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
if (FeatureFlags.defaultMessageTimer()) {
|
|
||||||
dividerPref()
|
dividerPref()
|
||||||
|
|
||||||
sectionHeaderPref(R.string.PrivacySettingsFragment__disappearing_messages)
|
sectionHeaderPref(R.string.PrivacySettingsFragment__disappearing_messages)
|
||||||
|
@ -155,7 +154,6 @@ class PrivacySettingsFragment : DSLSettingsFragment(R.string.preferences__privac
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
}
|
|
||||||
|
|
||||||
dividerPref()
|
dividerPref()
|
||||||
|
|
||||||
|
|
|
@ -102,6 +102,7 @@ class ConversationRepository {
|
||||||
if (SignalStore.settings().getUniversalExpireTimer() != 0 &&
|
if (SignalStore.settings().getUniversalExpireTimer() != 0 &&
|
||||||
conversationRecipient.getExpireMessages() == 0 &&
|
conversationRecipient.getExpireMessages() == 0 &&
|
||||||
!conversationRecipient.isGroup() &&
|
!conversationRecipient.isGroup() &&
|
||||||
|
conversationRecipient.isRegistered() &&
|
||||||
(threadId == -1 || !DatabaseFactory.getMmsSmsDatabase(context).hasMeaningfulMessage(threadId)))
|
(threadId == -1 || !DatabaseFactory.getMmsSmsDatabase(context).hasMeaningfulMessage(threadId)))
|
||||||
{
|
{
|
||||||
showUniversalExpireTimerUpdate = true;
|
showUniversalExpireTimerUpdate = true;
|
||||||
|
|
|
@ -381,11 +381,7 @@ public final class SettingsValues extends SignalStoreValues {
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getUniversalExpireTimer() {
|
public int getUniversalExpireTimer() {
|
||||||
if (FeatureFlags.defaultMessageTimer()) {
|
|
||||||
return getInteger(UNIVERSAL_EXPIRE_TIMER, 0);
|
return getInteger(UNIVERSAL_EXPIRE_TIMER, 0);
|
||||||
} else {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private @Nullable Uri getUri(@NonNull String key) {
|
private @Nullable Uri getUri(@NonNull String key) {
|
||||||
|
|
|
@ -80,7 +80,6 @@ public final class FeatureFlags {
|
||||||
private static final String NOTIFICATION_REWRITE = "android.notificationRewrite";
|
private static final String NOTIFICATION_REWRITE = "android.notificationRewrite";
|
||||||
private static final String MP4_GIF_SEND_SUPPORT = "android.mp4GifSendSupport";
|
private static final String MP4_GIF_SEND_SUPPORT = "android.mp4GifSendSupport";
|
||||||
private static final String MEDIA_QUALITY_LEVELS = "android.mediaQuality.levels";
|
private static final String MEDIA_QUALITY_LEVELS = "android.mediaQuality.levels";
|
||||||
private static final String DEFAULT_MESSAGE_TIMER = "android.defaultMessageTimer.2";
|
|
||||||
private static final String RETRY_RECEIPT_LIFESPAN = "android.retryReceiptLifespan";
|
private static final String RETRY_RECEIPT_LIFESPAN = "android.retryReceiptLifespan";
|
||||||
private static final String RETRY_RESPOND_MAX_AGE = "android.retryRespondMaxAge";
|
private static final String RETRY_RESPOND_MAX_AGE = "android.retryRespondMaxAge";
|
||||||
private static final String SENDER_KEY = "android.senderKey";
|
private static final String SENDER_KEY = "android.senderKey";
|
||||||
|
@ -118,7 +117,6 @@ public final class FeatureFlags {
|
||||||
NOTIFICATION_REWRITE,
|
NOTIFICATION_REWRITE,
|
||||||
MP4_GIF_SEND_SUPPORT,
|
MP4_GIF_SEND_SUPPORT,
|
||||||
MEDIA_QUALITY_LEVELS,
|
MEDIA_QUALITY_LEVELS,
|
||||||
DEFAULT_MESSAGE_TIMER,
|
|
||||||
RETRY_RECEIPT_LIFESPAN,
|
RETRY_RECEIPT_LIFESPAN,
|
||||||
RETRY_RESPOND_MAX_AGE,
|
RETRY_RESPOND_MAX_AGE,
|
||||||
SENDER_KEY
|
SENDER_KEY
|
||||||
|
@ -168,7 +166,6 @@ public final class FeatureFlags {
|
||||||
NOTIFICATION_REWRITE,
|
NOTIFICATION_REWRITE,
|
||||||
MP4_GIF_SEND_SUPPORT,
|
MP4_GIF_SEND_SUPPORT,
|
||||||
MEDIA_QUALITY_LEVELS,
|
MEDIA_QUALITY_LEVELS,
|
||||||
DEFAULT_MESSAGE_TIMER,
|
|
||||||
RETRY_RECEIPT_LIFESPAN,
|
RETRY_RECEIPT_LIFESPAN,
|
||||||
RETRY_RESPOND_MAX_AGE
|
RETRY_RESPOND_MAX_AGE
|
||||||
);
|
);
|
||||||
|
@ -370,10 +367,6 @@ public final class FeatureFlags {
|
||||||
return getString(MEDIA_QUALITY_LEVELS, "");
|
return getString(MEDIA_QUALITY_LEVELS, "");
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean defaultMessageTimer() {
|
|
||||||
return getBoolean(DEFAULT_MESSAGE_TIMER, false);
|
|
||||||
}
|
|
||||||
|
|
||||||
/** How long to wait before considering a retry to be a failure. */
|
/** How long to wait before considering a retry to be a failure. */
|
||||||
public static long retryReceiptLifespan() {
|
public static long retryReceiptLifespan() {
|
||||||
return getLong(RETRY_RECEIPT_LIFESPAN, TimeUnit.HOURS.toMillis(1));
|
return getLong(RETRY_RECEIPT_LIFESPAN, TimeUnit.HOURS.toMillis(1));
|
||||||
|
|
Ładowanie…
Reference in New Issue