diff --git a/Packages/com.varneon.fbx-to-blender-importer/Editor/ImportWindow.cs b/Packages/com.varneon.fbx-to-blender-importer/Editor/ImportWindow.cs index d0490a2..7718b87 100644 --- a/Packages/com.varneon.fbx-to-blender-importer/Editor/ImportWindow.cs +++ b/Packages/com.varneon.fbx-to-blender-importer/Editor/ImportWindow.cs @@ -15,6 +15,9 @@ namespace Varneon.BlenderFBXImporter /// internal class ImportWindow : EditorWindow { + [SerializeField] + private Texture2D windowIcon; + List models = new List(); ImportParameters importParameters = new ImportParameters(1f, true); @@ -83,14 +86,15 @@ private static bool DoesSelectionContainFBXAssets() [MenuItem(MenuPath, false)] private static void OpenImportPrompt() { - ImportWindow window = GetWindow(); - window.titleContent = new GUIContent("Blender FBX Importer", Resources.Load("Icon_BlenderFBXImporter")); - window.minSize = MinWindowSize; - window.Show(); + GetWindow(); } private void OnEnable() { + titleContent = new GUIContent("Blender FBX Importer", windowIcon); + + minSize = MinWindowSize; + models.AddRange(GetSelectedFBXAssetPaths().Select(c => new FBXAsset(c))); TryAddModelPathFunc = path => TryAddModelPath(path); diff --git a/Packages/com.varneon.fbx-to-blender-importer/Editor/ImportWindow.cs.meta b/Packages/com.varneon.fbx-to-blender-importer/Editor/ImportWindow.cs.meta index fa1c9d6..9dcc36e 100644 --- a/Packages/com.varneon.fbx-to-blender-importer/Editor/ImportWindow.cs.meta +++ b/Packages/com.varneon.fbx-to-blender-importer/Editor/ImportWindow.cs.meta @@ -5,7 +5,9 @@ labels: MonoImporter: externalObjects: {} serializedVersion: 2 - defaultReferences: [] + defaultReferences: + - m_ViewDataDictionary: {instanceID: 0} + - windowIcon: {fileID: 2800000, guid: 03f16bc94a553d245b8b0d285528897d, type: 3} executionOrder: 0 icon: {fileID: 2800000, guid: 03f16bc94a553d245b8b0d285528897d, type: 3} userData: