diff options
| author | Marius Nita <marius@cs.pdx.edu> | 2002-11-16 02:11:44 +0000 |
|---|---|---|
| committer | Marius Nita <marius@cs.pdx.edu> | 2002-11-16 02:11:44 +0000 |
| commit | e53fbcf092c40b22ccc4c5f23795e12c9862c338 (patch) | |
| tree | 1af236afed9fba729d9220f26e8edcd9e64cc470 /otk/eventhandler.cc | |
| parent | 1210e6d688b62aceec2395bd3833e7c280d57326 (diff) | |
event handling classes
Diffstat (limited to 'otk/eventhandler.cc')
| -rw-r--r-- | otk/eventhandler.cc | 84 |
1 files changed, 84 insertions, 0 deletions
diff --git a/otk/eventhandler.cc b/otk/eventhandler.cc new file mode 100644 index 00000000..27ad5e73 --- /dev/null +++ b/otk/eventhandler.cc @@ -0,0 +1,84 @@ +#include "eventhandler.hh" + +namespace otk { + +OtkEventHandler::OtkEventHandler() +{ +} + + +OtkEventHandler::~OtkEventHandler() +{ +} + + +int OtkEventHandler::handle(const XEvent &e) +{ + switch(e.type){ + case KeyPress: + return keyPressHandler(e.xkey); + case KeyRelease: + return keyReleaseHandler(e.xkey); + case ButtonPress: + return buttonPressHandler(e.xbutton); + case ButtonRelease: + return buttonReleaseHandler(e.xbutton); + case EnterNotify: + return enterHandler(e.xcrossing); + case LeaveNotify: + return leaveHandler(e.xcrossing); + case FocusIn: + return focusHandler(e.xfocus); + case FocusOut: + return unfocusHandler(e.xfocus); + case Expose: + return exposeHandler(e.xexpose); + case GraphicsExpose: + return graphicsExposeHandler(e.xgraphicsexpose); + case NoExpose: + return noExposeEventHandler(e.xnoexpose); + case CirculateRequest: + return circulateRequestHandler(e.xcirculaterequest); + case ConfigureRequest: + return configureRequestHandler(e.xconfigurerequest); + case MapRequest: + return mapRequestHandler(e.xmaprequest); + case ResizeRequest: + return resizeRequestHandler(e.xresizerequest); + case CirculateNotify: + return circulateHandler(e.xcirculate); + case ConfigureNotify: + return configureHandler(e.xconfigure); + case CreateNotify: + return createHandler(e.xcreatewindow); + case DestroyNotify: + return destroyHandler(e.xdestroywindow); + case GravityNotify: + return gravityHandler(e.xgravity); + case MapNotify: + return mapHandler(e.xmap); + case MappingNotify: + return mappingHandler(e.xmapping); + case ReparentNotify: + return reparentHandler(e.xreparent); + case UnmapNotify: + return unmapHandler(e.xunmap); + case VisibilityNotify: + return visibilityHandler(e.xvisibility); + case ColormapNotify: + return colorMapHandler(e.xcolormap); + case ClientMessage: + return clientMessageHandler(e.xclient); + case PropertyNotify: + return propertyHandler(e.xproperty); + case SelectionClear: + return selectionClearHandler(e.xselectionclear); + case SelectionNotify: + return selectionHandler(e.xselection); + case SelectionRequest: + return selectionRequestHandler(e.xselectionrequest); + }; + return 0; +} + +} |
