2 #include "e_devicemgr_private.h"
4 #define E_DEVICEMGR_INPUT_DFLT_BACK_KEYCODE 166
7 _e_devicemgr_conf_value_check(E_Devicemgr_Config_Data* dconfig)
9 if (!dconfig->conf) dconfig->conf = E_NEW(E_Devicemgr_Conf_Edd, 1);
10 EINA_SAFETY_ON_NULL_RETURN(dconfig->conf);
12 dconfig->conf->input.back_keycode = E_DEVICEMGR_INPUT_DFLT_BACK_KEYCODE;
16 e_devicemgr_conf_init(E_Devicemgr_Config_Data *dconfig)
18 dconfig->conf_edd = E_CONFIG_DD_NEW("Devicemgr_Config", E_Devicemgr_Conf_Edd);
21 #define T E_Devicemgr_Conf_Edd
22 #define D dconfig->conf_edd
23 E_CONFIG_VAL(D, T, input.button_remap_enable, CHAR);
24 E_CONFIG_VAL(D, T, input.virtual_key_device_enable, CHAR);
25 E_CONFIG_VAL(D, T, input.virtual_mouse_device_enable, CHAR);
26 E_CONFIG_VAL(D, T, input.back_keycode, INT);
30 dconfig->conf = e_config_domain_load("module.devicemgr", dconfig->conf_edd);
34 WRN("Failed to find module.devicemgr config file.\n");
36 _e_devicemgr_conf_value_check(dconfig);
40 e_devicemgr_conf_fini(E_Devicemgr_Config_Data *dconfig)
44 E_FREE(dconfig->conf);
46 E_CONFIG_DD_FREE(dconfig->conf_edd);