mirror of
https://github.com/leahneukirchen/cwm.git
synced 2023-08-10 21:13:12 +03:00
get rid of long standing XXX: now that we configure screens based on
config options, add the keybinding GrabKey calls here
This commit is contained in:
parent
532f132194
commit
d1eadee922
8
calmwm.c
8
calmwm.c
@ -144,7 +144,6 @@ dpy_init(const char *dpyname)
|
|||||||
static void
|
static void
|
||||||
x_setup(void)
|
x_setup(void)
|
||||||
{
|
{
|
||||||
struct keybinding *kb;
|
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
Cursor_default = XCreateFontCursor(X_Dpy, XC_X_cursor);
|
Cursor_default = XCreateFontCursor(X_Dpy, XC_X_cursor);
|
||||||
@ -155,13 +154,6 @@ x_setup(void)
|
|||||||
|
|
||||||
for (i = 0; i < ScreenCount(X_Dpy); i++)
|
for (i = 0; i < ScreenCount(X_Dpy); i++)
|
||||||
screen_init(i);
|
screen_init(i);
|
||||||
|
|
||||||
/*
|
|
||||||
* XXX key grabs weren't done before, since Screenq was empty,
|
|
||||||
* do them here for now (this needs changing).
|
|
||||||
*/
|
|
||||||
TAILQ_FOREACH(kb, &Conf.keybindingq, entry)
|
|
||||||
conf_grab(&Conf, kb);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
4
conf.c
4
conf.c
@ -98,6 +98,7 @@ static char *color_binds[CWM_COLOR_MAX] = {
|
|||||||
void
|
void
|
||||||
conf_screen(struct screen_ctx *sc)
|
conf_screen(struct screen_ctx *sc)
|
||||||
{
|
{
|
||||||
|
struct keybinding *kb;
|
||||||
int i;
|
int i;
|
||||||
XftColor xc;
|
XftColor xc;
|
||||||
|
|
||||||
@ -139,6 +140,9 @@ conf_screen(struct screen_ctx *sc)
|
|||||||
sc->visual, sc->colormap);
|
sc->visual, sc->colormap);
|
||||||
if (sc->xftdraw == NULL)
|
if (sc->xftdraw == NULL)
|
||||||
errx(1, "XftDrawCreate");
|
errx(1, "XftDrawCreate");
|
||||||
|
|
||||||
|
TAILQ_FOREACH(kb, &Conf.keybindingq, entry)
|
||||||
|
xu_key_grab(sc->rootwin, kb->modmask, kb->keysym);
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct {
|
static struct {
|
||||||
|
Loading…
Reference in New Issue
Block a user