aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/ecore_drm2
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2017-05-26 16:34:10 -0400
committerMike Blumenkrantz <zmike@osg.samsung.com>2017-05-26 16:27:42 -0400
commite8fe0bcc47ff44a5afaf8442407248887f716b89 (patch)
tree4fd7e06b862670ab7f87b2aa313f763e77b99cfc /src/lib/ecore_drm2
parentelput: implement compose sequences (diff)
downloadefl-e8fe0bcc47ff44a5afaf8442407248887f716b89.tar.gz
elput/drm: redo xkb context/keymap setting
context and keymap need to be set at the same time in order to effectively update keyboard state, and active group should be accessible through api as well preserve old function ABI to ensure old binaries don't crash
Diffstat (limited to 'src/lib/ecore_drm2')
-rw-r--r--src/lib/ecore_drm2/Ecore_Drm2.h16
-rw-r--r--src/lib/ecore_drm2/ecore_drm2_device.c12
2 files changed, 17 insertions, 11 deletions
diff --git a/src/lib/ecore_drm2/Ecore_Drm2.h b/src/lib/ecore_drm2/Ecore_Drm2.h
index 7d52d3aa00..d62f4e8f4c 100644
--- a/src/lib/ecore_drm2/Ecore_Drm2.h
+++ b/src/lib/ecore_drm2/Ecore_Drm2.h
@@ -285,26 +285,28 @@ EAPI void ecore_drm2_device_window_set(Ecore_Drm2_Device *device, unsigned int w
EAPI void ecore_drm2_device_pointer_max_set(Ecore_Drm2_Device *device, int w, int h);
/**
- * Set a cached context to be used on keyboards
+ * Set info to be used on keyboards
*
* @param device
* @param context
+ * @param keymap
+ * @param group
*
* @ingroup Ecore_Drm2_Device_Group
- * @since 1.18
+ * @since 1.20
*/
-EAPI void ecore_drm2_device_keyboard_cached_context_set(Ecore_Drm2_Device *device, void *context);
+EAPI void ecore_drm2_device_keyboard_info_set(Ecore_Drm2_Device *device, void *context, void *keymap, int group);
/**
- * Set a cached keymap to be used on keyboards
+ * Set a group layout to be used on keyboards
*
* @param device
- * @param keymap
+ * @param group
*
* @ingroup Ecore_Drm2_Device_Group
- * @since 1.18
+ * @since 1.20
*/
-EAPI void ecore_drm2_device_keyboard_cached_keymap_set(Ecore_Drm2_Device *device, void *keymap);
+EAPI void ecore_drm2_device_keyboard_group_set(Ecore_Drm2_Device *device, int group);
/**
* Get the crtcs of a given device
diff --git a/src/lib/ecore_drm2/ecore_drm2_device.c b/src/lib/ecore_drm2/ecore_drm2_device.c
index dbd95fe465..f225ad8129 100644
--- a/src/lib/ecore_drm2/ecore_drm2_device.c
+++ b/src/lib/ecore_drm2/ecore_drm2_device.c
@@ -777,19 +777,19 @@ ecore_drm2_device_pointer_max_set(Ecore_Drm2_Device *device, int w, int h)
}
EAPI void
-ecore_drm2_device_keyboard_cached_context_set(Ecore_Drm2_Device *device, void *context)
+ecore_drm2_device_keyboard_info_set(Ecore_Drm2_Device *device, void *context, void *keymap, int group)
{
EINA_SAFETY_ON_NULL_RETURN(device);
- elput_input_keyboard_cached_context_set(device->em, context);
+ elput_input_keyboard_info_set(device->em, context, keymap, group);
}
EAPI void
-ecore_drm2_device_keyboard_cached_keymap_set(Ecore_Drm2_Device *device, void *keymap)
+ecore_drm2_device_keyboard_group_set(Ecore_Drm2_Device *device, int group)
{
EINA_SAFETY_ON_NULL_RETURN(device);
- elput_input_keyboard_cached_keymap_set(device->em, keymap);
+ elput_input_keyboard_group_set(device->em, group);
}
EAPI unsigned int *
@@ -848,3 +848,7 @@ ecore_drm2_device_prefer_shadow(Ecore_Drm2_Device *device)
else
return EINA_FALSE;
}
+
+/* prevent crashing with old apps compiled against these functions */
+EAPI void ecore_drm2_device_keyboard_cached_context_set(){};
+EAPI void ecore_drm2_device_keyboard_cached_keymap_set(){};