Skip to content

Commit

Permalink
For issue mozilla-mobile#10727 - Hide saved logins details
Browse files Browse the repository at this point in the history
Removed the clearFlags call from the HomeActivity that was causing this issue and removed the now redundant call to update the flag from the redirectToReAuth method
  • Loading branch information
Mihai Eduard Badea authored and mcarare committed Jun 22, 2020
1 parent e9bb11e commit eb45b37
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 4 deletions.
2 changes: 0 additions & 2 deletions app/src/main/java/org/mozilla/fenix/HomeActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,6 @@ open class HomeActivity : LocaleAwareAppCompatActivity() {
final override fun onPause() {
if (settings().lastKnownMode.isPrivate) {
window.addFlags(WindowManager.LayoutParams.FLAG_SECURE)
} else {
window.clearFlags(WindowManager.LayoutParams.FLAG_SECURE)
}
super.onPause()

Expand Down
2 changes: 0 additions & 2 deletions app/src/main/java/org/mozilla/fenix/ext/Fragment.kt
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,12 @@ fun Fragment.hideToolbar() {
/**
* Pops the backstack to force users to re-auth if they put the app in the background and return to it
* while being inside the saved logins flow
* It also updates the FLAG_SECURE status for the activity's window
*
* Does nothing if the user is currently navigating to any of the [destinations] given as a parameter
*
*/
fun Fragment.redirectToReAuth(destinations: List<Int>, currentDestination: Int?) {
if (currentDestination !in destinations) {
activity?.let { it.checkAndUpdateScreenshotPermission(it.settings()) }
findNavController().popBackStack(R.id.savedLoginsAuthFragment, false)
}
}

0 comments on commit eb45b37

Please sign in to comment.