dont grab client context stuff on desktop windows. check that clint is non-null

This commit is contained in:
Dana Jansens 2003-08-20 15:50:12 +00:00
parent 6375df675f
commit 9e3d680cf7

View file

@ -17,9 +17,9 @@ typedef struct {
GSList *actions[OB_MOUSE_NUM_ACTIONS]; /* lists of Action pointers */ GSList *actions[OB_MOUSE_NUM_ACTIONS]; /* lists of Action pointers */
} ObMouseBinding; } ObMouseBinding;
#define CLIENT_CONTEXT(co, cl) (co == OB_FRAME_CONTEXT_CLIENT || \ #define CLIENT_CONTEXT(co, cl) ((cl && cl->type == OB_CLIENT_TYPE_DESKTOP) ? \
(co == OB_FRAME_CONTEXT_ROOT && \ co == OB_FRAME_CONTEXT_ROOT : \
cl->type == OB_CLIENT_TYPE_DESKTOP)) co == OB_FRAME_CONTEXT_CLIENT)
/* Array of GSList*s of PointerBinding*s. */ /* Array of GSList*s of PointerBinding*s. */
static GSList *bound_contexts[OB_FRAME_NUM_CONTEXTS]; static GSList *bound_contexts[OB_FRAME_NUM_CONTEXTS];