Skip to content

fix: resolve TreeView deprecation in Unity 6.2+#844

Merged
hadashiA merged 1 commit intohadashiA:masterfrom
chikacc:master
Mar 29, 2026
Merged

fix: resolve TreeView deprecation in Unity 6.2+#844
hadashiA merged 1 commit intohadashiA:masterfrom
chikacc:master

Conversation

@chikacc
Copy link
Copy Markdown
Contributor

@chikacc chikacc commented Mar 28, 2026

Description

Unity 6 (6000.2) has deprecated the non-generic TreeView, TreeViewItem, and TreeViewState classes in UnityEditor.IMGUI.Controls.

  • Unity 6000.2+: Triggers obsolete warnings (CS0618).
  • Unity 6000.5+: Triggers obsolete compiler errors (CS0619).

Solution

Introduced type aliasing for these classes to their generic counterparts (TreeView<int>, etc.) using the #if UNITY_6000_2_OR_NEWER preprocessor directive.

  • Removes deprecation warnings in Unity 6000.2 and later.
  • Fixes build errors in Unity 6000.5 and later.

@vercel
Copy link
Copy Markdown

vercel bot commented Mar 28, 2026

@chikacc is attempting to deploy a commit to the hadashia's projects Team on Vercel.

A member of the Team first needs to authorize it.

@hadashiA
Copy link
Copy Markdown
Owner

👍

@hadashiA hadashiA merged commit 8335fe9 into hadashiA:master Mar 29, 2026
1 of 11 checks passed
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.

2 participants