comparison src/events.c @ 70:131b0175ea99 r20-0b30

Import from CVS: tag r20-0b30
author cvs
date Mon, 13 Aug 2007 09:02:59 +0200
parents 859a2309aef8
children 4be1180a9e89
comparison
equal deleted inserted replaced
69:804d1389bcd6 70:131b0175ea99
668 Lisp_Object k = Qnil; 668 Lisp_Object k = Qnil;
669 unsigned int m = 0; 669 unsigned int m = 0;
670 if (event->event_type == dead_event) 670 if (event->event_type == dead_event)
671 error ("character-to-event called with a deallocated event!"); 671 error ("character-to-event called with a deallocated event!");
672 672
673 #ifndef MULE
673 c &= 255; 674 c &= 255;
675 #endif
674 if (c > 127 && c <= 255) 676 if (c > 127 && c <= 255)
675 { 677 {
676 int meta_flag = 1; 678 int meta_flag = 1;
677 if (use_console_meta_flag && CONSOLE_TTY_P (con)) 679 if (use_console_meta_flag && CONSOLE_TTY_P (con))
678 meta_flag = TTY_FLAGS (con).meta_key; 680 meta_flag = TTY_FLAGS (con).meta_key;
780 782
781 if (event->event.key.modifiers & MOD_META) 783 if (event->event.key.modifiers & MOD_META)
782 { 784 {
783 if (! allow_meta) return -1; 785 if (! allow_meta) return -1;
784 if (c & 0200) return -1; /* don't allow M-oslash (overlap) */ 786 if (c & 0200) return -1; /* don't allow M-oslash (overlap) */
787 #ifdef MULE
788 if (c >= 256) return -1;
789 #endif
785 c |= 0200; 790 c |= 0200;
786 } 791 }
787 return c; 792 return c;
788 } 793 }
789 794
803 variable) will be returned as their code in that character set, instead of 808 variable) will be returned as their code in that character set, instead of
804 the return value being restricted to ASCII. 809 the return value being restricted to ASCII.
805 Note that specifying both ALLOW-META and ALLOW-NON-ASCII is ambiguous, as 810 Note that specifying both ALLOW-META and ALLOW-NON-ASCII is ambiguous, as
806 both use the high bit; `M-x' and `oslash' will be indistinguishable. 811 both use the high bit; `M-x' and `oslash' will be indistinguishable.
807 */ 812 */
808 (event, allow_extra_modifiers, allow_meta, allow_non_ascii)) 813 (event, allow_extra_modifiers, allow_meta, allow_non_ascii))
809 { 814 {
810 Emchar c; 815 Emchar c;
811 CHECK_LIVE_EVENT (event); 816 CHECK_LIVE_EVENT (event);
812 c = event_to_character (XEVENT (event), 817 c = event_to_character (XEVENT (event),
813 !NILP (allow_extra_modifiers), 818 !NILP (allow_extra_modifiers),