forked from Shinonome/dots-hyprland
ConfigToggle; properly implement behavior on hover lost (fixes #1126)
This commit is contained in:
@@ -69,6 +69,10 @@ export const ConfigToggle = ({
|
|||||||
},
|
},
|
||||||
child: widgetContent,
|
child: widgetContent,
|
||||||
onClicked: (self) => self.attribute.toggle(self),
|
onClicked: (self) => self.attribute.toggle(self),
|
||||||
|
onHoverLost: () => { // mouse away
|
||||||
|
toggleIcon.toggleClassName('switch-fg-toggling-false', false);
|
||||||
|
if (enabled.value) toggleIcon.toggleClassName('txt-poof', false);
|
||||||
|
},
|
||||||
setup: (self) => {
|
setup: (self) => {
|
||||||
setupCursorHover(self);
|
setupCursorHover(self);
|
||||||
self.connect('pressed', () => { // mouse down
|
self.connect('pressed', () => { // mouse down
|
||||||
|
|||||||
Reference in New Issue
Block a user