forked from yilozt/rounded-window-corners
-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: don't skip effect application for maximized windows
Previously, if shouldEnableEffect() returned false for a window on startup, the effect wasn't applied to it, so it wasn't possible to enable and disable it. This commit removes the extra check, so the effect is applied properly, and then disabled with refreshRoundedCorners(). Fixes #54
- Loading branch information
Showing
1 changed file
with
0 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -36,13 +36,6 @@ import type {RoundedWindowActor} from '../utils/types.js'; | |
export function onAddEffect(actor: RoundedWindowActor) { | ||
logDebug(`opened: ${actor?.metaWindow.title}: ${actor}`); | ||
|
||
const win = actor.metaWindow; | ||
|
||
if (!shouldEnableEffect(win)) { | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
flexagoon
Author
Owner
|
||
logDebug(`Skipping ${win.title}`); | ||
return; | ||
} | ||
|
||
unwrapActor(actor)?.add_effect_with_name( | ||
ROUNDED_CORNERS_EFFECT, | ||
new RoundedCornersEffect(), | ||
|
@flexagoon:
Removing these lines actually creates a bug.
Now, my originally frameless Conky window appears to have a shadowed frame around it. Black-listing Conky gives the same unwanted result.
If I open the preferences of the extension and toggle the "Skip LibAdwaita applications" or "Skip LibHandy applications" option, the shadowed frame around the Conky window will disappear (I guess the
refreshRoundedCorners()
method is called when I toggle the options). However, if I log out and log in again, the frame around the Conky window will re-appear.