]> Dogcows Code - chaz/openbox/blob - src/xeventhandler.cc
cbca039d3915d921edb247d795c854672b6c4517
[chaz/openbox] / src / xeventhandler.cc
1 // -*- mode: C++; indent-tabs-mode: nil; -*-
2
3 #include "xeventhandler.hh"
4 #include "otk/display.hh"
5 #include "otk/rect.hh"
6
7 namespace ob {
8
9
10 OBXEventHandler::OBXEventHandler()
11 {
12 _lasttime = 1; // 0 is CurrentTime, so set to minimum
13 }
14
15 void OBXEventHandler::buttonPress(const XButtonEvent &e)
16 {
17 _lasttime = e.time;
18
19 }
20
21
22 void OBXEventHandler::buttonRelease(const XButtonEvent &e)
23 {
24 _lasttime = e.time;
25
26 }
27
28
29 void OBXEventHandler::keyPress(const XKeyEvent &e)
30 {
31 _lasttime = e.time;
32 }
33
34
35 void OBXEventHandler::motion(const XMotionEvent &e)
36 {
37 _lasttime = e.time;
38
39 // the pointer is on the wrong screen
40 if (! e.same_screen) return;
41
42 }
43
44
45 void OBXEventHandler::enterNotify(const XCrossingEvent &e)
46 {
47 _lasttime = e.time;
48 /*
49 BScreen *screen = (BScreen *) 0;
50 BlackboxWindow *win = (BlackboxWindow *) 0;
51
52 if (e->xcrossing.mode == NotifyGrab) break;
53
54 if ((e->xcrossing.window == e->xcrossing.root) &&
55 (screen = searchScreen(e->xcrossing.window))) {
56 screen->getImageControl()->installRootColormap();
57 } else if ((win = searchWindow(e->xcrossing.window))) {
58 if (! no_focus)
59 win->enterNotifyEvent(&e->xcrossing);
60 }
61 */
62 }
63
64
65 void OBXEventHandler::leaveNotify(const XCrossingEvent &e)
66 {
67 _lasttime = e.time;
68 /*
69 BlackboxWindow *win = (BlackboxWindow *) 0;
70
71 if ((win = searchWindow(e->xcrossing.window)))
72 win->leaveNotifyEvent(&e->xcrossing);
73 */
74 }
75
76
77 void OBXEventHandler::configureRequest(const XConfigureRequestEvent &e)
78 {
79 (void)e;
80 /* BlackboxWindow *win = (BlackboxWindow *) 0;
81
82 if ((win = searchWindow(e->xconfigurerequest.window))) {
83 win->configureRequestEvent(&e->xconfigurerequest);
84 } else {
85 if (validateWindow(e->xconfigurerequest.window)) {
86 XWindowChanges xwc;
87
88 xwc.x = e->xconfigurerequest.x;
89 xwc.y = e->xconfigurerequest.y;
90 xwc.width = e->xconfigurerequest.width;
91 xwc.height = e->xconfigurerequest.height;
92 xwc.border_width = e->xconfigurerequest.border_width;
93 xwc.sibling = e->xconfigurerequest.above;
94 xwc.stack_mode = e->xconfigurerequest.detail;
95
96 XConfigureWindow(otk::OBDisplay::display, e->xconfigurerequest.window,
97 e->xconfigurerequest.value_mask, &xwc);
98 }
99 }
100 */
101 }
102
103
104 void OBXEventHandler::mapRequest(const XMapRequestEvent &e)
105 {
106 #ifdef DEBUG
107 printf("MapRequest for 0x%lx\n", e.window);
108 #endif // DEBUG
109 /*
110 BlackboxWindow *win = searchWindow(e->xmaprequest.window);
111
112 if (win) {
113 bool focus = False;
114 if (win->isIconic()) {
115 win->deiconify();
116 focus = True;
117 }
118 if (win->isShaded()) {
119 win->shade();
120 focus = True;
121 }
122
123 if (focus && (win->isTransient() || win->getScreen()->doFocusNew()) &&
124 win->isVisible())
125 win->setInputFocus();
126 } else {
127 BScreen *screen = searchScreen(e->xmaprequest.parent);
128
129 if (! screen) {
130 */
131 /*
132 we got a map request for a window who's parent isn't root. this
133 can happen in only one circumstance:
134
135 a client window unmapped a managed window, and then remapped it
136 somewhere between unmapping the client window and reparenting it
137 to root.
138
139 regardless of how it happens, we need to find the screen that
140 the window is on
141 */
142 /*
143 XWindowAttributes wattrib;
144 if (! XGetWindowAttributes(otk::OBDisplay::display,
145 e->xmaprequest.window,
146 &wattrib)) {
147 // failed to get the window attributes, perhaps the window has
148 // now been destroyed?
149 break;
150 }
151
152 screen = searchScreen(wattrib.root);
153 assert(screen != 0); // this should never happen
154 }
155 screen->manageWindow(e->xmaprequest.window);
156 }
157 */
158 }
159
160
161 void OBXEventHandler::unmapNotify(const XUnmapEvent &e)
162 {
163 (void)e;
164 /*
165 BlackboxWindow *win = (BlackboxWindow *) 0;
166 BScreen *screen = (BScreen *) 0;
167
168 if ((win = searchWindow(e->xunmap.window))) {
169 win->unmapNotifyEvent(&e->xunmap);
170 } else if ((screen = searchSystrayWindow(e->xunmap.window))) {
171 screen->removeSystrayWindow(e->xunmap.window);
172 }
173 */
174 }
175
176
177 void OBXEventHandler::destroyNotify(const XDestroyWindowEvent &e)
178 {
179 (void)e;
180 /*
181 BlackboxWindow *win = (BlackboxWindow *) 0;
182 BScreen *screen = (BScreen *) 0;
183 BWindowGroup *group = (BWindowGroup *) 0;
184
185 if ((win = searchWindow(e->xdestroywindow.window))) {
186 win->destroyNotifyEvent(&e->xdestroywindow);
187 } else if ((group = searchGroup(e->xdestroywindow.window))) {
188 delete group;
189 } else if ((screen = searchSystrayWindow(e->xunmap.window))) {
190 screen->removeSystrayWindow(e->xunmap.window);
191 }
192 */
193 }
194
195
196 void OBXEventHandler::reparentNotify(const XReparentEvent &e)
197 {
198 (void)e;
199 /*
200 this event is quite rare and is usually handled in unmapNotify
201 however, if the window is unmapped when the reparent event occurs
202 the window manager never sees it because an unmap event is not sent
203 to an already unmapped window.
204 */
205 /*
206 BlackboxWindow *win = searchWindow(e->xreparent.window);
207 if (win)
208 win->reparentNotifyEvent(&e->xreparent);
209 */
210 }
211
212
213 void OBXEventHandler::propertyNotify(const XPropertyEvent &e)
214 {
215 _lasttime = e.time;
216 /*
217 BlackboxWindow *win = (BlackboxWindow *) 0;
218 BScreen *screen = (BScreen *) 0;
219
220 if ((win = searchWindow(e->xproperty.window)))
221 win->propertyNotifyEvent(&e->xproperty);
222 else if ((screen = searchScreen(e->xproperty.window)))
223 screen->propertyNotifyEvent(&e->xproperty);
224 */
225 }
226
227
228 void OBXEventHandler::expose(const XExposeEvent &first)
229 {
230 // compress expose events
231 XEvent e; e.xexpose = first;
232 unsigned int i = 0;
233 otk::Rect area(e.xexpose.x, e.xexpose.y, e.xexpose.width,
234 e.xexpose.height);
235 while (XCheckTypedWindowEvent(otk::OBDisplay::display,
236 e.xexpose.window, Expose, &e)) {
237 i++;
238 // merge expose area
239 area |= otk::Rect(e.xexpose.x, e.xexpose.y, e.xexpose.width,
240 e.xexpose.height);
241 }
242 if ( i > 0 ) {
243 // use the merged area
244 e.xexpose.x = area.x();
245 e.xexpose.y = area.y();
246 e.xexpose.width = area.width();
247 e.xexpose.height = area.height();
248 }
249 /*
250 BlackboxWindow *win = (BlackboxWindow *) 0;
251
252 if ((win = searchWindow(e->xexpose.window)))
253 win->exposeEvent(&e->xexpose);
254 */
255 }
256
257
258 void OBXEventHandler::colormapNotify(const XColormapEvent &e)
259 {
260 (void)e;
261 /*
262 BScreen *screen = searchScreen(e->xcolormap.window);
263 if (screen)
264 screen->setRootColormapInstalled((e->xcolormap.state ==
265 ColormapInstalled) ? True : False);
266 */
267 }
268
269
270 void OBXEventHandler::focusIn(const XFocusChangeEvent &e)
271 {
272 if (e.detail != NotifyNonlinear &&
273 e.detail != NotifyAncestor) {
274 /*
275 don't process FocusIns when:
276 1. the new focus window isn't an ancestor or inferior of the old
277 focus window (NotifyNonlinear)
278 make sure to allow the FocusIn when the old focus window was an
279 ancestor but didn't have a parent, such as root (NotifyAncestor)
280 */
281 return;
282 }
283 /*
284 BlackboxWindow *win = searchWindow(e.window);
285 if (win) {
286 if (! win->isFocused())
287 win->setFocusFlag(True);
288 */
289 /*
290 set the event window to None. when the FocusOut event handler calls
291 this function recursively, it uses this as an indication that focus
292 has moved to a known window.
293 */
294 /*
295 e->xfocus.window = None;
296
297 no_focus = False; // focusing is back on
298 }
299 */
300 }
301
302
303 void OBXEventHandler::focusOut(const XFocusChangeEvent &e)
304 {
305 if (e.detail != NotifyNonlinear) {
306 /*
307 don't process FocusOuts when:
308 2. the new focus window isn't an ancestor or inferior of the old
309 focus window (NotifyNonlinear)
310 */
311 return;
312 }
313
314 /*
315 BlackboxWindow *win = searchWindow(e->xfocus.window);
316 if (win && win->isFocused()) {
317 */
318 /*
319 before we mark "win" as unfocused, we need to verify that focus is
320 going to a known location, is in a known location, or set focus
321 to a known location.
322 */
323 /*
324 XEvent event;
325 // don't check the current focus if FocusOut was generated during a grab
326 bool check_focus = (e->xfocus.mode == NotifyNormal);
327 */
328 /*
329 First, check if there is a pending FocusIn event waiting. if there
330 is, process it and determine if focus has moved to another window
331 (the FocusIn event handler sets the window in the event
332 structure to None to indicate this).
333 */
334 /*
335 if (XCheckTypedEvent(otk::OBDisplay::display, FocusIn, &event)) {
336
337 process_event(&event);
338 if (event.xfocus.window == None) {
339 // focus has moved
340 check_focus = False;
341 }
342 }
343
344 if (check_focus) {
345 */
346 /*
347 Second, we query the X server for the current input focus.
348 to make sure that we keep a consistent state.
349 */
350 /*
351 BlackboxWindow *focus;
352 Window w;
353 int revert;
354 XGetInputFocus(otk::OBDisplay::display, &w, &revert);
355 focus = searchWindow(w);
356 if (focus) {
357 */
358 /*
359 focus got from "win" to "focus" under some very strange
360 circumstances, and we need to make sure that the focus indication
361 is correct.
362 */
363 /*
364 setFocusedWindow(focus);
365 } else {
366 // we have no idea where focus went... so we set it to somewhere
367 setFocusedWindow(0);
368 }
369 }
370 }
371 */
372 }
373
374
375 #ifdef SHAPE
376 void OBXEventHandler::shapeEvent(const XShapeEvent &e)
377 {
378 XShapeEvent *shape_event = (XShapeEvent *) e;
379 BlackboxWindow *win = searchWindow(e->xany.window);
380
381 if (win && shape_event->kind == ShapeBounding)
382 win->shapeEvent(shape_event);
383 }
384 #endif // SHAPE
385
386
387 void OBXEventHandler::clientMessage(const XClientMessageEvent &e)
388 {
389 if (e.format != 32)
390 return;
391 /*
392 if (e->xclient.message_type == xatom->getAtom(XAtom::wm_change_state)) {
393 // WM_CHANGE_STATE message
394 BlackboxWindow *win = searchWindow(e->xclient.window);
395 if (! win || ! win->validateClient()) return;
396
397 if (e->xclient.data.l[0] == IconicState)
398 win->iconify();
399 if (e->xclient.data.l[0] == NormalState)
400 win->deiconify();
401 } else if (e->xclient.message_type ==
402 xatom->getAtom(XAtom::blackbox_change_workspace) ||
403 e->xclient.message_type ==
404 xatom->getAtom(XAtom::net_current_desktop)) {
405 // NET_CURRENT_DESKTOP message
406 BScreen *screen = searchScreen(e->xclient.window);
407
408 unsigned int workspace = e->xclient.data.l[0];
409 if (screen && workspace < screen->getWorkspaceCount())
410 screen->changeWorkspaceID(workspace);
411 } else if (e->xclient.message_type ==
412 xatom->getAtom(XAtom::blackbox_change_window_focus)) {
413 // TEMP HACK TO KEEP BBKEYS WORKING
414 BlackboxWindow *win = searchWindow(e->xclient.window);
415
416 if (win && win->isVisible() && win->setInputFocus())
417 win->installColormap(True);
418 } else if (e->xclient.message_type ==
419 xatom->getAtom(XAtom::net_active_window)) {
420 // NET_ACTIVE_WINDOW
421 BlackboxWindow *win = searchWindow(e->xclient.window);
422
423 if (win) {
424 BScreen *screen = win->getScreen();
425
426 if (win->isIconic())
427 win->deiconify(False, False);
428 if (! win->isStuck() &&
429 (win->getWorkspaceNumber() != screen->getCurrentWorkspaceID())) {
430 no_focus = True;
431 screen->changeWorkspaceID(win->getWorkspaceNumber());
432 }
433 if (win->isVisible() && win->setInputFocus()) {
434 win->getScreen()->getWorkspace(win->getWorkspaceNumber())->
435 raiseWindow(win);
436 win->installColormap(True);
437 }
438 }
439 } else if (e->xclient.message_type ==
440 xatom->getAtom(XAtom::blackbox_cycle_window_focus)) {
441 // BLACKBOX_CYCLE_WINDOW_FOCUS
442 BScreen *screen = searchScreen(e->xclient.window);
443
444 if (screen) {
445 if (! e->xclient.data.l[0])
446 screen->prevFocus();
447 else
448 screen->nextFocus();
449 }
450 } else if (e->xclient.message_type ==
451 xatom->getAtom(XAtom::net_wm_desktop)) {
452 // NET_WM_DESKTOP
453 BlackboxWindow *win = searchWindow(e->xclient.window);
454
455 if (win) {
456 BScreen *screen = win->getScreen();
457 unsigned long wksp = (unsigned) e->xclient.data.l[0];
458 if (wksp < screen->getWorkspaceCount()) {
459 if (win->isIconic()) win->deiconify(False, True);
460 if (win->isStuck()) win->stick();
461 if (wksp != screen->getCurrentWorkspaceID())
462 win->withdraw();
463 else
464 win->show();
465 screen->reassociateWindow(win, wksp, True);
466 } else if (wksp == 0xfffffffe || // XXX: BUG, BUT DOING THIS SO KDE WORKS FOR NOW!!
467 wksp == 0xffffffff) {
468 if (win->isIconic()) win->deiconify(False, True);
469 if (! win->isStuck()) win->stick();
470 if (! win->isVisible()) win->show();
471 }
472 }
473 } else if (e->xclient.message_type ==
474 xatom->getAtom(XAtom::blackbox_change_attributes)) {
475 // BLACKBOX_CHANGE_ATTRIBUTES
476 BlackboxWindow *win = searchWindow(e->xclient.window);
477
478 if (win && win->validateClient()) {
479 BlackboxHints net;
480 net.flags = e->xclient.data.l[0];
481 net.attrib = e->xclient.data.l[1];
482 net.workspace = e->xclient.data.l[2];
483 net.stack = e->xclient.data.l[3];
484 net.decoration = e->xclient.data.l[4];
485
486 win->changeBlackboxHints(&net);
487 }
488 } else if (e->xclient.message_type ==
489 xatom->getAtom(XAtom::net_number_of_desktops)) {
490 // NET_NUMBER_OF_DESKTOPS
491 BScreen *screen = searchScreen(e->xclient.window);
492
493 if (e->xclient.data.l[0] > 0)
494 screen->changeWorkspaceCount((unsigned) e->xclient.data.l[0]);
495 } else if (e->xclient.message_type ==
496 xatom->getAtom(XAtom::net_close_window)) {
497 // NET_CLOSE_WINDOW
498 BlackboxWindow *win = searchWindow(e->xclient.window);
499 if (win && win->validateClient())
500 win->close(); // could this be smarter?
501 } else if (e->xclient.message_type ==
502 xatom->getAtom(XAtom::net_wm_moveresize)) {
503 // NET_WM_MOVERESIZE
504 BlackboxWindow *win = searchWindow(e->xclient.window);
505 if (win && win->validateClient()) {
506 int x_root = e->xclient.data.l[0],
507 y_root = e->xclient.data.l[1];
508 if ((Atom) e->xclient.data.l[2] ==
509 xatom->getAtom(XAtom::net_wm_moveresize_move)) {
510 win->beginMove(x_root, y_root);
511 } else {
512 if ((Atom) e->xclient.data.l[2] ==
513 xatom->getAtom(XAtom::net_wm_moveresize_size_topleft))
514 win->beginResize(x_root, y_root, BlackboxWindow::TopLeft);
515 else if ((Atom) e->xclient.data.l[2] ==
516 xatom->getAtom(XAtom::net_wm_moveresize_size_topright))
517 win->beginResize(x_root, y_root, BlackboxWindow::TopRight);
518 else if ((Atom) e->xclient.data.l[2] ==
519 xatom->getAtom(XAtom::net_wm_moveresize_size_bottomleft))
520 win->beginResize(x_root, y_root, BlackboxWindow::BottomLeft);
521 else if ((Atom) e->xclient.data.l[2] ==
522 xatom->getAtom(XAtom::net_wm_moveresize_size_bottomright))
523 win->beginResize(x_root, y_root, BlackboxWindow::BottomRight);
524 }
525 }
526 } else if (e->xclient.message_type ==
527 xatom->getAtom(XAtom::net_wm_state)) {
528 // NET_WM_STATE
529 BlackboxWindow *win = searchWindow(e->xclient.window);
530 if (win && win->validateClient()) {
531 const Atom action = (Atom) e->xclient.data.l[0];
532 const Atom state[] = { (Atom) e->xclient.data.l[1],
533 (Atom) e->xclient.data.l[2] };
534
535 for (int i = 0; i < 2; ++i) {
536 if (! state[i])
537 continue;
538
539 if ((Atom) e->xclient.data.l[0] == 1) {
540 // ADD
541 if (state[i] == xatom->getAtom(XAtom::net_wm_state_modal)) {
542 win->setModal(True);
543 } else if (state[i] ==
544 xatom->getAtom(XAtom::net_wm_state_maximized_vert)) {
545 if (win->isMaximizedHoriz()) {
546 win->maximize(0); // unmaximize
547 win->maximize(1); // full
548 } else if (! win->isMaximized()) {
549 win->maximize(2); // vert
550 }
551 } else if (state[i] ==
552 xatom->getAtom(XAtom::net_wm_state_maximized_horz)) {
553 if (win->isMaximizedVert()) {
554 win->maximize(0); // unmaximize
555 win->maximize(1); // full
556 } else if (! win->isMaximized()) {
557 win->maximize(3); // horiz
558 }
559 } else if (state[i] ==
560 xatom->getAtom(XAtom::net_wm_state_shaded)) {
561 if (! win->isShaded())
562 win->shade();
563 } else if (state[i] ==
564 xatom->getAtom(XAtom::net_wm_state_skip_taskbar)) {
565 win->setSkipTaskbar(True);
566 } else if (state[i] ==
567 xatom->getAtom(XAtom::net_wm_state_skip_pager)) {
568 win->setSkipPager(True);
569 } else if (state[i] ==
570 xatom->getAtom(XAtom::net_wm_state_fullscreen)) {
571 win->setFullscreen(True);
572 }
573 } else if (action == 0) {
574 // REMOVE
575 if (state[i] == xatom->getAtom(XAtom::net_wm_state_modal)) {
576 win->setModal(False);
577 } else if (state[i] ==
578 xatom->getAtom(XAtom::net_wm_state_maximized_vert)) {
579 if (win->isMaximizedFull()) {
580 win->maximize(0); // unmaximize
581 win->maximize(3); // horiz
582 } else if (win->isMaximizedVert()) {
583 win->maximize(0); // unmaximize
584 }
585 } else if (state[i] ==
586 xatom->getAtom(XAtom::net_wm_state_maximized_horz)) {
587 if (win->isMaximizedFull()) {
588 win->maximize(0); // unmaximize
589 win->maximize(2); // vert
590 } else if (win->isMaximizedHoriz()) {
591 win->maximize(0); // unmaximize
592 }
593 } else if (state[i] ==
594 xatom->getAtom(XAtom::net_wm_state_shaded)) {
595 if (win->isShaded())
596 win->shade();
597 } else if (state[i] ==
598 xatom->getAtom(XAtom::net_wm_state_skip_taskbar)) {
599 win->setSkipTaskbar(False);
600 } else if (state[i] ==
601 xatom->getAtom(XAtom::net_wm_state_skip_pager)) {
602 win->setSkipPager(False);
603 } else if (state[i] ==
604 xatom->getAtom(XAtom::net_wm_state_fullscreen)) {
605 win->setFullscreen(False);
606 }
607 } else if (action == 2) {
608 // TOGGLE
609 if (state[i] == xatom->getAtom(XAtom::net_wm_state_modal)) {
610 win->setModal(! win->isModal());
611 } else if (state[i] ==
612 xatom->getAtom(XAtom::net_wm_state_maximized_vert)) {
613 if (win->isMaximizedFull()) {
614 win->maximize(0); // unmaximize
615 win->maximize(3); // horiz
616 } else if (win->isMaximizedVert()) {
617 win->maximize(0); // unmaximize
618 } else if (win->isMaximizedHoriz()) {
619 win->maximize(0); // unmaximize
620 win->maximize(1); // full
621 } else {
622 win->maximize(2); // vert
623 }
624 } else if (state[i] ==
625 xatom->getAtom(XAtom::net_wm_state_maximized_horz)) {
626 if (win->isMaximizedFull()) {
627 win->maximize(0); // unmaximize
628 win->maximize(2); // vert
629 } else if (win->isMaximizedHoriz()) {
630 win->maximize(0); // unmaximize
631 } else if (win->isMaximizedVert()) {
632 win->maximize(0); // unmaximize
633 win->maximize(1); // full
634 } else {
635 win->maximize(3); // horiz
636 }
637 } else if (state[i] ==
638 xatom->getAtom(XAtom::net_wm_state_shaded)) {
639 win->shade();
640 } else if (state[i] ==
641 xatom->getAtom(XAtom::net_wm_state_skip_taskbar)) {
642 win->setSkipTaskbar(! win->skipTaskbar());
643 } else if (state[i] ==
644 xatom->getAtom(XAtom::net_wm_state_skip_pager)) {
645 win->setSkipPager(! win->skipPager());
646 } else if (state[i] ==
647 xatom->getAtom(XAtom::net_wm_state_fullscreen)) {
648 win->setFullscreen(! win->isFullscreen());
649 }
650 }
651 }
652 }
653 }
654 */
655 }
656
657
658 void OBXEventHandler::handle(const XEvent &e)
659 {
660 /* mouse button events can get translated into:
661 press - button was pressed down
662 release - buttons was released
663 click - button was pressed and released on the same window
664 double click - clicked twice on the same widget in a given time and area
665
666 key events are only bindable to presses. key releases are ignored.
667
668 mouse enter/leave can be bound to for the entire window
669 */
670
671 switch (e.type) {
672
673 // These types of XEvent's can be bound to actions by the user, and so end
674 // up getting passed off to the OBBindingMapper class at some point
675 case ButtonPress:
676 buttonPress(e.xbutton);
677 break;
678 case ButtonRelease:
679 buttonRelease(e.xbutton);
680 break;
681 case KeyPress:
682 keyPress(e.xkey);
683 break;
684 case MotionNotify:
685 motion(e.xmotion);
686 break;
687 case EnterNotify:
688 enterNotify(e.xcrossing);
689 break;
690 case LeaveNotify:
691 leaveNotify(e.xcrossing);
692 break;
693
694
695 // These types of XEvent's can not be bound to actions by the user and so
696 // will simply be handled in this class
697 case ConfigureRequest:
698 configureRequest(e.xconfigurerequest);
699 break;
700
701 case MapRequest:
702 mapRequest(e.xmaprequest);
703 break;
704
705 case UnmapNotify:
706 unmapNotify(e.xunmap);
707 break;
708
709 case DestroyNotify:
710 destroyNotify(e.xdestroywindow);
711 break;
712
713 case ReparentNotify:
714 reparentNotify(e.xreparent);
715 break;
716
717 case PropertyNotify:
718 propertyNotify(e.xproperty);
719 break;
720
721 case Expose:
722 expose(e.xexpose);
723 break;
724
725 case ColormapNotify:
726 colormapNotify(e.xcolormap);
727 break;
728
729 case FocusIn:
730 focusIn(e.xfocus);
731 break;
732
733 case FocusOut:
734 focusOut(e.xfocus);
735 break;
736
737 case ClientMessage:
738 clientMessage(e.xclient);
739
740 default:
741 #ifdef SHAPE
742 if (e.type == otk::OBDisplay::shapeEventBase())
743 shapeEvent(e);
744 #endif // SHAPE
745 break;
746
747 /*
748 case ClientMessage: {
749 break;
750 }
751
752 */
753 } // switch
754 }
755
756
757 }
This page took 0.064467 seconds and 3 git commands to generate.