changeset 43073:c9baf4b00820

(term_get_fkeys_1): If `k0' and `k;' are both specified and with the same sequence, map that sequence to f10 rather than f0.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Sat, 02 Feb 2002 23:46:40 +0000
parents 6a9c037fa34a
children 11c22804d5e3
files src/term.c
diffstat 1 files changed, 6 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/term.c	Sat Feb 02 23:05:59 2002 +0000
+++ b/src/term.c	Sat Feb 02 23:46:40 2002 +0000
@@ -1513,12 +1513,15 @@
 
     if (k_semi)
       {
+	if (k0)
+	  /* Define f0 first, so that f10 takes precedence in case the
+	     key sequences happens to be the same.  */
+	  Fdefine_key (Vfunction_key_map, build_string (k0),
+		       Fmake_vector (make_number (1), intern ("f0")));
 	Fdefine_key (Vfunction_key_map, build_string (k_semi),
 		     Fmake_vector (make_number (1), intern ("f10")));
-	k0_name = "f0";
       }
-
-    if (k0)
+    else if (k0)
       Fdefine_key (Vfunction_key_map, build_string (k0),
 		   Fmake_vector (make_number (1), intern (k0_name)));
   }