return list2 (Qselect_window, list1 (event->frame_or_window));
case TAB_BAR_EVENT:
- if (EQ (event->arg, event->frame_or_window))
- /* This is the prefix key. We translate this to
- `(tab_bar)' because the code in keyboard.c for tab bar
- events, which we use, relies on this. */
- return list1 (Qtab_bar);
- else if (SYMBOLP (event->arg))
- return apply_modifiers (event->modifiers, event->arg);
- return event->arg;
-
case TOOL_BAR_EVENT:
{
Lisp_Object res = event->arg;
+ Lisp_Object location
+ = event->kind == TAB_BAR_EVENT ? Qtab_bar : Qtool_bar;
if (SYMBOLP (res)) res = apply_modifiers (event->modifiers, res);
- return list2 (res, list2 (event->frame_or_window, Qtool_bar));
+ return list2 (res, list2 (event->frame_or_window, location));
}
case USER_SIGNAL_EVENT:
key = AREF (f->tab_bar_items, prop_idx + TAB_BAR_ITEM_KEY);
XSETFRAME (frame, f);
- event.kind = TAB_BAR_EVENT;
- event.frame_or_window = frame;
- event.arg = frame;
- kbd_buffer_store_event (&event);
-
event.kind = TAB_BAR_EVENT;
event.frame_or_window = frame;
event.arg = key;
event->code = 0;
XSETFRAME (frame, f);
- event->kind = TAB_BAR_EVENT;
- event->frame_or_window = frame;
- event->arg = frame;
- kbd_buffer_store_event (event);
-
event->kind = TAB_BAR_EVENT;
event->frame_or_window = frame;
event->arg = key;