1
0
Fork 0
mirror of https://github.com/davatorium/rofi.git synced 2024-11-25 13:55:34 -05:00

switch desktop check

This commit is contained in:
seanpringle 2012-06-30 03:43:42 +10:00
parent 092f3bbd03
commit 342b4e865c

View file

@ -774,6 +774,13 @@ void run_switcher(Window root, int mode, int fmode)
int n = menu(root, list, NULL);
if (n >= 0 && list[n])
{
if (mode == ALLWINDOWS)
{
// TODO: get rid of strtol
window_send_message(root, root, netatoms[_NET_CURRENT_DESKTOP], strtol(list[n], NULL, 10)-1,
SubstructureNotifyMask | SubstructureRedirectMask);
XSync(display, False);
}
window_send_message(root, ids->array[n], netatoms[_NET_ACTIVE_WINDOW], 2, // 2 = pager
SubstructureNotifyMask | SubstructureRedirectMask);
}