fix(ags overview): try to fix multi-monitor issue
All checks were successful
Discord / discord commits (push) Has been skipped
All checks were successful
Discord / discord commits (push) Has been skipped
This commit is contained in:
parent
42d4759786
commit
7860e2638e
2 changed files with 13 additions and 3 deletions
|
@ -137,8 +137,18 @@ export const updateClients = (box) => {
|
|||
const active =
|
||||
client.address === Hyprland.active.client.address;
|
||||
|
||||
// TODO: fix multi monitor issue. this is just a temp fix
|
||||
client.at[1] -= 2920;
|
||||
// TODO: see if this works on multi monitor setup
|
||||
const alloc = box.get_allocation();
|
||||
let monitor = box.get_display()
|
||||
.get_monitor_at_point(alloc.x, alloc.y);
|
||||
|
||||
monitor = Hyprland.monitors.find((mon) => {
|
||||
return mon.make === monitor.manufacturer &&
|
||||
mon.model === monitor.model;
|
||||
});
|
||||
|
||||
client.at[0] -= monitor.x;
|
||||
client.at[1] -= monitor.y;
|
||||
|
||||
// Special workspaces that haven't been opened yet
|
||||
// return a size of 0. We need to set them to default
|
||||
|
|
|
@ -75,7 +75,7 @@ export const Overview = () => {
|
|||
`,
|
||||
}),
|
||||
|
||||
// TODO: throttle his?
|
||||
// TODO: throttle this?
|
||||
setup: (self) => {
|
||||
self.on('get-child-position', (_, ch) => {
|
||||
if (ch === mainBox) {
|
||||
|
|
Loading…
Reference in a new issue