using MCPForUnity.Editor.Setup;
using MCPForUnity.Editor.Windows;
using UnityEditor;
using UnityEngine;
namespace MCPForUnity.Editor.MenuItems
{
///
/// Centralized menu items for MCP For Unity
///
public static class MCPForUnityMenu
{
// ========================================
// Main Menu Items
// ========================================
///
/// Show the Setup Window
///
[MenuItem("Window/MCP For Unity/Setup Window", priority = 1)]
public static void ShowSetupWindow()
{
SetupWindowService.ShowSetupWindow();
}
///
/// Toggle the main MCP For Unity window
///
[MenuItem("Window/MCP For Unity/Toggle MCP Window %#m", priority = 2)]
public static void ToggleMCPWindow()
{
if (EditorWindow.HasOpenInstances())
{
foreach (var window in UnityEngine.Resources.FindObjectsOfTypeAll())
{
window.Close();
}
}
else
{
MCPForUnityEditorWindow.ShowWindow();
}
}
}
}