Example #1
0
void KeyboardInterface::Private::sendModifiers(quint32 depressed, quint32 latched, quint32 locked, quint32 group, quint32 serial)
{
    if (!resource) {
        return;
    }
    wl_keyboard_send_modifiers(resource, serial, depressed, latched, locked, group);
}
Example #2
0
WL_EXPORT void
wlb_keyboard_modifiers(struct wlb_keyboard *keyboard, uint32_t mods_depressed,
		       uint32_t mods_latched, uint32_t mods_locked,
		       uint32_t group)
{
	struct wl_resource *resource;
	uint32_t serial;

	keyboard_ensure_focus(keyboard);

	if (!keyboard->focus || wl_list_empty(&keyboard->resource_list))
		return;
	
	serial = wl_display_next_serial(keyboard->seat->compositor->display);
	wl_resource_for_each(resource, &keyboard->resource_list)
		wl_keyboard_send_modifiers(resource, serial, mods_depressed,
					   mods_latched, mods_locked, group);
}