Skip to content

QuickAccessDialog: defer built-in provider construction until first use#3973

Open
vogella wants to merge 1 commit into
eclipse-platform:masterfrom
vogella:quickaccess-lazy-providers
Open

QuickAccessDialog: defer built-in provider construction until first use#3973
vogella wants to merge 1 commit into
eclipse-platform:masterfrom
vogella:quickaccess-lazy-providers

Conversation

@vogella
Copy link
Copy Markdown
Contributor

@vogella vogella commented May 6, 2026

The dialog constructor previously instantiated all nine built-in providers (Editor, View, Perspective, Command, Action, Wizard, Preference, Properties, HelpSearch) eagerly inside the open-time BusyIndicator, even when the user closed the dialog without typing. This wraps each in a LazyQuickAccessProvider that exposes the provider id and requiresUiAccess flag as static metadata and resolves the delegate only on the first getElements/findElement call, so identity and threading queries during dialog setup do not force construction.

As a side benefit, it should marginally help stabilize QuickAccessDialogTest.testPreviousChoicesAvailableForExtension on Windows by reducing constructor work and the initial-layout shell resize events that can preempt the compute job.

@vogella vogella force-pushed the quickaccess-lazy-providers branch from bf9c5c8 to d30f0ff Compare May 6, 2026 15:42
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 6, 2026

Test Results

   864 files  ±0     864 suites  ±0   54m 52s ⏱️ + 4m 43s
 7 988 tests ±0   7 745 ✅ ±0  243 💤 ±0  0 ❌ ±0 
20 418 runs  ±0  19 763 ✅ ±0  655 💤 ±0  0 ❌ ±0 

Results for commit 0461de2. ± Comparison against base commit 6c53fec.

♻️ This comment has been updated with latest results.

@vogella
Copy link
Copy Markdown
Contributor Author

vogella commented May 7, 2026

Marking as draft so it is clear that this is NOT planned for 4.40 (it is planned for 4.41)

Wrap the nine built-in providers in a LazyQuickAccessProvider that
exposes the id and requiresUiAccess flag as static metadata and
resolves the delegate only on the first getElements/findElement call,
so closing the dialog without typing skips constructing them
entirely.

Marginally helps stabilize
QuickAccessDialogTest.testPreviousChoicesAvailableForExtension on
Windows by reducing constructor work and the resulting initial-layout
resize events that can preempt the compute job.
@vogella vogella force-pushed the quickaccess-lazy-providers branch from d30f0ff to 0461de2 Compare May 31, 2026 11:54
@vogella vogella marked this pull request as ready for review May 31, 2026 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant