Skip to content

Browser: better tracking of per-window trust#319601

Merged
kycutler merged 2 commits into
mainfrom
kycutler/windowtrusttracking
Jun 2, 2026
Merged

Browser: better tracking of per-window trust#319601
kycutler merged 2 commits into
mainfrom
kycutler/windowtrusttracking

Conversation

@kycutler
Copy link
Copy Markdown
Contributor

@kycutler kycutler commented Jun 2, 2026

No description provided.

Copilot AI review requested due to automatic review settings June 2, 2026 15:45
@kycutler kycutler self-assigned this Jun 2, 2026
@kycutler kycutler enabled auto-merge (squash) June 2, 2026 15:46
@vs-code-engineering
Copy link
Copy Markdown
Contributor

vs-code-engineering Bot commented Jun 2, 2026

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

@jruales

Matched files:

  • src/vs/platform/browserView/electron-main/browserViewMainService.ts

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refines how the Electron main process tracks “trusted file roots” for integrated browser views on a per-window basis, aiming to keep the global trusted-roots set in sync as windows come and go.

Changes:

  • Replace a global windowsMainService.onDidDestroyWindow listener with per-window lifecycle subscriptions created on demand when a window reports trusted roots.
  • Track and dispose per-window close subscriptions via a DisposableMap<number>.
  • Recompute the global trusted file roots set whenever per-window roots change or a tracked window closes.
Show a summary per file
File Description
src/vs/platform/browserView/electron-main/browserViewMainService.ts Switches trusted-roots cleanup from a global window-destroy listener to per-window lifecycle subscriptions and disposal tracking.

Copilot's findings

  • Files reviewed: 1/1 changed files
  • Comments generated: 2

Comment thread src/vs/platform/browserView/electron-main/browserViewMainService.ts Outdated
Comment thread src/vs/platform/browserView/electron-main/browserViewMainService.ts
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@kycutler kycutler merged commit 50c0f4b into main Jun 2, 2026
25 checks passed
@kycutler kycutler deleted the kycutler/windowtrusttracking branch June 2, 2026 17:02
@vs-code-engineering vs-code-engineering Bot added this to the 1.124.0 milestone Jun 2, 2026
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.

3 participants