mirror of
https://github.com/oxen-io/session-android.git
synced 2024-11-27 20:15:21 +00:00
Hide link device preference if we're a secondary device.
This commit is contained in:
parent
da67bfab4c
commit
a2e9271050
@ -180,8 +180,12 @@ public class ApplicationPreferencesActivity extends PassphraseRequiredActionBarA
|
||||
.setOnPreferenceClickListener(new CategoryClickListener(PREFERENCE_CATEGORY_PUBLIC_KEY));
|
||||
this.findPreference(PREFERENCE_CATEGORY_QR_CODE)
|
||||
.setOnPreferenceClickListener(new CategoryClickListener(PREFERENCE_CATEGORY_QR_CODE));
|
||||
this.findPreference(PREFERENCE_CATEGORY_LINK_DEVICE)
|
||||
.setOnPreferenceClickListener(new CategoryClickListener(PREFERENCE_CATEGORY_LINK_DEVICE));
|
||||
|
||||
Preference linkDevicePreference = this.findPreference(PREFERENCE_CATEGORY_LINK_DEVICE);
|
||||
// Hide if we're already a secondary device
|
||||
linkDevicePreference.setVisible(!TextSecurePreferences.isSecondaryDevice(getContext()));
|
||||
linkDevicePreference.setOnPreferenceClickListener(new CategoryClickListener(PREFERENCE_CATEGORY_LINK_DEVICE));
|
||||
|
||||
this.findPreference(PREFERENCE_CATEGORY_SEED)
|
||||
.setOnPreferenceClickListener(new CategoryClickListener((PREFERENCE_CATEGORY_SEED)));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user