|
3 | 3 | using UnityEditorInternal; |
4 | 4 | using UnityEngine; |
5 | 5 | using UnityEngine.Perception.GroundTruth; |
| 6 | + |
6 | 7 | #if UNITY_EDITOR_WIN || UNITY_EDITOR_OSX |
7 | 8 | using UnityEditor.Perception.Visualizer; |
8 | 9 | #endif |
@@ -159,13 +160,6 @@ public override void OnInspectorGUI() |
159 | 160 | GUIUtility.systemCopyBuffer = dir; |
160 | 161 | } |
161 | 162 | GUILayout.EndHorizontal(); |
162 | | -#if UNITY_EDITOR_WIN || UNITY_EDITOR_OSX |
163 | | - if (GUILayout.Button("Open Visualizer")) |
164 | | - { |
165 | | - var project = Application.dataPath; |
166 | | - _=VisualizerInstaller.RunVisualizer(project); |
167 | | - } |
168 | | -#endif |
169 | 163 | GUILayout.EndVertical(); |
170 | 164 | } |
171 | 165 |
|
@@ -199,6 +193,27 @@ public override void OnInspectorGUI() |
199 | 193 | GUILayout.EndHorizontal(); |
200 | 194 | GUILayout.EndVertical(); |
201 | 195 |
|
| 196 | +#if UNITY_EDITOR_WIN || UNITY_EDITOR_OSX |
| 197 | + GUILayout.Space(10); |
| 198 | + EditorGUILayout.LabelField("Visualizer Tool"); |
| 199 | + |
| 200 | + GUILayout.BeginHorizontal("TextArea"); |
| 201 | + if (GUILayout.Button("Open Visualizer")) |
| 202 | + { |
| 203 | + var project = Application.dataPath; |
| 204 | + _=VisualizerInstaller.RunVisualizer(project); |
| 205 | + } |
| 206 | + |
| 207 | + if (GUILayout.Button("Check For Updates")) |
| 208 | + { |
| 209 | + var project = Application.dataPath; |
| 210 | + _=VisualizerInstaller.CheckForUpdates(); |
| 211 | + } |
| 212 | + |
| 213 | + GUILayout.EndHorizontal(); |
| 214 | + GUILayout.Space(10); |
| 215 | +#endif |
| 216 | + |
202 | 217 |
|
203 | 218 | if (EditorSettings.asyncShaderCompilation) |
204 | 219 | { |
|
0 commit comments