mirror of
https://github.com/element-hq/element-android
synced 2024-11-27 11:59:12 +03:00
Fix cancel actions.
This commit is contained in:
parent
04fb31666b
commit
2527cab73e
2 changed files with 8 additions and 1 deletions
|
@ -43,7 +43,7 @@ class QrCodeLoginShowQrCodeFragment : VectorBaseFragment<FragmentQrCodeLoginShow
|
|||
|
||||
private fun initCancelButton() {
|
||||
views.qrCodeLoginShowQrCodeCancelButton.debouncedClicks {
|
||||
activity?.supportFragmentManager?.popBackStack()
|
||||
parentFragmentManager.popBackStack()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -39,9 +39,16 @@ class QrCodeLoginStatusFragment : VectorBaseFragment<FragmentQrCodeLoginStatusBi
|
|||
|
||||
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
|
||||
super.onViewCreated(view, savedInstanceState)
|
||||
initCancelButton()
|
||||
observeViewState()
|
||||
}
|
||||
|
||||
private fun initCancelButton() {
|
||||
views.qrCodeLoginStatusCancelButton.debouncedClicks {
|
||||
parentFragmentManager.popBackStack()
|
||||
}
|
||||
}
|
||||
|
||||
private fun observeViewState() {
|
||||
viewModel.onEach {
|
||||
when (it.connectionStatus) {
|
||||
|
|
Loading…
Reference in a new issue