diff options
| author | Vaxry <43317083+vaxerski@users.noreply.github.com> | 2026-04-19 18:47:49 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-04-19 18:47:49 +0100 |
| commit | a360c31d0434898888e710f4a5f560200f50cecf (patch) | |
| tree | f68746c77b416654ec059f670e2e66af62581de3 /src/config/legacy/ConfigManager.cpp | |
| parent | 889ee4f26d77ff0c36f5c4767ef0629371fd2c18 (diff) | |
errorOverlay: modernize, refactor, use GPU rendering (#14122)
Improves the overlay's rendering:
- GPU accelerated
- supports gradients
- wraps
- cleaner code a bit
Diffstat (limited to 'src/config/legacy/ConfigManager.cpp')
| -rw-r--r-- | src/config/legacy/ConfigManager.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/config/legacy/ConfigManager.cpp b/src/config/legacy/ConfigManager.cpp index c91959c8..bfe8fef3 100644 --- a/src/config/legacy/ConfigManager.cpp +++ b/src/config/legacy/ConfigManager.cpp @@ -29,7 +29,7 @@ #include "../defaultConfig.hpp" #include "../../render/Renderer.hpp" -#include "../../hyprerror/HyprError.hpp" +#include "../../errorOverlay/Overlay.hpp" #include "../../managers/input/InputManager.hpp" #include "../../managers/eventLoop/EventLoopManager.hpp" #include "../../managers/EventManager.hpp" @@ -957,7 +957,7 @@ CConfigManager::CConfigManager() { } if (g_pEventLoopManager && ERR.has_value()) - g_pEventLoopManager->doLater([ERR] { g_pHyprError->queueCreate(ERR.value(), CHyprColor{1.0, 0.1, 0.1, 1.0}); }); + g_pEventLoopManager->doLater([ERR] { ErrorOverlay::overlay()->queueCreate(ERR.value(), ErrorOverlay::Colors::ERROR); }); } eConfigManagerType CConfigManager::type() { @@ -1311,14 +1311,14 @@ void CConfigManager::postConfigReload(const Hyprlang::CParseResult& result) { m_configErrors = ""; if (result.error && !std::any_cast<Hyprlang::INT>(m_config->getConfigValue("debug:suppress_errors"))) - g_pHyprError->queueCreate(result.getError(), CHyprColor(1.0, 50.0 / 255.0, 50.0 / 255.0, 1.0)); + ErrorOverlay::overlay()->queueCreate(result.getError(), ErrorOverlay::Colors::ERROR); else if (std::any_cast<Hyprlang::INT>(m_config->getConfigValue("autogenerated")) == 1) - g_pHyprError->queueCreate( + ErrorOverlay::overlay()->queueCreate( "Warning: You're using an autogenerated config! Edit the config file to get rid of this message. (config file: " + getMainConfigPath() + " )\nSUPER+Q -> kitty (if it doesn't launch, make sure it's installed or choose a different terminal in the config)\nSUPER+M -> exit Hyprland", - CHyprColor(1.0, 1.0, 70.0 / 255.0, 1.0)); + ErrorOverlay::Colors::ERROR); else - g_pHyprError->destroy(); + ErrorOverlay::overlay()->destroy(); // Set the modes for all monitors as we configured them // not on first launch because monitors might not exist yet @@ -1509,7 +1509,7 @@ void CConfigManager::handlePluginLoads() { g_pPluginSystem->updateConfigPlugins(m_declaredPlugins, pluginsChanged); if (pluginsChanged) { - g_pHyprError->destroy(); + ErrorOverlay::overlay()->destroy(); reload(); } } |
