Fixed: Play Store reported a crash error when closing the tabs. #3791
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #3790
This error was occurring due to the user frequently clicking the close icon of the same tab, in this situation first click closes the tab, and the second immediate click again triggers the
closeTab
function but recyclerView does not have the valid view for this position because it is in removing process so this makes this view invalid and recyclerView returns the-1
index for invalid views. So this was the reason for this issue, to address this issue we have added a check in ourcloseTab
method if the incoming index is-1
then it will not execute the further code.CloseTabIssue.mp4
CloseTabFix.mp4
Tab closed
snackBar behavior. Now, when the user clicks theUNDO
button to restore a tab, we disable the snackBar's "UNDO" button to prevent subsequent clicks. This prevents the addition of multiple tabs if theUNDO
button is clicked multiple times, as this type of restored tab leads to unexpected behavior see below video.SnackbarMultipleClickIssue.mp4