File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed
Assets/MixedRealityToolkit.SDK/Inspectors/UX/BoundingBox Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change 33// Licensed under the MIT License. See LICENSE in the project root for license information.
44//
55
6+ using Microsoft . MixedReality . Toolkit . Experimental . Utilities ;
67using Microsoft . MixedReality . Toolkit . Input ;
78using Microsoft . MixedReality . Toolkit . UI ;
89using Microsoft . MixedReality . Toolkit . Utilities . Editor ;
@@ -44,6 +45,21 @@ public override void OnInspectorGUI()
4445 }
4546
4647 DrawDefaultInspector ( ) ;
48+
49+ // Draws warning message for deprecated object with button for migration option
50+ DrawDeprecated ( ) ;
51+ }
52+
53+ private void DrawDeprecated ( )
54+ {
55+ EditorGUILayout . HelpBox ( "This Component is deprecated. Please migrate object to up to date version" , UnityEditor . MessageType . Warning ) ;
56+ if ( GUILayout . Button ( "Migrate Object" ) )
57+ {
58+ BoundsControlMigrationHandler migrationHandler = new BoundsControlMigrationHandler ( ) ;
59+ migrationHandler . Migrate ( ( ( BoundingBox ) target ) . gameObject ) ;
60+
61+ }
4762 }
4863 }
4964}
65+
You can’t perform that action at this time.
0 commit comments