… | |
… | |
26 | * Copyright (c) 1998 Alfredo K. Kojima <kojima@windowmaker.org> |
26 | * Copyright (c) 1998 Alfredo K. Kojima <kojima@windowmaker.org> |
27 | * Copyright (c) 2001 Marius Gedminas |
27 | * Copyright (c) 2001 Marius Gedminas |
28 | * - Ctrl/Mod4+Tab works like Meta+Tab (options) |
28 | * - Ctrl/Mod4+Tab works like Meta+Tab (options) |
29 | * Copyright (c) 2003 Rob McMullen <robm@flipturn.org> |
29 | * Copyright (c) 2003 Rob McMullen <robm@flipturn.org> |
30 | * Copyright (c) 2003-2007 Marc Lehmann <pcg@goof.com> |
30 | * Copyright (c) 2003-2007 Marc Lehmann <pcg@goof.com> |
|
|
31 | * Copyright (c) 2007 Emanuele Giaquinta <e.giaquinta@glauco.it> |
31 | * |
32 | * |
32 | * This program is free software; you can redistribute it and/or modify |
33 | * This program is free software; you can redistribute it and/or modify |
33 | * it under the terms of the GNU General Public License as published by |
34 | * it under the terms of the GNU General Public License as published by |
34 | * the Free Software Foundation; either version 2 of the License, or |
35 | * the Free Software Foundation; either version 2 of the License, or |
35 | * (at your option) any later version. |
36 | * (at your option) any later version. |
… | |
… | |
1529 | while (XCheckTypedWindowEvent (dpy, ev.xany.window, Expose, &unused_event)) |
1530 | while (XCheckTypedWindowEvent (dpy, ev.xany.window, Expose, &unused_event)) |
1530 | ; |
1531 | ; |
1531 | while (XCheckTypedWindowEvent (dpy, ev.xany.window, GraphicsExpose, &unused_event)) |
1532 | while (XCheckTypedWindowEvent (dpy, ev.xany.window, GraphicsExpose, &unused_event)) |
1532 | ; |
1533 | ; |
1533 | |
1534 | |
1534 | if (isScrollbarWindow (ev.xany.window)) |
1535 | if (scrollBar.state && ev.xany.window == scrollBar.win) |
1535 | { |
1536 | { |
1536 | scrollBar.setIdle (); |
1537 | scrollBar.setIdle (); |
1537 | scrollbar_show (0); |
1538 | scrollbar_show (0); |
1538 | } |
1539 | } |
1539 | } |
1540 | } |
… | |
… | |
1629 | #ifdef MOUSE_THRESHOLD |
1630 | #ifdef MOUSE_THRESHOLD |
1630 | } |
1631 | } |
1631 | #endif |
1632 | #endif |
1632 | } |
1633 | } |
1633 | } |
1634 | } |
1634 | else if (isScrollbarWindow (ev.xany.window) && scrollbar_isMotion ()) |
1635 | else if (scrollbar_isMotion () && ev.xany.window == scrollBar.win) |
1635 | { |
1636 | { |
1636 | while (XCheckTypedWindowEvent (dpy, scrollBar.win, |
1637 | while (XCheckTypedWindowEvent (dpy, scrollBar.win, |
1637 | MotionNotify, &ev)) |
1638 | MotionNotify, &ev)) |
1638 | ; |
1639 | ; |
1639 | |
1640 | |
… | |
… | |
1923 | } |
1924 | } |
1924 | |
1925 | |
1925 | /* |
1926 | /* |
1926 | * Scrollbar window processing of button press |
1927 | * Scrollbar window processing of button press |
1927 | */ |
1928 | */ |
1928 | if (isScrollbarWindow (ev.window)) |
1929 | if (scrollBar.state && ev.window == scrollBar.win) |
1929 | { |
1930 | { |
1930 | scrollBar.setIdle (); |
1931 | scrollBar.setIdle (); |
1931 | /* |
1932 | /* |
1932 | * Rxvt-style scrollbar: |
1933 | * Rxvt-style scrollbar: |
1933 | * move up if mouse is above slider |
1934 | * move up if mouse is above slider |
… | |
… | |
2169 | |
2170 | |
2170 | if (!slip_wheel_ev.is_active ()) |
2171 | if (!slip_wheel_ev.is_active ()) |
2171 | slip_wheel_ev.start (SCROLLBAR_CONTINUOUS_DELAY, SCROLLBAR_CONTINUOUS_DELAY); |
2172 | slip_wheel_ev.start (SCROLLBAR_CONTINUOUS_DELAY, SCROLLBAR_CONTINUOUS_DELAY); |
2172 | } |
2173 | } |
2173 | else |
2174 | else |
|
|
2175 | # endif |
2174 | { |
2176 | { |
2175 | # endif |
|
|
2176 | scr_page (v, i); |
2177 | scr_page (v, i); |
2177 | scrollbar_show (1); |
2178 | scrollbar_show (1); |
2178 | # ifdef MOUSE_SLIP_WHEELING |
|
|
2179 | } |
2179 | } |
2180 | # endif |
|
|
2181 | } |
2180 | } |
2182 | break; |
2181 | break; |
2183 | #endif |
2182 | #endif |
2184 | } |
2183 | } |
2185 | } |
2184 | } |
… | |
… | |
3671 | */ |
3670 | */ |
3672 | PrivMode (1, PrivMode_vt52); |
3671 | PrivMode (1, PrivMode_vt52); |
3673 | break; |
3672 | break; |
3674 | case 3: /* 80/132 */ |
3673 | case 3: /* 80/132 */ |
3675 | if (priv_modes & PrivMode_132OK) |
3674 | if (priv_modes & PrivMode_132OK) |
|
|
3675 | { |
|
|
3676 | scr_poweron (); |
3676 | set_widthheight (((state ? 132 : 80) * fwidth), height); |
3677 | set_widthheight (((state ? 132 : 80) * fwidth), 24 * fheight); |
|
|
3678 | } |
3677 | break; |
3679 | break; |
3678 | case 4: /* smooth scrolling */ |
3680 | case 4: /* smooth scrolling */ |
3679 | set_option (Opt_jumpScroll, !state); |
3681 | set_option (Opt_jumpScroll, !state); |
3680 | break; |
3682 | break; |
3681 | case 5: /* reverse video */ |
3683 | case 5: /* reverse video */ |