mirror of
https://github.com/leahneukirchen/cwm.git
synced 2023-08-10 21:13:12 +03:00
Update _NET_CURRENT_DESKTOP with the screen's group_active->num.
This commit is contained in:
parent
cb65869d7a
commit
845e82015c
2
calmwm.h
2
calmwm.h
@ -544,7 +544,7 @@ void xu_ewmh_net_wm_desktop_viewport(struct screen_ctx *);
|
|||||||
void xu_ewmh_net_wm_number_of_desktops(struct screen_ctx *);
|
void xu_ewmh_net_wm_number_of_desktops(struct screen_ctx *);
|
||||||
void xu_ewmh_net_showing_desktop(struct screen_ctx *);
|
void xu_ewmh_net_showing_desktop(struct screen_ctx *);
|
||||||
void xu_ewmh_net_virtual_roots(struct screen_ctx *);
|
void xu_ewmh_net_virtual_roots(struct screen_ctx *);
|
||||||
void xu_ewmh_net_current_desktop(struct screen_ctx *, long);
|
void xu_ewmh_net_current_desktop(struct screen_ctx *);
|
||||||
void xu_ewmh_net_desktop_names(struct screen_ctx *);
|
void xu_ewmh_net_desktop_names(struct screen_ctx *);
|
||||||
|
|
||||||
void xu_ewmh_net_wm_desktop(struct client_ctx *);
|
void xu_ewmh_net_wm_desktop(struct client_ctx *);
|
||||||
|
6
group.c
6
group.c
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
static void group_assign(struct group_ctx *, struct client_ctx *);
|
static void group_assign(struct group_ctx *, struct client_ctx *);
|
||||||
static void group_restack(struct group_ctx *);
|
static void group_restack(struct group_ctx *);
|
||||||
static void group_setactive(struct screen_ctx *, long);
|
static void group_setactive(struct screen_ctx *, int);
|
||||||
|
|
||||||
const char *num_to_name[] = {
|
const char *num_to_name[] = {
|
||||||
"nogroup", "one", "two", "three", "four", "five", "six",
|
"nogroup", "one", "two", "three", "four", "five", "six",
|
||||||
@ -132,7 +132,7 @@ group_init(struct screen_ctx *sc)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
group_setactive(struct screen_ctx *sc, long idx)
|
group_setactive(struct screen_ctx *sc, int idx)
|
||||||
{
|
{
|
||||||
struct group_ctx *gc;
|
struct group_ctx *gc;
|
||||||
|
|
||||||
@ -142,7 +142,7 @@ group_setactive(struct screen_ctx *sc, long idx)
|
|||||||
}
|
}
|
||||||
sc->group_active = gc;
|
sc->group_active = gc;
|
||||||
|
|
||||||
xu_ewmh_net_current_desktop(sc, idx);
|
xu_ewmh_net_current_desktop(sc);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
6
xutil.c
6
xutil.c
@ -274,10 +274,12 @@ xu_ewmh_net_virtual_roots(struct screen_ctx *sc)
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
xu_ewmh_net_current_desktop(struct screen_ctx *sc, long idx)
|
xu_ewmh_net_current_desktop(struct screen_ctx *sc)
|
||||||
{
|
{
|
||||||
|
long num = sc->group_active->num;
|
||||||
|
|
||||||
XChangeProperty(X_Dpy, sc->rootwin, ewmh[_NET_CURRENT_DESKTOP],
|
XChangeProperty(X_Dpy, sc->rootwin, ewmh[_NET_CURRENT_DESKTOP],
|
||||||
XA_CARDINAL, 32, PropModeReplace, (unsigned char *)&idx, 1);
|
XA_CARDINAL, 32, PropModeReplace, (unsigned char *)&num, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
Loading…
Reference in New Issue
Block a user