mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2024-11-25 10:55:55 +03:00
Merge pull request #7375 from vector-im/feature/mna/device-manager-go-to-new-screen
[Device Management] Redirect to the new screen everywhere when lab flag is on
This commit is contained in:
commit
36e5166051
2 changed files with 11 additions and 2 deletions
1
changelog.d/7374.feature
Normal file
1
changelog.d/7374.feature
Normal file
|
@ -0,0 +1 @@
|
|||
[Device Management] Redirect to the new screen everywhere when lab flag is on
|
|
@ -63,6 +63,8 @@ class VectorSettingsActivity : VectorBaseActivity<ActivityVectorSettingsBinding>
|
|||
|
||||
@Inject lateinit var session: Session
|
||||
|
||||
@Inject lateinit var vectorPreferences: VectorPreferences
|
||||
|
||||
override fun initUiAndData() {
|
||||
setupToolbar(views.settingsToolbar)
|
||||
.allowBack()
|
||||
|
@ -77,13 +79,19 @@ class VectorSettingsActivity : VectorBaseActivity<ActivityVectorSettingsBinding>
|
|||
replaceFragment(views.vectorSettingsPage, VectorSettingsAdvancedSettingsFragment::class.java, null, FRAGMENT_TAG)
|
||||
SettingsActivityPayload.SecurityPrivacy ->
|
||||
replaceFragment(views.vectorSettingsPage, VectorSettingsSecurityPrivacyFragment::class.java, null, FRAGMENT_TAG)
|
||||
SettingsActivityPayload.SecurityPrivacyManageSessions ->
|
||||
SettingsActivityPayload.SecurityPrivacyManageSessions -> {
|
||||
val fragmentClass = if (vectorPreferences.isNewSessionManagerEnabled()) {
|
||||
im.vector.app.features.settings.devices.v2.VectorSettingsDevicesFragment::class.java
|
||||
} else {
|
||||
VectorSettingsDevicesFragment::class.java
|
||||
}
|
||||
replaceFragment(
|
||||
views.vectorSettingsPage,
|
||||
VectorSettingsDevicesFragment::class.java,
|
||||
fragmentClass,
|
||||
null,
|
||||
FRAGMENT_TAG
|
||||
)
|
||||
}
|
||||
SettingsActivityPayload.Notifications -> {
|
||||
requestHighlightPreferenceKeyOnResume(VectorPreferences.SETTINGS_ENABLE_THIS_DEVICE_PREFERENCE_KEY)
|
||||
replaceFragment(views.vectorSettingsPage, VectorSettingsNotificationPreferenceFragment::class.java, null, FRAGMENT_TAG)
|
||||
|
|
Loading…
Reference in a new issue