mirror of
git://git.suckless.org/dwm
synced 2026-04-07 06:45:42 +01:00
sendmon: resize fullscreen windows to target monitor
When a fullscreen window is moved to another monitor (e.g. via tagmon), its geometry does not always match the new monitor's dimensions. Steps to reproduce: 1. Start dwm with two monitors (A and B). 2. Open a window on Monitor A. 3. Make the window fullscreen (e.g. Firefox with F11). 4. Move the window to Monitor B using the tagmon shortcut (Mod+Shift+>). 5. Go to the other monitor (B), observe that the window is still visible on Monitor A and its contents, even though the window's title is seen on Monitor B bar. 6. Go to the monitor A where the window is still in fullscreen, remove the fullscreen and the window automatically will go to monitor B. This fix ensures that fullscreen windows are correctly resized to the new monitor's geometry during the move.
This commit is contained in:
parent
c3dd6a829b
commit
2bb919e634
2
dwm.c
2
dwm.c
@ -1429,6 +1429,8 @@ sendmon(Client *c, Monitor *m)
|
|||||||
c->tags = m->tagset[m->seltags]; /* assign tags of target monitor */
|
c->tags = m->tagset[m->seltags]; /* assign tags of target monitor */
|
||||||
attach(c);
|
attach(c);
|
||||||
attachstack(c);
|
attachstack(c);
|
||||||
|
if (c->isfullscreen)
|
||||||
|
resizeclient(c, m->mx, m->my, m->mw, m->mh);
|
||||||
focus(NULL);
|
focus(NULL);
|
||||||
arrange(NULL);
|
arrange(NULL);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user