entrance: the gui can now be set to a new theme.

devs/bu5hm4n/develop
Marcel Hollerbach 8 years ago
parent 08c429ec82
commit cf959fc86e
  1. 28
      src/bin/entrance_gui.c

@ -169,6 +169,29 @@ entrance_gui_init(const char *theme)
return j;
}
static void
_entrance_gui_theme_update(void)
{
Eina_List *node;
Entrance_Screen *screen;
char buf[PATH_MAX];
snprintf(buf, sizeof(buf),
PACKAGE_DATA_DIR"/themes/%s.edj", _gui->theme);
EINA_LIST_FOREACH(_gui->screens, node, screen)
{
elm_layout_file_set(screen->transition, buf, "entrance/wallpaper/default");
elm_layout_file_set(screen->edj, buf, "entrance");
elm_layout_file_set(screen->login, buf, "entrance/login");
evas_object_smart_callback_add(
ENTRANCE_GUI_GET(screen->edj, "entrance.conf"),
"clicked",
_entrance_gui_conf_clicked_cb,
screen->transition);
}
_entrance_gui_actions_populate();
_entrance_gui_users_populate();
}
void
entrance_gui_shutdown(void)
{
@ -490,7 +513,8 @@ entrance_gui_conf_set(const Entrance_Conf_Gui_Event *conf)
}
if (_gui->theme != conf->theme)
{
_gui->theme = conf->theme;
entrance_gui_theme_name_set(conf->theme);
_entrance_gui_theme_update();
}
_gui->changed = ~(ENTRANCE_CONF_NONE);
_entrance_gui_update();
@ -532,7 +556,7 @@ entrance_gui_themes_get(void)
void
entrance_gui_theme_name_set(const char *theme)
{
/* TODO */
_gui->theme = theme;
}
const char *

Loading…
Cancel
Save