1 #include "e_devicemgr_private.h"
3 #define E_DEVICEMGR_INPUT_DFLT_BACK_KEYCODE 166
6 _e_devicemgr_conf_value_check(E_Devicemgr_Config_Data* dconfig)
8 if (!dconfig->conf) dconfig->conf = E_NEW(E_Devicemgr_Conf_Edd, 1);
9 EINA_SAFETY_ON_NULL_RETURN(dconfig->conf);
11 dconfig->conf->input.back_keycode = E_DEVICEMGR_INPUT_DFLT_BACK_KEYCODE;
15 e_devicemgr_conf_init(E_Devicemgr_Config_Data *dconfig)
17 dconfig->conf_edd = E_CONFIG_DD_NEW("Devicemgr_Config", E_Devicemgr_Conf_Edd);
20 #define T E_Devicemgr_Conf_Edd
21 #define D dconfig->conf_edd
22 E_CONFIG_VAL(D, T, input.button_remap_enable, CHAR);
23 E_CONFIG_VAL(D, T, input.virtual_key_device_enable, CHAR);
24 E_CONFIG_VAL(D, T, input.virtual_mouse_device_enable, CHAR);
25 E_CONFIG_VAL(D, T, input.back_keycode, INT);
29 dconfig->conf = e_config_domain_load("module.devicemgr", dconfig->conf_edd);
33 WRN("Failed to find module.devicemgr config file.\n");
35 _e_devicemgr_conf_value_check(dconfig);
39 e_devicemgr_conf_fini(E_Devicemgr_Config_Data *dconfig)
43 E_FREE(dconfig->conf);
45 E_CONFIG_DD_FREE(dconfig->conf_edd);