41 lines
1.2 KiB
C
41 lines
1.2 KiB
C
//
|
|
// Created by anas on 10/31/22.
|
|
//
|
|
|
|
#ifndef MOUSE_H
|
|
#define MOUSE_H
|
|
|
|
#include <X11/X.h>
|
|
|
|
typedef struct {
|
|
unsigned int click;
|
|
unsigned int mask;
|
|
unsigned int button;
|
|
|
|
void (*func)(const Arg *arg);
|
|
|
|
const Arg arg;
|
|
} Button;
|
|
|
|
enum {
|
|
ClkTagBar, ClkLtSymbol, ClkStatusText, ClkWinTitle,
|
|
ClkClientWin, ClkRootWin, ClkLast
|
|
}; /* clicks */
|
|
|
|
/* button definitions */
|
|
/* click can be ClkTagBar, ClkLtSymbol, ClkStatusText, ClkWinTitle, ClkClientWin, or ClkRootWin */
|
|
static Button buttons[] = {
|
|
/* click event mask button function argument */
|
|
{ClkTagBar, MODKEY, Button1, tag, {0}},
|
|
{ClkTagBar, MODKEY, Button3, toggletag, {0}},
|
|
{ClkClientWin, MODKEY, Button1, movemouse, {0}},
|
|
{ClkClientWin, MODKEY, Button2, togglefloating, {0}},
|
|
{ClkClientWin, MODKEY, Button3, resizemouse, {0}},
|
|
{ClkTagBar, 0, Button1, view, {0}},
|
|
{ClkTagBar, 0, Button3, toggleview, {0}},
|
|
{ClkTagBar, MODKEY, Button1, tag, {0}},
|
|
{ClkTagBar, MODKEY, Button3, toggletag, {0}},
|
|
};
|
|
|
|
#endif //MOUSE_H
|