Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Device Management] Redirect to the new screen everywhere when lab flag is on #7375

Merged
merged 2 commits into from
Oct 17, 2022

Conversation

mnaturel
Copy link
Contributor

Type of change

  • Feature
  • Bugfix
  • Technical
  • Other :

Content

Checking the lab flag value for new session manager to select the correct session manager screen to navigate to.

Motivation and context

Closes #7374

Screenshots / GIFs

Tests

  • Sign in to a verified session
  • Enable the lab flag for new session manager
  • Restart the app
  • Press the in app alert to review the session appearing in the home screen
  • Check the new session manager main screen is opened
  • Disable the lab flag for new session manager
  • Restart the app
  • Press the in app alert to review the session appearing in the home screen
  • Check the old session manager main screen is opened

Tested devices

  • Physical
  • Emulator
  • OS version(s): Android 11

Checklist

@mnaturel mnaturel added PR-Small PR with less than 20 updated lines Z-NextRelease For issues and PRs which should be included in the NextRelease. labels Oct 14, 2022
@mnaturel mnaturel requested review from a team and onurays and removed request for a team October 14, 2022 12:32
@mnaturel mnaturel marked this pull request as ready for review October 14, 2022 12:32
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

SettingsActivityPayload.SecurityPrivacyManageSessions ->
SettingsActivityPayload.SecurityPrivacyManageSessions -> {
val fragmentClass = if (vectorPreferences.isNewSessionManagerEnabled()) {
im.vector.app.features.settings.devices.v2.VectorSettingsDevicesFragment::class.java
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe add the import to avoid this long line?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess we can't avoid that. We have two VectorSettingsDevicesFragment, the V2 version and the previous one. This is only temporary. Once the new session manager is delabsed, we will remove all the old code.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, OK, I did not see that the names were identical.
FTR you could have used import alias
So:

import im.vector.app.features.settings.devices.v2.VectorSettingsDevicesFragment as VectorSettingsDevicesFragmentV2

but not now, this is fine, please do not update the PR!

@mnaturel mnaturel requested a review from bmarty October 17, 2022 07:42
@bmarty bmarty merged commit 36e5166 into develop Oct 17, 2022
@bmarty bmarty deleted the feature/mna/device-manager-go-to-new-screen branch October 17, 2022 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR-Small PR with less than 20 updated lines Z-NextRelease For issues and PRs which should be included in the NextRelease.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Device Management] Redirect to the new screen everywhere when lab flag is on
2 participants