mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2026-04-15 08:21:41 -04:00
fix: can't set ~0 tag layout for ipc
This commit is contained in:
parent
d86045fa28
commit
4a8568639f
1 changed files with 5 additions and 1 deletions
|
|
@ -238,6 +238,7 @@ void dwl_ipc_output_set_layout(struct wl_client *client,
|
||||||
unsigned int index) {
|
unsigned int index) {
|
||||||
DwlIpcOutput *ipc_output;
|
DwlIpcOutput *ipc_output;
|
||||||
Monitor *monitor;
|
Monitor *monitor;
|
||||||
|
unsigned int target_tag;
|
||||||
|
|
||||||
ipc_output = wl_resource_get_user_data(resource);
|
ipc_output = wl_resource_get_user_data(resource);
|
||||||
if (!ipc_output)
|
if (!ipc_output)
|
||||||
|
|
@ -247,7 +248,10 @@ void dwl_ipc_output_set_layout(struct wl_client *client,
|
||||||
if (index >= LENGTH(layouts))
|
if (index >= LENGTH(layouts))
|
||||||
index = 0;
|
index = 0;
|
||||||
|
|
||||||
monitor->pertag->ltidxs[monitor->pertag->curtag] = &layouts[index];
|
target_tag = monitor->pertag->curtag ? monitor->pertag->curtag
|
||||||
|
: monitor->pertag->prevtag;
|
||||||
|
|
||||||
|
monitor->pertag->ltidxs[target_tag] = &layouts[index];
|
||||||
arrange(monitor, false);
|
arrange(monitor, false);
|
||||||
printstatus();
|
printstatus();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue