Method: XCB::KeymapNotifyEvent.new

Defined in:
ext/xproto.c

.new(r_keys) ⇒ Object



2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
# File 'ext/xproto.c', line 2396

static VALUE
r_XCB_KeymapNotifyEvent_new(VALUE r_klass, VALUE r_keys)
{
	xcb_keymap_notify_event_t *self = malloc(sizeof(xcb_keymap_notify_event_t));
	if (self == NULL)
		rb_raise(rb_eNoMemError, "NoMemoryError");
	VALUE r_self = Data_Wrap_Struct(r_klass, NULL, NULL, self);
	self->response_type = XCB_KEYMAP_NOTIFY;
	Check_Type(r_keys, T_ARRAY);
	int __keys_len = 31;
	int i;
	for (i = 0; i < __keys_len; i += 1)
		self->keys[i] = FIX2INT(rb_ary_entry(r_keys, i));
	return r_self;
}