started to reduce globals, set signal handlers after everything used in them initialized
This commit is contained in:
@ -1,10 +1,10 @@
|
||||
#include "event.h"
|
||||
|
||||
//this should be initialized by main.cpp as soon as the program starts.
|
||||
Display* display = 0;
|
||||
Display *display = 0;
|
||||
|
||||
//actually creates an XWindows event :)
|
||||
void sendevent( xevent e ) {
|
||||
void sendevent( Display* display, xevent e ) {
|
||||
if (e.value1 == 0 && e.value2 == 0) return;
|
||||
if (e.type == WARP) {
|
||||
XTestFakeRelativeMotionEvent(display, e.value1, e.value2, 0);
|
||||
|
Reference in New Issue
Block a user