Add storage force push internal option.

This commit is contained in:
Alan Evans
2020-07-10 18:12:16 -03:00
committed by Greyson Parrelli
parent eb6ecc59ab
commit d70999c386
3 changed files with 20 additions and 0 deletions

View File

@@ -14,6 +14,7 @@ import org.thoughtcrime.securesms.dependencies.ApplicationDependencies;
import org.thoughtcrime.securesms.jobs.RefreshAttributesJob;
import org.thoughtcrime.securesms.jobs.RefreshOwnProfileJob;
import org.thoughtcrime.securesms.jobs.RotateProfileKeyJob;
import org.thoughtcrime.securesms.jobs.StorageForcePushJob;
import org.thoughtcrime.securesms.keyvalue.InternalValues;
import org.thoughtcrime.securesms.keyvalue.SignalStore;
import org.thoughtcrime.securesms.logging.Log;
@@ -50,6 +51,12 @@ public class InternalOptionsPreferenceFragment extends CorrectedPreferenceFragme
Toast.makeText(getContext(), "Scheduled profile key rotation", Toast.LENGTH_SHORT).show();
return true;
});
findPreference("pref_force_send").setOnPreferenceClickListener(preference -> {
ApplicationDependencies.getJobManager().add(new StorageForcePushJob());
Toast.makeText(getContext(), "Scheduled storage force push", Toast.LENGTH_SHORT).show();
return true;
});
}
private void initializeSwitchPreference(@NonNull PreferenceDataStore preferenceDataStore,