* TF-5022 Report the folder and email list loads of a switch attempt to ShownAccountLoadTracker and reload the shown account through watchShownReload
* TF-5022 Implement AccountSwitchView in DashboardAccountSwitchView with ShownMailboxSelection, the shown account input blocker and the closing of open popups
* TF-5022 Close every route above the dashboard in DashboardAccountSwitchView.blockInput, count the mobile composer route in DashboardShownMailboxSelection.hasOpenComposer, and test the email list report order with the real MailboxController and ThreadController
* TF-5022 Gate T-02.6 on T-06 delegationEnabledProvider in ADR-0114
* TF-5022 Test that a switch closes menu submenus and drops mail list shortcuts
* TF-5022 Keep key presses from the dashboard while a switch blocks its input
* TF-5022 Count a load as failed in ShownAccountStateSubscription when onDone throws
* TF-5022 Rename ShownMailboxSelection to AccountSwitchDashboard with resetForNewAccount and GetXAccountSwitchDashboard
---------
Co-authored-by: Dat H. Pham <dphamhoang@linagora.com>
A first Email/query page shorter than the limit means the mailbox is
exhausted unless collapseThreads is on. Forcing canLoadMore whenever the
list did not fill the viewport sent a useless 'before' Email/query on
every open or refresh of a small folder.
Closes#4943
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Extract shouldAutoLoadMoreByEstimatedHeight as a testable static method
and use strict < instead of <= so an estimated height equal to the
viewport no longer triggers a redundant load — actual rendered height
is likely larger than the 40 px estimate and already overflows.
Use maxScrollExtent <= 0 instead of maxScrollExtent <= viewportDimension
so auto-load only triggers when the list has not yet filled the viewport.
Also set canLoadMore based on page-size comparison to avoid showing the
Load More button when the server has returned the final partial page.