[TabGroupModelFilter] Fix crash on undo last closed tab
The cause is TabModel#setIndex() event is fired when undoing the first tab, before the tab actually undo in TabGroupModelFilter. This CL is a band-aid fix for M74. We cache the selected tab that is not exist in the TabGroupFilterModel. And try to select that tab on the next addTab()/undo call. This will fix the current crash and will not causing any side effects on TabGroupModelFilter normal usage. Bug: 948518 Change-Id: Ic65e521baebe65c54b1033f6be35dd2dbdd1a676 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1552281Reviewed-by:Wei-Yin Chen (陳威尹) <wychen@chromium.org> Reviewed-by:
Yusuf Ozuysal <yusufo@chromium.org> Commit-Queue: Mei Liang <meiliang@chromium.org> Cr-Commit-Position: refs/heads/master@{#648363}
Showing
Please register or sign in to comment