mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-21 17:29:32 +01:00
Remove leftover Valentine's Day assets.
This commit is contained in:
committed by
Alex Hart
parent
35199abf1f
commit
63412b0153
@@ -66,7 +66,7 @@ public final class Megaphones {
|
||||
private static final MegaphoneSchedule ALWAYS = new ForeverSchedule(true);
|
||||
private static final MegaphoneSchedule NEVER = new ForeverSchedule(false);
|
||||
|
||||
private static final Set<Event> DONATE_EVENTS = SetUtil.newHashSet(Event.VALENTINES_DONATIONS_2022, Event.BECOME_A_SUSTAINER);
|
||||
private static final Set<Event> DONATE_EVENTS = SetUtil.newHashSet(Event.BECOME_A_SUSTAINER);
|
||||
private static final long MIN_TIME_BETWEEN_DONATE_MEGAPHONES = TimeUnit.DAYS.toMillis(30);
|
||||
|
||||
private Megaphones() {}
|
||||
@@ -107,7 +107,6 @@ public final class Megaphones {
|
||||
put(Event.NOTIFICATIONS, shouldShowNotificationsMegaphone(context) ? RecurringSchedule.every(TimeUnit.DAYS.toMillis(30)) : NEVER);
|
||||
put(Event.ONBOARDING, shouldShowOnboardingMegaphone(context) ? ALWAYS : NEVER);
|
||||
put(Event.BECOME_A_SUSTAINER, shouldShowDonateMegaphone(context, records) ? ShowForDurationSchedule.showForDays(7) : NEVER);
|
||||
put(Event.VALENTINES_DONATIONS_2022, NEVER);
|
||||
put(Event.PIN_REMINDER, new SignalPinReminderSchedule());
|
||||
|
||||
// Feature-introduction megaphones should *probably* be added below this divider
|
||||
@@ -135,8 +134,6 @@ public final class Megaphones {
|
||||
return buildAddAProfilePhotoMegaphone(context);
|
||||
case BECOME_A_SUSTAINER:
|
||||
return buildBecomeASustainerMegaphone(context);
|
||||
case VALENTINES_DONATIONS_2022:
|
||||
return buildValentinesDonationsMegaphone(context);
|
||||
case NOTIFICATION_PROFILES:
|
||||
return buildNotificationProfilesMegaphone(context);
|
||||
default:
|
||||
@@ -283,21 +280,6 @@ public final class Megaphones {
|
||||
.build();
|
||||
}
|
||||
|
||||
private static @NonNull Megaphone buildValentinesDonationsMegaphone(@NonNull Context context) {
|
||||
return new Megaphone.Builder(Event.VALENTINES_DONATIONS_2022, Megaphone.Style.BASIC)
|
||||
.setTitle(R.string.ValentinesDayMegaphone_happy_heart_day)
|
||||
.setImage(R.drawable.ic_valentines_donor_megaphone_64)
|
||||
.setBody(R.string.ValentinesDayMegaphone_show_your_affection)
|
||||
.setActionButton(R.string.BecomeASustainerMegaphone__contribute, (megaphone, listener) -> {
|
||||
listener.onMegaphoneNavigationRequested(AppSettingsActivity.subscriptions(context));
|
||||
listener.onMegaphoneCompleted(Event.VALENTINES_DONATIONS_2022);
|
||||
})
|
||||
.setSecondaryButton(R.string.BecomeASustainerMegaphone__no_thanks, (megaphone, listener) -> {
|
||||
listener.onMegaphoneCompleted(Event.VALENTINES_DONATIONS_2022);
|
||||
})
|
||||
.build();
|
||||
}
|
||||
|
||||
private static @NonNull Megaphone buildNotificationProfilesMegaphone(@NonNull Context context) {
|
||||
return new Megaphone.Builder(Event.NOTIFICATION_PROFILES, Megaphone.Style.BASIC)
|
||||
.setTitle(R.string.NotificationProfilesMegaphone__notification_profiles)
|
||||
|
||||
@@ -64,7 +64,6 @@ public final class FeatureFlags {
|
||||
private static final String PHONE_NUMBER_PRIVACY_VERSION = "android.phoneNumberPrivacyVersion";
|
||||
private static final String CLIENT_EXPIRATION = "android.clientExpiration";
|
||||
public static final String DONATE_MEGAPHONE = "android.donate.2";
|
||||
public static final String VALENTINES_DONATE_MEGAPHONE = "android.donate.valentines.2022";
|
||||
private static final String CUSTOM_VIDEO_MUXER = "android.customVideoMuxer";
|
||||
private static final String CDS_REFRESH_INTERVAL = "cds.syncInterval.seconds";
|
||||
private static final String AUTOMATIC_SESSION_RESET = "android.automaticSessionReset.2";
|
||||
@@ -136,7 +135,6 @@ public final class FeatureFlags {
|
||||
DONOR_BADGES_DISPLAY,
|
||||
HARDWARE_AEC_MODELS,
|
||||
FORCE_DEFAULT_AEC,
|
||||
VALENTINES_DONATE_MEGAPHONE,
|
||||
STORIES,
|
||||
STORIES_TEXT_FUNCTIONS,
|
||||
STORIES_TEXT_POSTS
|
||||
@@ -194,8 +192,7 @@ public final class FeatureFlags {
|
||||
SENDER_KEY_MAX_AGE,
|
||||
DONOR_BADGES_DISPLAY,
|
||||
DONATE_MEGAPHONE,
|
||||
FORCE_DEFAULT_AEC,
|
||||
VALENTINES_DONATE_MEGAPHONE
|
||||
FORCE_DEFAULT_AEC
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -312,11 +309,6 @@ public final class FeatureFlags {
|
||||
return getString(DONATE_MEGAPHONE, "");
|
||||
}
|
||||
|
||||
/** The raw valentine's day donate megaphone CSV string */
|
||||
public static String valentinesDonateMegaphone() {
|
||||
return getString(VALENTINES_DONATE_MEGAPHONE, "");
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether the user can choose phone number privacy settings, and;
|
||||
* Whether to fetch and store the secondary certificate
|
||||
|
||||
@@ -37,13 +37,6 @@ public final class LocaleFeatureFlags {
|
||||
return isEnabled(FeatureFlags.DONATE_MEGAPHONE, FeatureFlags.donateMegaphone());
|
||||
}
|
||||
|
||||
/**
|
||||
* In valentines donation megaphone group for given country code
|
||||
*/
|
||||
public static boolean isInValentinesDonateMegaphone() {
|
||||
return isEnabled(FeatureFlags.VALENTINES_DONATE_MEGAPHONE, FeatureFlags.valentinesDonateMegaphone());
|
||||
}
|
||||
|
||||
public static @NonNull Optional<PushMediaConstraints.MediaConfig> getMediaQualityLevel() {
|
||||
Map<String, Integer> countryValues = parseCountryValues(FeatureFlags.getMediaQualityLevels(), NOT_FOUND);
|
||||
int level = getCountryValue(countryValues, Recipient.self().getE164().or(""), NOT_FOUND);
|
||||
|
||||
Reference in New Issue
Block a user