fix(ags bar workspace): make urgent go away when on current workspace
This commit is contained in:
parent
ee5af67444
commit
3b65abac7e
2 changed files with 12 additions and 19 deletions
|
@ -26,8 +26,13 @@ const Workspace = ({ i } = {}) =>
|
||||||
self.toggleClassName('empty', !occupied);
|
self.toggleClassName('empty', !occupied);
|
||||||
|
|
||||||
// Deal with urgent windows
|
// Deal with urgent windows
|
||||||
if (Hyprland.getClient(addr)?.workspace.id === i)
|
if (Hyprland.getClient(addr)?.workspace.id === i) {
|
||||||
self.toggleClassName('urgent', true);
|
self.toggleClassName('urgent', true);
|
||||||
|
|
||||||
|
// Only show for a sec when urgent is current workspace
|
||||||
|
if (Hyprland.active.workspace.id === i)
|
||||||
|
timeout(1000, () => self.toggleClassName('urgent', false));
|
||||||
|
}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
connections: [
|
connections: [
|
||||||
|
@ -63,15 +68,9 @@ export default () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
const widget = Overlay({
|
const widget = Overlay({
|
||||||
setup: self => {
|
|
||||||
// FIXME: see if we can get rid of this timeout
|
// FIXME: see if we can get rid of this timeout
|
||||||
timeout(1, () => {
|
setup: self => timeout(1, () => self.pass_through = true),
|
||||||
self.set_overlay_pass_through(
|
|
||||||
self.get_children()[1],
|
|
||||||
true,
|
|
||||||
);
|
|
||||||
});
|
|
||||||
},
|
|
||||||
overlays: [highlight],
|
overlays: [highlight],
|
||||||
child: EventBox({
|
child: EventBox({
|
||||||
child: Box({
|
child: Box({
|
||||||
|
|
|
@ -24,15 +24,9 @@ export default () => PopupWindow({
|
||||||
onOpen: child => update(child.child),
|
onOpen: child => update(child.child),
|
||||||
|
|
||||||
child: Overlay({
|
child: Overlay({
|
||||||
setup: self => {
|
|
||||||
// FIXME: see if we can get rid of this timeout
|
// FIXME: see if we can get rid of this timeout
|
||||||
timeout(1, () => {
|
setup: self => timeout(1, () => self.pass_through = true),
|
||||||
self.set_overlay_pass_through(
|
|
||||||
self.get_children()[1],
|
|
||||||
true,
|
|
||||||
);
|
|
||||||
});
|
|
||||||
},
|
|
||||||
overlays: [Highlighter()],
|
overlays: [Highlighter()],
|
||||||
child: Box({
|
child: Box({
|
||||||
className: 'overview',
|
className: 'overview',
|
||||||
|
|
Loading…
Reference in a new issue