diff --git a/clutter/clutter-input-device.c b/clutter/clutter-input-device.c index efec797bd..41196eef7 100644 --- a/clutter/clutter-input-device.c +++ b/clutter/clutter-input-device.c @@ -1421,9 +1421,10 @@ _clutter_input_device_select_stage_events (ClutterInputDevice *device, * equivalent evdev keycode. Note that depending on the input backend * used by Clutter this function can fail if there is no obvious * mapping between the key codes. The hardware keycode can be taken - * from the hardware_keycode member of #ClutterKeyEvent. + * from the #ClutterKeyEvent.hardware_keycode member of #ClutterKeyEvent. * * Return value: %TRUE if the conversion succeeded, %FALSE otherwise. + * * Since: 1.10 */ gboolean @@ -1433,6 +1434,8 @@ clutter_input_device_keycode_to_evdev (ClutterInputDevice *device, { ClutterInputDeviceClass *device_class; + g_return_val_if_fail (CLUTTER_IS_INPUT_DEVICE (device), FALSE); + device_class = CLUTTER_INPUT_DEVICE_GET_CLASS (device); if (device_class->keycode_to_evdev == NULL) return FALSE;