Report will close old tab before selecting new tab.
ActivityTabProvider#setTabModelSelector looks at the total tab count when willCloseTab is called, and checks to see if there's one tab remaining, in which case it reports no Activity tab. This is probably because didSelectTab is never passed a null tab (maybe we should do that instead?). The problem is, for SingleTabModel, there's only ever a single tab (or should we report 2 while a tab is closing?), so once we started calling WillCloseTab, we broke ActivityTabProvider. This change moves the select tab call after the willCloseTab call so that we restore the correct state to ActivityTabProvider after closing the tab. Bug: 995966 Change-Id: I9d478b774a9f0c88ed646653d3aa5d12b195a870 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1764331Reviewed-by:Matthew Jones <mdjones@chromium.org> Commit-Queue: Michael Thiessen <mthiesse@chromium.org> Cr-Commit-Position: refs/heads/master@{#689289}
Showing
Please register or sign in to comment