feat(ContextMenu): disable if GUI is open (#1239)

This commit is contained in:
Andreas Maerten
2023-04-15 17:40:17 +02:00
committed by GitHub
parent 461e1b5138
commit e138e2fa11
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,4 @@
#include "gui.hpp"
#include "services/context_menu/context_menu_service.hpp"
#include "view.hpp"
@ -26,7 +27,7 @@ namespace big
void view::context_menu()
{
if (const auto draw_list = ImGui::GetBackgroundDrawList(); draw_list)
if (const auto draw_list = ImGui::GetBackgroundDrawList(); draw_list && !g_gui->is_open())
{
if (g_context_menu_service->enabled && g_context_menu_service->m_pointer
&& g_context_menu_service->m_pointer->m_navigation)