comparison src/keyboard.c @ 5808:995860e5f342

(menu_bar_item): Use internal_condition_case_1. (menu_bar_item_1): New function.
author Richard M. Stallman <rms@gnu.org>
date Mon, 07 Feb 1994 01:03:39 +0000
parents 8fae1a51e9c5
children c4030d39f26d
comparison
equal deleted inserted replaced
5807:cc9d9ab24008 5808:995860e5f342
3584 } 3584 }
3585 3585
3586 return result; 3586 return result;
3587 } 3587 }
3588 3588
3589 /* This is used as the handler when calling internal_condition_case_1. */
3590
3591 static Lisp_Object
3592 menu_bar_item_1 (arg)
3593 Lisp_Object arg;
3594 {
3595 return Qnil;
3596 }
3597
3589 static Lisp_Object 3598 static Lisp_Object
3590 menu_bar_item (key, item_string, def, result) 3599 menu_bar_item (key, item_string, def, result)
3591 Lisp_Object key, item_string, def, result; 3600 Lisp_Object key, item_string, def, result;
3592 { 3601 {
3593 Lisp_Object tem; 3602 Lisp_Object tem;
3608 { 3617 {
3609 /* No property, or nil, means enable. 3618 /* No property, or nil, means enable.
3610 Otherwise, enable if value is not nil. */ 3619 Otherwise, enable if value is not nil. */
3611 tem = Fget (def, Qmenu_enable); 3620 tem = Fget (def, Qmenu_enable);
3612 if (!NILP (tem)) 3621 if (!NILP (tem))
3613 enabled = Feval (tem); 3622 /* (condition-case nil (eval tem)
3623 (error nil)) */
3624 enabled = internal_condition_case_1 (Feval, tem, Qerror,
3625 menu_bar_item_1);
3614 } 3626 }
3615 3627
3616 /* Add an entry for this key and string 3628 /* Add an entry for this key and string
3617 if there is none yet. */ 3629 if there is none yet. */
3618 tem = Fassq (key, result); 3630 tem = Fassq (key, result);