summaryrefslogtreecommitdiff
path: root/src/bin/e_config.c
diff options
context:
space:
mode:
authorKim Kibum <kb0929.kim@samsung.com>2012-04-29 17:00:05 +0900
committerKim Kibum <kb0929.kim@samsung.com>2012-04-29 17:00:05 +0900
commitac8fa492451a1268eec649ea98e67184842f11a0 (patch)
tree9e13ab1116e2d6a9aecd65da2a232f7a63a9f3dc /src/bin/e_config.c
parent71de741809b2c23779657ecda17a4ef900af62e1 (diff)
downloade17-ac8fa492451a1268eec649ea98e67184842f11a0.tar.gz
e17-ac8fa492451a1268eec649ea98e67184842f11a0.tar.bz2
e17-ac8fa492451a1268eec649ea98e67184842f11a0.zip
upload tizen1.0 source
Diffstat (limited to 'src/bin/e_config.c')
-rw-r--r--src/bin/e_config.c131
1 files changed, 29 insertions, 102 deletions
diff --git a/src/bin/e_config.c b/src/bin/e_config.c
index 774a220..7f9cfe5 100644
--- a/src/bin/e_config.c
+++ b/src/bin/e_config.c
@@ -57,12 +57,13 @@ static E_Config_DD *_e_config_randr_serialized_setup_11_edd = NULL;
static E_Config_DD *_e_config_randr_serialized_setup_12_edd = NULL;
static E_Config_DD *_e_config_randr_serialized_output_policy_edd = NULL;
static E_Config_DD *_e_config_randr_serialized_output_edd = NULL;
-static E_Config_DD *_e_config_randr_serialized_mode_info_edd = NULL;
+static E_Config_DD *_e_config_randr_mode_info_edd = NULL;
static E_Config_DD *_e_config_randr_serialized_crtc_edd = NULL;
EAPI int E_EVENT_CONFIG_ICON_THEME = 0;
EAPI int E_EVENT_CONFIG_MODE_CHANGED = 0;
+EAPI int E_EVENT_CONFIG_LOADED = 0;
static E_Dialog *_e_config_error_dialog = NULL;
@@ -117,6 +118,7 @@ e_config_init(void)
{
E_EVENT_CONFIG_ICON_THEME = ecore_event_type_new();
E_EVENT_CONFIG_MODE_CHANGED = ecore_event_type_new();
+ E_EVENT_CONFIG_LOADED = ecore_event_type_new();
_e_config_profile = getenv("E_CONF_PROFILE");
@@ -553,7 +555,6 @@ e_config_init(void)
#define T E_Randr_Serialized_Output_Policy
#define D _e_config_randr_serialized_output_policy_edd
E_CONFIG_VAL(D, T, name, STR);
- E_CONFIG_VAL(D, T, name_length, INT);
E_CONFIG_VAL(D, T, policy, INT);
_e_config_randr_serialized_output_edd = E_CONFIG_DD_NEW("E_Randr_Serialized_Output", E_Randr_Serialized_Output);
@@ -562,15 +563,14 @@ e_config_init(void)
#define T E_Randr_Serialized_Output
#define D _e_config_randr_serialized_output_edd
E_CONFIG_VAL(D, T, name, STR);
- E_CONFIG_VAL(D, T, name_length, INT);
- E_CONFIG_SUB(D, T, edid_hash, _e_config_randr_edid_hash_edd);
E_CONFIG_VAL(D, T, backlight_level, DOUBLE);
- _e_config_randr_serialized_mode_info_edd = E_CONFIG_DD_NEW("E_Randr_Serialized_Mode_Info", Ecore_X_Randr_Mode_Info);
+ _e_config_randr_mode_info_edd = E_CONFIG_DD_NEW("Ecore_X_Randr_Mode_Info", Ecore_X_Randr_Mode_Info);
#undef T
#undef D
#define T Ecore_X_Randr_Mode_Info
-#define D _e_config_randr_serialized_mode_info_edd
+#define D _e_config_randr_mode_info_edd
+ E_CONFIG_VAL(D, T, xid, INT);
E_CONFIG_VAL(D, T, width, INT);
E_CONFIG_VAL(D, T, height, INT);
E_CONFIG_VAL(D, T, dotClock, LL);
@@ -590,11 +590,10 @@ e_config_init(void)
#undef D
#define T E_Randr_Serialized_Crtc
#define D _e_config_randr_serialized_crtc_edd
- E_CONFIG_LIST(D, T, serialized_outputs, _e_config_randr_serialized_output_edd);
- E_CONFIG_SUB(D, T, mode_info, _e_config_randr_serialized_mode_info_edd);
+ E_CONFIG_LIST(D, T, outputs, _e_config_randr_serialized_output_edd);
+ E_CONFIG_SUB(D, T, mode_info, _e_config_randr_mode_info_edd);
E_CONFIG_VAL(D, T, pos.x, INT);
E_CONFIG_VAL(D, T, pos.y, INT);
- EET_DATA_DESCRIPTOR_ADD_LIST_STRING(D, T, "Crtc_Possible_Outputs_Names", possible_outputs_names);
E_CONFIG_VAL(D, T, orientation, INT);
_e_config_randr_serialized_setup_12_edd = E_CONFIG_DD_NEW("E_Randr_Serialized_Setup_12", E_Randr_Serialized_Setup_12);
@@ -603,8 +602,8 @@ e_config_init(void)
#define T E_Randr_Serialized_Setup_12
#define D _e_config_randr_serialized_setup_12_edd
E_CONFIG_VAL(D, T, timestamp, DOUBLE);
- E_CONFIG_LIST(D, T, serialized_crtcs, _e_config_randr_serialized_crtc_edd);
- E_CONFIG_LIST(D, T, serialized_edid_hashes, _e_config_randr_edid_hash_edd);
+ E_CONFIG_LIST(D, T, crtcs, _e_config_randr_serialized_crtc_edd);
+ E_CONFIG_LIST(D, T, edid_hashes, _e_config_randr_edid_hash_edd);
_e_config_randr_serialized_setup_edd = E_CONFIG_DD_NEW("E_Randr_Serialized_Setup", E_Randr_Serialized_Setup);
#undef T
@@ -613,7 +612,7 @@ e_config_init(void)
#define D _e_config_randr_serialized_setup_edd
E_CONFIG_SUB(D, T, serialized_setup_11, _e_config_randr_serialized_setup_11_edd);
E_CONFIG_LIST(D, T, serialized_setups_12, _e_config_randr_serialized_setup_12_edd);
- E_CONFIG_LIST(D, T, serialized_outputs_policies, _e_config_randr_serialized_output_policy_edd);
+ E_CONFIG_LIST(D, T, outputs_policies, _e_config_randr_serialized_output_policy_edd);
_e_config_edd = E_CONFIG_DD_NEW("E_Config", E_Config);
#undef T
@@ -642,19 +641,8 @@ e_config_init(void)
E_CONFIG_VAL(D, T, edje_collection_cache, INT); /**/
E_CONFIG_VAL(D, T, zone_desks_x_count, INT); /**/
E_CONFIG_VAL(D, T, zone_desks_y_count, INT); /**/
- E_CONFIG_VAL(D, T, use_virtual_roots, INT); /* should not make this a config option (for now) */
E_CONFIG_VAL(D, T, show_desktop_icons, INT); /**/
E_CONFIG_VAL(D, T, edge_flip_dragging, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_default, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_container, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_init, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_menus, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_borders, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_errors, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_popups, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_drag, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_win, INT); /**/
- E_CONFIG_VAL(D, T, evas_engine_zone, INT); /**/
E_CONFIG_VAL(D, T, use_composite, INT); /**/
E_CONFIG_VAL(D, T, language, STR); /**/
E_CONFIG_LIST(D, T, modules, _e_config_module_edd); /**/
@@ -826,13 +814,6 @@ e_config_init(void)
E_CONFIG_VAL(D, T, wallpaper_import_last_dev, STR);
E_CONFIG_VAL(D, T, wallpaper_import_last_path, STR);
- E_CONFIG_VAL(D, T, wallpaper_grad_c1_r, INT);
- E_CONFIG_VAL(D, T, wallpaper_grad_c1_g, INT);
- E_CONFIG_VAL(D, T, wallpaper_grad_c1_b, INT);
- E_CONFIG_VAL(D, T, wallpaper_grad_c2_r, INT);
- E_CONFIG_VAL(D, T, wallpaper_grad_c2_g, INT);
- E_CONFIG_VAL(D, T, wallpaper_grad_c2_b, INT);
-
E_CONFIG_VAL(D, T, theme_default_border_style, STR);
E_CONFIG_LIST(D, T, mime_icons, _e_config_mime_icon_edd); /**/
@@ -898,6 +879,8 @@ e_config_init(void)
E_CONFIG_VAL(D, T, backlight.normal, DOUBLE);
E_CONFIG_VAL(D, T, backlight.dim, DOUBLE);
E_CONFIG_VAL(D, T, backlight.transition, DOUBLE);
+ E_CONFIG_VAL(D, T, backlight.idle_dim, UCHAR);
+ E_CONFIG_VAL(D, T, backlight.timer, DOUBLE);
E_CONFIG_VAL(D, T, deskenv.load_xrdb, UCHAR);
E_CONFIG_VAL(D, T, deskenv.load_xmodmap, UCHAR);
@@ -915,6 +898,9 @@ e_config_init(void)
E_CONFIG_VAL(D, T, xsettings.net_icon_theme_name, STR);
E_CONFIG_VAL(D, T, xsettings.gtk_font_name, STR);
+ E_CONFIG_VAL(D, T, update.check, UCHAR);
+ E_CONFIG_VAL(D, T, update.later, UCHAR);
+
e_config_load();
e_config_save_queue();
@@ -947,7 +933,7 @@ e_config_shutdown(void)
E_CONFIG_DD_FREE(_e_config_mime_icon_edd);
E_CONFIG_DD_FREE(_e_config_syscon_action_edd);
E_CONFIG_DD_FREE(_e_config_env_var_edd);
- E_CONFIG_DD_FREE(_e_config_randr_serialized_setup_edd);
+ //E_CONFIG_DD_FREE(_e_config_randr_serialized_setup_edd);
return 1;
}
@@ -1172,6 +1158,8 @@ e_config_load(void)
COPYVAL(backlight.normal);
COPYVAL(backlight.dim);
COPYVAL(backlight.transition);
+ COPYVAL(backlight.idle_dim);
+ COPYVAL(backlight.timer);
IFCFGEND;
IFCFG(0x0145);
@@ -1180,6 +1168,11 @@ e_config_load(void)
COPYVAL(xsettings.match_e17_icon_theme);
IFCFGEND;
+ IFCFG(0x0147);
+ COPYVAL(update.check);
+ COPYVAL(update.later);
+ IFCFGEND;
+
e_config->config_version = E_CONFIG_FILE_VERSION;
_e_config_free(tcfg);
}
@@ -1337,6 +1330,8 @@ e_config_load(void)
if (e_config->desklock_personal_passwd)
eina_stringshare_del(e_config->desklock_personal_passwd);
e_config->desklock_personal_passwd = NULL;
+
+ ecore_event_add(E_EVENT_CONFIG_LOADED, NULL, NULL, NULL);
}
EAPI int
@@ -1496,31 +1491,6 @@ e_config_profile_del(const char *prof)
ecore_file_recursive_rm(buf);
}
-EAPI Eina_List *
-e_config_engine_list(void)
-{
- Eina_List *l = NULL;
- l = eina_list_append(l, strdup("SOFTWARE"));
- /*
- * DISABLE GL as an accessible engine - it does have problems, ESPECIALLY with
- * shaped windows (it can't do them), and multiple gl windows and shared
- * contexts, so for now just disable it. xrender is much more complete in
- * this regard.
- */
-#if 0 /* opengl cant do occludes for frames - only useful for compositor */
- l = eina_list_append(l, strdup("GL"));
-#endif
-#if 0 /* xrender too incomplete these days */
- if (ecore_evas_engine_type_supported_get(ECORE_EVAS_ENGINE_XRENDER_X11))
- l = eina_list_append(l, strdup("XRENDER"));
-#endif
-#if 0 /* software-16 too incomplete and buggy */
- if (ecore_evas_engine_type_supported_get(ECORE_EVAS_ENGINE_SOFTWARE_16_X11))
- l = eina_list_append(l, strdup("SOFTWARE_16"));
-#endif
- return l;
-}
-
EAPI void
e_config_save_block_set(int block)
{
@@ -1602,7 +1572,7 @@ _e_config_mv_error(const char *from, const char *to)
e_dialog_title_set(dia, _("Enlightenment Settings Write Problems"));
e_dialog_icon_set(dia, "dialog-error", 64);
snprintf(buf, sizeof(buf),
- _("Enlightenment has an error while moving config files<br>"
+ _("Enlightenment has had an error while moving config files<br>"
"from:<br>"
"%s<br>"
"<br>"
@@ -1912,15 +1882,8 @@ _e_config_free(E_Config *ecf)
E_Color_Class *cc;
E_Path_Dir *epd;
E_Remember *rem;
- E_Randr_Serialized_Setup_12 *serialized_setup_12;
- E_Randr_Serialized_Crtc *serialized_crtc;
- E_Randr_Serialized_Output_Policy *serialized_output_policy;
- E_Randr_Serialized_Output *serialized_output;
- E_Randr_Edid_Hash *edid_hash;
- char *output_name;
E_Config_Env_Var *evr;
-
if (!ecf) return;
EINA_LIST_FREE(ecf->modules, em)
@@ -2070,44 +2033,8 @@ _e_config_free(E_Config *ecf)
}
if(ecf->randr_serialized_setup)
{
- free (ecf->randr_serialized_setup->serialized_setup_11);
- if (ecf->randr_serialized_setup->serialized_setups_12)
- {
- EINA_LIST_FREE(ecf->randr_serialized_setup->serialized_setups_12, serialized_setup_12)
- {
- EINA_LIST_FREE(serialized_setup_12->serialized_crtcs, serialized_crtc)
- {
- if (!serialized_crtc) continue;
- EINA_LIST_FREE(serialized_crtc->serialized_outputs, serialized_output)
- {
- if (!serialized_output) continue;
- free(serialized_output->name);
- free(serialized_output);
- }
- EINA_LIST_FREE(serialized_crtc->possible_outputs_names, output_name)
- {
- if (output_name) free(output_name);
- }
- if (serialized_crtc->mode_info.name)
- free(serialized_crtc->mode_info.name);
- free(serialized_crtc);
- }
- EINA_LIST_FREE(serialized_setup_12->serialized_edid_hashes, edid_hash)
- {
- if (edid_hash) free(edid_hash);
- }
- free(serialized_setup_12);
- }
- }
- EINA_LIST_FREE(ecf->randr_serialized_setup->serialized_outputs_policies, serialized_output_policy)
- {
- if (!serialized_output_policy) continue;
- free(serialized_output_policy->name);
- free(serialized_output_policy);
- }
- free(ecf->randr_serialized_setup);
+ e_randr_serialized_setup_free(ecf->randr_serialized_setup);
}
-
EINA_LIST_FREE(ecf->env_vars, evr)
{
if (evr->var) eina_stringshare_del(evr->var);
@@ -2220,7 +2147,7 @@ _e_config_eet_close_handle(Eet_File *ef, char *file)
e_dialog_title_set(dia, _("Enlightenment Settings Write Problems"));
e_dialog_icon_set(dia, "dialog-error", 64);
snprintf(buf, sizeof(buf),
- _("Enlightenment has an error while writing<br>"
+ _("Enlightenment has had an error while writing<br>"
"its config file.<br>"
"%s<br>"
"<br>"