Skip to content

Implement outlineViewType setting that changes the Project Outline View (#3799) - #4538

Merged
Hannia Valera (hanniavalera) merged 3 commits into
microsoft:mainfrom
ar1m4n:dev/ar1m4n/AddOutlineViewTypeSetting
Apr 7, 2026
Merged

Hannia Valera (hanniavalera) merged 3 commits into
microsoft:mainfrom
ar1m4n:dev/ar1m4n/AddOutlineViewTypeSetting

Conversation

@ar1m4n

@ar1m4n ar1m4n commented Aug 8, 2025 •

Copy link
Copy Markdown
Contributor

This change addresses item #3799

This changes visible behavior, documentation and configuration]

The following changes are proposed:

  • New config option "cmake.outlineViewType" that accepts one of 2 values - list or tree
  • If "cmake.outlineViewType" is set to "list", the Project Outline View will show all cmake targets in a "flat" view
  • If "cmake.outlineViewType" is set to "tree", the Project Outline View will show all cmake targets in a hierarchical view

The purpose of this change is to enable users to choose witch type of view to use. In my case, I find the "tree" view much more useful

Changes:

  • A ConfigurationReader argument is added to ProjectNode`s constructor
  • ProjectNodes::update uses the "cmake.outlineViewType" to produce a different output
  • An on change event handler is added to refresh the Outline View each time the value of the new config option is changed
@ar1m4n

ar1m4n commented Aug 8, 2025

Copy link
Copy Markdown
Contributor Author

@microsoft-github-policy-service agree

@hanniavalera
Hannia Valera (hanniavalera) force-pushed the dev/ar1m4n/AddOutlineViewTypeSetting branch 2 times, most recently from 92c86d5 to 0d6c999 Compare February 23, 2026 17:07
@hanniavalera
Hannia Valera (hanniavalera) force-pushed the dev/ar1m4n/AddOutlineViewTypeSetting branch 5 times, most recently from ff5063c to 058e68d Compare April 1, 2026 17:42
Dimitar Ushatov and others added 3 commits April 7, 2026 12:31
…views

- Move onChange subscription from workspace-level to per-project
  ConfigurationReader, fixing resource-scoped setting detection and
  multi-project refresh (Bugs microsoft#1 and microsoft#2 from audit)
- Branch in WorkspaceFolderNode.updateCodeModel() to restore the
  pre-1.15 multi-project outline in tree mode, bypassing the
  populateViewCodeModel() flattening (Bug microsoft#3)
- Revert ProjectNode to original 3-param constructor (remove
  ConfigurationReader dependency)
- Revert ProjectNode.update() to standard folder-based target
  grouping (tree structure comes from separate ProjectNodes)
- Add CHANGELOG entry

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@hanniavalera
Hannia Valera (hanniavalera) force-pushed the dev/ar1m4n/AddOutlineViewTypeSetting branch from 89bacd4 to e11e8c9 Compare April 7, 2026 18:28
@hanniavalera

Hannia Valera (hanniavalera) commented Apr 7, 2026 •

Copy link
Copy Markdown
Contributor

Here is what the changes look like (tested locally):
image
image

@hanniavalera
Hannia Valera (hanniavalera) merged commit a0e78c1 into microsoft:main Apr 7, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants