mirror of
https://github.com/oxen-io/session-android.git
synced 2025-12-31 14:06:10 +00:00
Don't show the link preview megaphone if previously disabled.
This commit is contained in:
@@ -16,6 +16,7 @@ import androidx.core.app.NotificationCompat;
|
||||
import org.greenrobot.eventbus.EventBus;
|
||||
import org.thoughtcrime.securesms.R;
|
||||
import org.thoughtcrime.securesms.jobmanager.impl.SqlCipherMigrationConstraintObserver;
|
||||
import org.thoughtcrime.securesms.keyvalue.SettingsValues;
|
||||
import org.thoughtcrime.securesms.lock.RegistrationLockReminders;
|
||||
import org.thoughtcrime.securesms.logging.Log;
|
||||
import org.thoughtcrime.securesms.preferences.widgets.NotificationPrivacyPreference;
|
||||
@@ -419,8 +420,13 @@ public class TextSecurePreferences {
|
||||
setBooleanPreference(context, TYPING_INDICATORS, enabled);
|
||||
}
|
||||
|
||||
public static void setLinkPreviewsEnabled(Context context, boolean enabled) {
|
||||
setBooleanPreference(context, LINK_PREVIEWS, enabled);
|
||||
/**
|
||||
* Only kept so that we can avoid showing the megaphone for the new link previews setting
|
||||
* ({@link SettingsValues#isLinkPreviewsEnabled()}) when users upgrade. This can be removed after
|
||||
* we stop showing the link previews megaphone.
|
||||
*/
|
||||
public static boolean wereLinkPreviewsEnabled(Context context) {
|
||||
return getBooleanPreference(context, LINK_PREVIEWS, true);
|
||||
}
|
||||
|
||||
public static boolean isGifSearchInGridLayout(Context context) {
|
||||
|
||||
Reference in New Issue
Block a user