wmbutton: Middle button enabled by default
The mouse middle button should be enabled by default (see the help and the manpage). This patch solves this bug. The MIDMOUSE definition is removed because the value of MIDMOUSE changes the middle button behaviour. Now, the middle button always works, except if the user uses the -m argument. Now the manpage and the help show the same info.
This commit is contained in:
parent
991c54732d
commit
cc68392ccb
|
@ -116,11 +116,7 @@ void show_usage() {
|
|||
fprintf(stderr,"-F <font> Custom tooltip font (e.g. -b\\&h-lucidatypewriter-medium-*-*-*-12-*)\n");
|
||||
fprintf(stderr,"-v Verbose Mode.\n");
|
||||
fprintf(stderr,"-h Help. This message.\n");
|
||||
#if MIDMOUSE
|
||||
fprintf(stderr,"-m Disable Middle Mouse functionality.\n");
|
||||
#else
|
||||
fprintf(stderr,"-m Enable Middle Mouse functionality.\n");
|
||||
#endif
|
||||
fprintf(stderr,"-s Swap tooltip colors.\n");
|
||||
fprintf(stderr,"-n Turn off tooltips.\n");
|
||||
fprintf(stderr,"\n");
|
||||
|
|
|
@ -296,7 +296,7 @@ int main(int argc, char **argv)
|
|||
break;
|
||||
|
||||
case Button2:
|
||||
if (Config.mmouse) {
|
||||
if (!Config.mmouse) {
|
||||
N = whichButton(report.xbutton.x, report.xbutton.y);
|
||||
if ((N >= 0) && (N <= NUMB_OF_APPS)) {
|
||||
button_pressed = N + MMASK;
|
||||
|
@ -339,7 +339,7 @@ int main(int argc, char **argv)
|
|||
break;
|
||||
|
||||
case Button2:
|
||||
if (Config.mmouse) {
|
||||
if (!Config.mmouse) {
|
||||
N = whichButton(report.xbutton.x, report.xbutton.y);
|
||||
if ((N >= 0) && (N <= NUMB_OF_APPS) && (N == button_pressed))
|
||||
RunAppN(N + MMASK);
|
||||
|
|
|
@ -36,7 +36,6 @@
|
|||
|
||||
/****** Define Other Options ****************************************/
|
||||
#define VERB 0 /* Enable=1, Disable=0: Debugging (verbose) Mode*/
|
||||
#define MIDMOUSE 1 /* Define Middle Mouse functionality */
|
||||
#define LMASK 0 /* left button mask: run app # mask + button #*/
|
||||
#define MMASK 10 /* middle button mask: run app # mask + button #*/
|
||||
#define RMASK 20 /* right button mask: run app # mask + button #*/
|
||||
|
|
Loading…
Reference in a new issue