diff src/keymap.c @ 98:0d2f883870bc r20-1b1

Import from CVS: tag r20-1b1
author cvs
date Mon, 13 Aug 2007 09:13:56 +0200
parents c0c698873ce1
children 4be1180a9e89
line wrap: on
line diff
--- a/src/keymap.c	Mon Aug 13 09:12:43 2007 +0200
+++ b/src/keymap.c	Mon Aug 13 09:13:56 2007 +0200
@@ -227,6 +227,9 @@
 Lisp_Object Qbutton0up, Qbutton1up, Qbutton2up, Qbutton3up, Qbutton4up,
   Qbutton5up, Qbutton6up, Qbutton7up;
 Lisp_Object Qmenu_selection;
+/* Emacs compatibility */
+Lisp_Object Qdown_mouse_1, Qdown_mouse_2, Qdown_mouse_3;
+Lisp_Object Qmouse_1, Qmouse_2, Qmouse_3;
 
 /* Kludge kludge kludge */
 Lisp_Object QLFD, QTAB, QRET, QESC, QDEL, QSPC, QBS;
@@ -1342,6 +1345,19 @@
 	*keysym = QKdelete;
       else if (EQ (*keysym, QBS))
 	*keysym = QKbackspace;
+      /* Emacs compatibility */
+      else if (EQ(*keysym, Qdown_mouse_1))
+	*keysym = Qbutton1;
+      else if (EQ(*keysym, Qdown_mouse_2))
+	*keysym = Qbutton2;
+      else if (EQ(*keysym, Qdown_mouse_3))
+	*keysym = Qbutton3;
+      else if (EQ(*keysym, Qmouse_1))
+	*keysym = Qbutton1up;
+      else if (EQ(*keysym, Qmouse_2))
+	*keysym = Qbutton2up;
+      else if (EQ(*keysym, Qmouse_3))
+	*keysym = Qbutton3up;
     }
 }
 
@@ -4198,6 +4214,12 @@
   defsymbol (&Qbutton5up, "button5up");
   defsymbol (&Qbutton6up, "button6up");
   defsymbol (&Qbutton7up, "button7up");
+  defsymbol (&Qmouse_1, "mouse-1");
+  defsymbol (&Qmouse_2, "mouse-2");
+  defsymbol (&Qmouse_3, "mouse-3");
+  defsymbol (&Qdown_mouse_1, "down-mouse-1");
+  defsymbol (&Qdown_mouse_2, "down-mouse-2");
+  defsymbol (&Qdown_mouse_3, "down-mouse-3");
   defsymbol (&Qmenu_selection, "menu-selection");
   defsymbol (&QLFD, "LFD");
   defsymbol (&QTAB, "TAB");