ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/command.C
(Generate patch)

Comparing rxvt-unicode/src/command.C (file contents):
Revision 1.25 by pcg, Fri Dec 19 09:41:09 2003 UTC vs.
Revision 1.30 by pcg, Thu Jan 29 21:35:58 2004 UTC

1/*--------------------------------*-C-*---------------------------------* 1/*--------------------------------*-C-*---------------------------------*
2 * File: command.c 2 * File: command.c
3 *----------------------------------------------------------------------* 3 *----------------------------------------------------------------------*
4 * $Id: command.C,v 1.25 2003/12/19 09:41:09 pcg Exp $ 4 * $Id: command.C,v 1.30 2004/01/29 21:35:58 pcg Exp $
5 * 5 *
6 * All portions of code are copyright by their respective author/s. 6 * All portions of code are copyright by their respective author/s.
7 * Copyright (c) 1992 John Bovey, University of Kent at Canterbury <jdb@ukc.ac.uk> 7 * Copyright (c) 1992 John Bovey, University of Kent at Canterbury <jdb@ukc.ac.uk>
8 * - original version 8 * - original version
9 * Copyright (c) 1994 Robert Nation <nation@rocket.sanders.lockheed.com> 9 * Copyright (c) 1994 Robert Nation <nation@rocket.sanders.lockheed.com>
752 rxvt_process_x_event (this, &xev); 752 rxvt_process_x_event (this, &xev);
753 } 753 }
754 while (XPending (Xdisplay)); 754 while (XPending (Xdisplay));
755} 755}
756 756
757#ifdef CURSOR_BLINK
757void 758void
758rxvt_term::blink_cb (time_watcher &w) 759rxvt_term::blink_cb (time_watcher &w)
759{ 760{
760 w.at += BLINK_INTERVAL;
761 hidden_cursor = !hidden_cursor; 761 hidden_cursor = !hidden_cursor;
762 want_refresh = 1; 762 want_refresh = 1;
763
764 w.start (w.at + BLINK_INTERVAL);
763} 765}
766#endif
764 767
765void 768void
766rxvt_term::x_cb (io_watcher &w, short revents) 769rxvt_term::x_cb (io_watcher &w, short revents)
767{ 770{
768 SET_R (this); 771 SET_R (this);
1017 quick_timeout |= R->want_full_refresh; 1020 quick_timeout |= R->want_full_refresh;
1018#endif 1021#endif
1019#endif 1022#endif
1020} 1023}
1021 1024
1025#ifdef POINTER_BLANK
1022void 1026void
1023rxvt_term::pointer_unblank () 1027rxvt_term::pointer_unblank ()
1024{ 1028{
1025 XDefineCursor (Xdisplay, TermWin.vt, TermWin_cursor); 1029 XDefineCursor (Xdisplay, TermWin.vt, TermWin_cursor);
1026 recolour_cursor (); 1030 recolour_cursor ();
1027 1031
1028#ifdef POINTER_BLANK
1029 hidden_pointer = 0; 1032 hidden_pointer = 0;
1030 1033
1031 if (Options & Opt_pointerBlank) 1034 if (Options & Opt_pointerBlank)
1032 pointer_ev.start (NOW + pointerBlankDelay); 1035 pointer_ev.start (NOW + pointerBlankDelay);
1033#endif
1034} 1036}
1035 1037
1036#ifdef POINTER_BLANK
1037void 1038void
1038rxvt_term::pointer_blank () 1039rxvt_term::pointer_blank ()
1039{ 1040{
1040 pointer_ev.stop ();
1041
1042 if (!(Options & Opt_pointerBlank)) 1041 if (!(Options & Opt_pointerBlank))
1043 return; 1042 return;
1044 1043
1045 XDefineCursor (Xdisplay, TermWin.vt, blank_cursor); 1044 XDefineCursor (Xdisplay, TermWin.vt, blank_cursor);
1046 XFlush (Xdisplay); 1045 XFlush (Xdisplay);
1526 1525
1527/* INTPROTO */ 1526/* INTPROTO */
1528void 1527void
1529rxvt_button_press(pR_ XButtonEvent *ev) 1528rxvt_button_press(pR_ XButtonEvent *ev)
1530{ 1529{
1531 int reportmode = 0, clickintime; 1530 int reportmode = 0, clickintime;
1532 1531
1533 R->bypass_keystate = ev->state & (R->ModMetaMask | ShiftMask); 1532 R->bypass_keystate = ev->state & (R->ModMetaMask | ShiftMask);
1534 if (!R->bypass_keystate) 1533 if (!R->bypass_keystate)
1535 reportmode = !!(R->PrivateModes & PrivMode_mouse_report); 1534 reportmode = !!(R->PrivateModes & PrivMode_mouse_report);
1536/* 1535/*
1584 R->MEvent.clicks = 0; 1583 R->MEvent.clicks = 0;
1585 switch (ev->button) 1584 switch (ev->button)
1586 { 1585 {
1587 case Button1: 1586 case Button1:
1588 /* allow shift+left click to extend selection */ 1587 /* allow shift+left click to extend selection */
1589 if (ev->state & ShiftMask) 1588 if (ev->state & ShiftMask && !(R->PrivateModes & PrivMode_mouse_report))
1590 { 1589 {
1591 if (R->MEvent.button == Button1 && clickintime) 1590 if (R->MEvent.button == Button1 && clickintime)
1592 R->selection_rotate (ev->x, ev->y); 1591 R->selection_rotate (ev->x, ev->y);
1593 else 1592 else
1594 R->selection_extend (ev->x, ev->y, 1); 1593 R->selection_extend (ev->x, ev->y, 1);
2692 break; 2691 break;
2693#endif 2692#endif
2694 2693
2695 case CSI_78: /* DECREQTPARM */ 2694 case CSI_78: /* DECREQTPARM */
2696 if (arg[0] == 0 || arg[0] == 1) 2695 if (arg[0] == 0 || arg[0] == 1)
2697 R->tt_printf("\033[%d;1;1;112;112;1;0x", arg[0] + 2); 2696 R->tt_printf("\033[%d;1;1;128;128;1;0x", arg[0] + 2);
2698 /* FALLTHROUGH */ 2697 /* FALLTHROUGH */
2699 2698
2700 default: 2699 default:
2701 break; 2700 break;
2702 } 2701 }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines