evas_object_size_hint_weight_set(bg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
evas_object_size_hint_min_set(bg, width, height);
evas_object_size_hint_max_set(bg, width, height);
- if (!elm_image_file_set(bg, buf, NULL)) {
+ if (buf == NULL || !elm_image_file_set(bg, buf, NULL)) {
_E("Failed to set image file : %s", buf);
if (!elm_image_file_set(bg, util_get_file_path(IMAGE_DIR"/home_001.png"), NULL)) {
- _E("Failed to set default image file: %s", util_get_file_path(IMAGE_DIR"/home_001.png"));
+ _E("Failed to set default image file: %s", util_get_file_path(IMAGE_DIR"/home_001.png"));
return;
}
}
static Evas_Object *_create_conformant(Evas_Object *win)
{
Evas_Object *conformant;
+ char *device_profile;
conformant = elm_conformant_add(win);
retv_if(NULL == conformant, NULL);
evas_object_size_hint_weight_set(conformant, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
- elm_win_indicator_mode_set(menu_screen_info.win, ELM_WIN_INDICATOR_SHOW);
- elm_win_indicator_opacity_set(menu_screen_info.win, ELM_WIN_INDICATOR_TRANSLUCENT);
+ device_profile = util_get_device_profile();
+ if (device_profile) {
+ if (!strcmp(device_profile, "mobile")) {
+ elm_win_indicator_mode_set(menu_screen_info.win, ELM_WIN_INDICATOR_SHOW);
+ elm_win_indicator_opacity_set(menu_screen_info.win, ELM_WIN_INDICATOR_TRANSLUCENT);
+ }
+ }
elm_object_signal_emit(conformant, "elm,state,indicator,overlap", "elm");
evas_object_data_set(conformant, "win", win);
evas_object_show(conformant);
elm_win_resize_object_add(win, conformant);
elm_win_conformant_set(win, EINA_TRUE);
+ if (device_profile)
+ free(device_profile);
+
return conformant;
}
count = page_scroller_count_page(scroller);
page_max_app = (unsigned int) evas_object_data_get(scroller, "page_max_app");
- for (i = 0; i < count; i ++) {
+ for (i = 0; i < count; i++) {
page = page_scroller_get_page_at(scroller, i);
if (!page) continue;
if (mapbuf_is_enabled(page)) {
mapbuf_disable(page, 1);
}
- for (j = 0; j < page_max_app; j ++) {
+ for (j = 0; j < page_max_app; j++) {
app_info_h app_info = NULL;
char *name;
int ret;
+ char *package;
item = page_get_item_at(page, j);
if (!item) continue;
- app_manager_get_app_info(item_get_package(item), &app_info);
+ package = item_get_package(item);
+ if (!package) continue;
+ ret = app_manager_get_app_info(package, &app_info);
+ if (ret != APP_MANAGER_ERROR_NONE || !app_info) {
+ _E("Failed to get app info");
+ continue;
+ }
ret = app_info_get_label(app_info, &name);
if (APP_MANAGER_ERROR_NONE != ret) {
_E("Failed to get label from : %s", item_get_package(item));