Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve preference renderer linking #14311

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

msujew
Copy link
Member

@msujew msujew commented Oct 14, 2024

What it does

Fixes a few minor issues which should massively reduce the amount of Linked preference "<id>" not found. warnings printed to the console:

  1. Don't use a link to window.titleBarStyle when not in Electron mode (the linked preference does only exist in Electron).
  2. Use editor.cursorSurroundingLines instead of cursorSurroundingLines as a link.
  3. Some extensions sometimes link commands in the preferences. We now also use the CommandRegistry to figure out the name of a linked command.
  4. Caches the IDs of the tree nodes of every preference so that we can later find the tree ID again for any preference ID. That way, we don't have to recompute the ID to figure out the real name of a preference (and potentially do that incorrectly).

How to test

  1. Open the application.
  2. Open the settings/preference view
  3. Assert that there are much fewer warnings in the console.
  4. Assert that all links to other preferences are correctly rendered and actually make you jump to that preference.

Review checklist

Reminder for reviewers

@msujew msujew added the preferences issues related to preferences label Oct 14, 2024
@msujew msujew requested a review from tsmaeder October 14, 2024 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
preferences issues related to preferences
Projects
Status: Waiting on reviewers
Development

Successfully merging this pull request may close these issues.

1 participant