From 8f57dd86af1482ba353db015ffae616afe36e2fb Mon Sep 17 00:00:00 2001 From: WerWolv Date: Mon, 1 Dec 2025 19:33:21 +0100 Subject: [PATCH] fix: Typos --- lib/libimhex/include/hex/api/imhex_api/system.hpp | 2 +- lib/libimhex/source/api/imhex_api.cpp | 2 +- main/gui/source/window/window.cpp | 15 +++++---------- 3 files changed, 7 insertions(+), 12 deletions(-) diff --git a/lib/libimhex/include/hex/api/imhex_api/system.hpp b/lib/libimhex/include/hex/api/imhex_api/system.hpp index fc103eb0f..f83dcbe20 100644 --- a/lib/libimhex/include/hex/api/imhex_api/system.hpp +++ b/lib/libimhex/include/hex/api/imhex_api/system.hpp @@ -171,7 +171,7 @@ EXPORT_MODULE namespace hex { * @brief Checks if multi-window mode is enabled currently * @return Whether multi-window mode is enabled */ - bool isMutliWindowModeEnabled(); + bool isMultiWindowModeEnabled(); /** * @brief Gets the init arguments passed to ImHex from the splash screen diff --git a/lib/libimhex/source/api/imhex_api.cpp b/lib/libimhex/source/api/imhex_api.cpp index e56875545..549d13e95 100644 --- a/lib/libimhex/source/api/imhex_api.cpp +++ b/lib/libimhex/source/api/imhex_api.cpp @@ -704,7 +704,7 @@ namespace hex { return impl::s_borderlessWindowMode; } - bool isMutliWindowModeEnabled() { + bool isMultiWindowModeEnabled() { return impl::s_multiWindowMode; } diff --git a/main/gui/source/window/window.cpp b/main/gui/source/window/window.cpp index ae647f6ff..baef38047 100644 --- a/main/gui/source/window/window.cpp +++ b/main/gui/source/window/window.cpp @@ -54,23 +54,16 @@ #include #include #include -#include #include namespace hex { - using namespace std::literals::chrono_literals; - Window::Window() { this->initGLFW(); this->initImGui(); this->setupNativeWindow(); this->registerEventHandlers(); this->setupEmergencyPopups(); - - #if !defined(OS_WEB) - - #endif } Window::~Window() { @@ -232,6 +225,8 @@ namespace hex { } void Window::loop() { + using namespace std::literals::chrono_literals; + glfwShowWindow(m_window); double returnToIdleTime = 5.0; @@ -670,7 +665,7 @@ namespace hex { float startY = windowPos.y + ImGui::GetTextLineHeight() + ((ImGui::GetTextLineHeight() + (ImGui::GetStyle().FramePadding.y * 2.0F)) * (onWelcomeScreen ? 1 : 2)); const auto height = ImGui::GetTextLineHeightWithSpacing() * 1.5f; - // Offset banner based on the size of the title bar. On macOS it's slightly taller + // Offset banner based on the size of the title bar. On macOS, it's slightly taller #if defined(OS_MACOS) startY += 2 * 8_scaled; #else @@ -914,7 +909,7 @@ namespace hex { auto* drawData = ImGui::GetDrawData(); // Avoid accidentally clearing the viewport when the application is minimized, - // otherwise the OS will display an empty frame during deminimization on macOS + // otherwise the OS will display an empty frame during window restore on macOS if (drawData->DisplaySize.x != 0 && drawData->DisplaySize.y != 0) { int displayWidth, displayHeight; glfwGetFramebufferSize(m_window, &displayWidth, &displayHeight); @@ -1285,7 +1280,7 @@ namespace hex { io.ConfigDragClickToInputText = true; if (glfwGetPrimaryMonitor() != nullptr) { - if (ImHexApi::System::isMutliWindowModeEnabled()) { + if (ImHexApi::System::isMultiWindowModeEnabled()) { io.ConfigFlags |= ImGuiConfigFlags_ViewportsEnable; // Enable viewport window OS decorations on Linux so that the window can be moved around on Wayland