From 8364276a5dbce8628ee7502d0ddc0d4eac1d93b6 Mon Sep 17 00:00:00 2001 From: Louis <35883445+louist103@users.noreply.github.com> Date: Sun, 22 Dec 2024 12:10:12 -0500 Subject: [PATCH] move audio editor to enhancements --- mm/2s2h/BenGui/BenMenuBar.cpp | 11 +++++------ mm/2s2h/BenGui/SearchableMenuItems.h | 14 +++++++------- 2 files changed, 12 insertions(+), 13 deletions(-) diff --git a/mm/2s2h/BenGui/BenMenuBar.cpp b/mm/2s2h/BenGui/BenMenuBar.cpp index 39e45c6ac9..a180df94e9 100644 --- a/mm/2s2h/BenGui/BenMenuBar.cpp +++ b/mm/2s2h/BenGui/BenMenuBar.cpp @@ -358,6 +358,8 @@ void DrawSettingsMenu() { extern std::shared_ptr mHudEditorWindow; extern std::shared_ptr mItemTrackerWindow; extern std::shared_ptr mItemTrackerSettingsWindow; +extern std::shared_ptr mAudioEditorWindow; + void DrawEnhancementsMenu() { if (UIWidgets::BeginMenu("Enhancements")) { @@ -806,6 +808,9 @@ void DrawEnhancementsMenu() { UIWidgets::WindowButton("Item Tracker Settings", "gWindows.ItemTrackerSettings", mItemTrackerSettingsWindow); } + if (mAudioEditorWindow) { + UIWidgets::WindowButton("Audio Editor", "gWindows.AudioEditor", mAudioEditorWindow); + } ImGui::EndMenu(); } @@ -851,8 +856,6 @@ extern std::shared_ptr mActorViewerWindow; extern std::shared_ptr mCollisionViewerWindow; extern std::shared_ptr mEventLogWindow; -extern std::shared_ptr mAudioEditorWindow; - const char* logLevels[] = { "trace", "debug", "info", "warn", "error", "critical", "off", }; @@ -979,10 +982,6 @@ void DrawDeveloperToolsMenu() { UIWidgets::WindowButton("Event Log", "gWindows.EventLog", mEventLogWindow); } - if (mAudioEditorWindow) { - UIWidgets::WindowButton("Audio Editor", "gWindows.AudioEditor", mAudioEditorWindow); - } - ImGui::EndMenu(); } } diff --git a/mm/2s2h/BenGui/SearchableMenuItems.h b/mm/2s2h/BenGui/SearchableMenuItems.h index 60de55640d..f7c618c842 100644 --- a/mm/2s2h/BenGui/SearchableMenuItems.h +++ b/mm/2s2h/BenGui/SearchableMenuItems.h @@ -1429,6 +1429,13 @@ void AddEnhancements() { "", WIDGET_WINDOW_BUTTON, { .size = UIWidgets::Sizes::Inline, .windowName = "Item Tracker Settings" } } } } }); + enhancementsSidebar.push_back({ "Audio Editor", + 1, + { { { "Popout Audio Editor", + "gWindows.AudioEditor", + "Enables the audio editor window", + WIDGET_WINDOW_BUTTON, + { .size = UIWidgets::Sizes::Inline, .windowName = "Audio Editor" } } } } }); } void AddDevTools() { @@ -1670,13 +1677,6 @@ void AddDevTools() { "Enables the event log window", WIDGET_WINDOW_BUTTON, { .size = UIWidgets::Sizes::Inline, .windowName = "Event Log" } } } } }); - devToolsSidebar.push_back({ "Audio Editor", - 1, - { { { "Popout Audio Editor", - "gWindows.AudioEditor", - "Enables the audio editor window", - WIDGET_WINDOW_BUTTON, - { .size = UIWidgets::Sizes::Inline, .windowName = "Audio Editor" } } } } }); } void SearchMenuGetItem(widgetInfo& widget) {