From 4317656c64bd9321a6f21ba6aff671d95bd0ed82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=88=E6=80=9D=E6=B5=B7?= <1464576565@qq.com> Date: Mon, 1 Dec 2025 16:45:54 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Editor/ToolBarExtension/EditorQuickToolBar.cs | 6 +++--- Editor/ToolBarExtension/LocalizationDropdownField.cs | 10 +++++----- Editor/ToolBarExtension/ResourceModeDropdownField.cs | 8 ++++---- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/Editor/ToolBarExtension/EditorQuickToolBar.cs b/Editor/ToolBarExtension/EditorQuickToolBar.cs index 3a6d456..c621532 100644 --- a/Editor/ToolBarExtension/EditorQuickToolBar.cs +++ b/Editor/ToolBarExtension/EditorQuickToolBar.cs @@ -12,7 +12,7 @@ namespace AlicizaX.Editor.Extension [MainToolbarElement("EditorQuickToolBar", alignment: ToolbarAlign.Right, order: 1)] public class EditorQuickToolBar : IMGUIContainer { - private static GUIContent toolsDropBtContent; + private GUIContent toolsDropBtContent; public void InitializeElement() { @@ -33,7 +33,7 @@ namespace AlicizaX.Editor.Extension GUILayout.EndHorizontal(); } - static void DrawEditorToolDropdownMenus() + void DrawEditorToolDropdownMenus() { GenericMenu popMenu = new GenericMenu(); for (int i = 0; i < EditorToolFunctionAttributeCollector.Attributes.Count; i++) @@ -46,7 +46,7 @@ namespace AlicizaX.Editor.Extension popMenu.ShowAsContext(); } - static void ClickToolsSubmenu(int menuIdx) + void ClickToolsSubmenu(int menuIdx) { var editorTp = EditorToolFunctionAttributeCollector.Attributes[menuIdx]; if (editorTp.MethodInfo != null && editorTp.MethodInfo.IsStatic) diff --git a/Editor/ToolBarExtension/LocalizationDropdownField.cs b/Editor/ToolBarExtension/LocalizationDropdownField.cs index c4d40a3..b2c3e39 100644 --- a/Editor/ToolBarExtension/LocalizationDropdownField.cs +++ b/Editor/ToolBarExtension/LocalizationDropdownField.cs @@ -11,9 +11,9 @@ using UnityEngine.UIElements; [MainToolbarElement("LocalizationDropdownField", alignment: ToolbarAlign.Right, order: 0)] public class LocalizationDropdownField : IMGUIContainer { - private static GUIContent appConfigBtContent; + private GUIContent appConfigBtContent; - private static string[] _languageTypeNames; + private string[] _languageTypeNames; public void InitializeElement() { @@ -39,7 +39,7 @@ public class LocalizationDropdownField : IMGUIContainer GUILayout.EndHorizontal(); } - static void DrawEditorToolDropdownMenus() + void DrawEditorToolDropdownMenus() { string langaugeName = GetPrefsStr(); GenericMenu popMenu = new GenericMenu(); @@ -53,13 +53,13 @@ public class LocalizationDropdownField : IMGUIContainer popMenu.ShowAsContext(); } - static void ClickToolsSubmenu(string langaugeName) + void ClickToolsSubmenu(string langaugeName) { EditorPrefs.SetString(LocalizationComponent.PrefsKey, langaugeName); Debug.Log(langaugeName); } - static string GetPrefsStr() + string GetPrefsStr() { return EditorPrefs.GetString(LocalizationComponent.PrefsKey, "None"); } diff --git a/Editor/ToolBarExtension/ResourceModeDropdownField.cs b/Editor/ToolBarExtension/ResourceModeDropdownField.cs index 9611161..b4a81e2 100644 --- a/Editor/ToolBarExtension/ResourceModeDropdownField.cs +++ b/Editor/ToolBarExtension/ResourceModeDropdownField.cs @@ -12,9 +12,9 @@ namespace AlicizaX.Editor.Extension [MainToolbarElement("ResourceModeDropdownField", alignment: ToolbarAlign.Right, order: 0)] public class ResourceModeDropdownField : IMGUIContainer { - private static GUIContent appConfigBtContent; + private GUIContent appConfigBtContent; - private static readonly string[] _resourceModeNames = + private readonly string[] _resourceModeNames = { "Editor", "Offline", @@ -42,7 +42,7 @@ namespace AlicizaX.Editor.Extension GUILayout.EndHorizontal(); } - static void DrawEditorToolDropdownMenus() + void DrawEditorToolDropdownMenus() { int index = EditorPrefs.GetInt(ResourceComponent.PrefsKey, 0); GenericMenu popMenu = new GenericMenu(); @@ -56,7 +56,7 @@ namespace AlicizaX.Editor.Extension popMenu.ShowAsContext(); } - static void ClickToolsSubmenu(int menuIdx) + void ClickToolsSubmenu(int menuIdx) { EditorPrefs.SetInt(ResourceComponent.PrefsKey, menuIdx); }