/[oroborus]/oroborus/src/events.c
ViewVC logotype

Diff of /oroborus/src/events.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by dreamind, Thu May 30 13:57:51 2002 UTC revision 1.3 by dreamind, Sun Jun 9 22:15:13 2002 UTC
# Line 29  handleKeyPress (XKeyEvent * ev) Line 29  handleKeyPress (XKeyEvent * ev)
29    Client *c;    Client *c;
30    int state, key;    int state, key;
31    XEvent e;    XEvent e;
32      XWindowChanges wc;
33    
34  #ifdef DEBUG  #ifdef DEBUG
35    printf ("entering handleKeyEvent\n");    printf ("entering handleKeyEvent\n");
# Line 56  handleKeyPress (XKeyEvent * ev) Line 57  handleKeyPress (XKeyEvent * ev)
57              XWarpPointer (dpy, None, c->window, 0, 0, 0, 0,              XWarpPointer (dpy, None, c->window, 0, 0, 0, 0,
58                            frameWidth (c) / 2, frameHeight (c) / 2);                            frameWidth (c) / 2, frameHeight (c) / 2);
59            break;            break;
60                case KEY_TOP_LEFT:
61                    wc.x = frameLeft(c) + margins[MARGIN_LEFT];
62                    wc.y = frameTop(c) + margins[MARGIN_TOP];
63                    clientConfigure (c, &wc, CWX | CWY);
64                    if (!click_to_focus)
65                        XWarpPointer (dpy, None, c->window, 0, 0, 0, 0,
66                                      frameWidth (c) / 2, frameHeight (c) / 2);
67                    break;
68                case KEY_TOP_RIGHT:
69                    wc.x = XDisplayWidth(dpy, screen) - c->width - frameRight(c) - margins[MARGIN_RIGHT];
70                    wc.y = frameTop(c) + margins[MARGIN_TOP];
71                    clientConfigure (c, &wc, CWX | CWY);
72                    if (!click_to_focus)
73                        XWarpPointer (dpy, None, c->window, 0, 0, 0, 0,
74                                      frameWidth (c) / 2, frameHeight (c) / 2);
75                    break;
76                case KEY_BOTTOM_LEFT:
77                    wc.x = frameLeft(c) + margins[MARGIN_LEFT];
78                    wc.y = XDisplayHeight(dpy, screen) - c->height - frameBottom(c) - margins[MARGIN_BOTTOM];
79                    clientConfigure (c, &wc, CWX | CWY);
80                    if (!click_to_focus)
81                        XWarpPointer (dpy, None, c->window, 0, 0, 0, 0,
82                                      frameWidth (c) / 2, frameHeight (c) / 2);
83                    break;
84                case KEY_BOTTOM_RIGHT:
85                    wc.x = XDisplayWidth(dpy, screen) - c->width - frameRight(c) - margins[MARGIN_RIGHT];
86                    wc.y = XDisplayHeight(dpy, screen) - c->height - frameBottom(c) - margins[MARGIN_BOTTOM];
87                    clientConfigure (c, &wc, CWX | CWY);
88                    if (!click_to_focus)
89                        XWarpPointer (dpy, None, c->window, 0, 0, 0, 0,
90                                      frameWidth (c) / 2, frameHeight (c) / 2);
91                    break;
92          case KEY_RESIZE_UP:          case KEY_RESIZE_UP:
93          case KEY_RESIZE_DOWN:          case KEY_RESIZE_DOWN:
94          case KEY_RESIZE_LEFT:          case KEY_RESIZE_LEFT:

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26