focus: avoid replaying anim on an unchanged window

This commit is contained in:
Vaxry 2025-06-19 17:39:44 +02:00
parent f444ff0089
commit 39c2832102
No known key found for this signature in database
GPG Key ID: 665806380871D640

View File

@ -33,6 +33,13 @@ static void onFocusChange(PHLWINDOW window) {
if (!window)
return;
static PHLWINDOWREF lastWindow;
if (lastWindow == window)
return;
lastWindow = window;
static const auto POPACITY = CConfigValue<Hyprlang::FLOAT>("plugin:hyprfocus:fade_opacity");
static const auto PBOUNCE = CConfigValue<Hyprlang::FLOAT>("plugin:hyprfocus:bounce_strength");
static const auto PSLIDE = CConfigValue<Hyprlang::FLOAT>("plugin:hyprfocus:slide_height");