void bs_service_page_show (const char *file) { Evas_Object *old; edje_object_signal_emit(mod->edje, "page,hide", "enna"); if (!file) { edje_object_signal_emit(mod->edje, "page,hide", "enna"); evas_object_del(mod->page); return; } old = mod->page; mod->page = elm_image_add(mod->o_layout); elm_image_fill_outside_set(mod->page, 0); elm_image_file_set(mod->page, file, NULL); elm_layout_content_set(mod->o_layout, "service.book.page.swallow", mod->page); edje_object_signal_emit(mod->edje, "page,show", "enna"); evas_object_del(old); evas_object_show(mod->page); }
static void _win_nowplaying_update(Win *w, Song *previous) { Evas_Object *cover; int label_size; char *artist_title; const char *s1, *s2; if (previous && w->song && previous->album_id != w->song->album_id) { cover = cover_album_fetch_by_id(w->win, w->db, w->song->album_id, 480, NULL, NULL); // TODO: size! elm_layout_content_set(w->nowplaying, "ejy.swallow.cover", cover); } db_song_artist_fetch(w->db, w->song); s1 = w->song->title; s2 = w->song->artist; if (!s1) s1 = ""; if (!s2) s2 = ""; label_size = strlen(s1) + strlen(s2) + 4; artist_title = malloc(label_size); if (!artist_title) return; if (snprintf(artist_title, label_size, "%s - %s", s1, s2) >= label_size) { CRITICAL("could not set nowplaying title"); goto nowplaying_error; } edje_object_part_text_set(elm_layout_edje_get(w->nowplaying), "ejy.text.title", eina_stringshare_add(artist_title)); nowplaying_error: free(artist_title); }
/** * @brief Positive test case of elm_nocontents_custom_set() */ static void utc_UIFW_elm_nocontents_custom_set_func_01(void) { Evas_Object *no_contents = NULL; Evas_Object *custom_area,*btn , *icon; Evas_Object *custom; char buf[255] = {0,}; no_contents = elm_nocontents_add(main_win); evas_object_show(no_contents); custom_area = elm_layout_add (main_win); elm_layout_file_set (custom_area, NULL, "winset-test/nocontents/search_google"); elm_nocontents_custom_set(no_contents,custom_area); btn = elm_button_add (main_win); icon = elm_icon_add (main_win); snprintf (buf, sizeof(buf), "%s/30_SmartSearch_google_icon.png", PKG_DATA_DIR); elm_icon_file_set (icon, buf, NULL); elm_icon_scale_set (icon, 1, 1); elm_button_icon_set (btn, icon); elm_layout_content_set (custom_area, "buttons", btn); custom = elm_nocontents_custom_get(no_contents); if (!custom) { tet_infoline("elm_nocontents_custom_set() failed in positive test case"); tet_result(TET_FAIL); return; } tet_result(TET_PASS); }
static Evas_Object * _date_add(Evas_Object *parent) { sd->obj = elm_layout_add(parent); elm_layout_file_set(sd->obj, enna_config_theme_get(), "gadget/date"); evas_object_show(sd->obj); elm_layout_content_set(parent, "enna.swallow.date", sd->obj); return NULL; }
static void bs_menu_create (void) { mod->menu = enna_wall_add(mod->o_layout); bs_menu_add(mod->gocomics); enna_wall_select_nth(mod->menu, 0, 0); elm_layout_content_set(mod->o_layout, "menu.swallow", mod->menu); mod->state = BS_MENU_VIEW; }
static Evas_Object* gl_content_get_cb(void *data, Evas_Object *obj, const char *part) { settings_internal_data *sd = data; if (!sd || !sd->item || !part) return NULL; const Elm_Genlist_Item_Class *itc = elm_genlist_item_item_class_get(sd->item); if (!itc) return NULL; Evas_Object *content = NULL; /* Check the item class style and add the object needed in the item class*/ /* Here, puts the icon in the item class to add it to genlist items */ if (itc->item_style && !strcmp(itc->item_style, "1line")) { if (part && !strcmp(part, "elm.icon.1") && sd->selected.menu[sd->selected.index].icon != NULL) { content = elm_layout_add(obj); elm_layout_theme_set(content, "layout", "list/B/type.3", "default"); Evas_Object *icon = create_icon(content, sd->selected.menu[sd->selected.index].icon); elm_layout_content_set(content, "elm.swallow.content", icon); } if (sd->selected.menu[sd->selected.index].type == SETTINGS_TYPE_TOGGLE) { if (part && !strcmp(part, "elm.icon.right")) { Evas_Object *icon; content = elm_layout_add(obj); elm_layout_theme_set(content, "layout", "list/A/right.icon", "default"); if (sd->selected.menu[sd->selected.index].toggled) icon = create_icon(sd->parent, "toggle_on.png"); else icon = create_icon(sd->parent, "toggle_off.png"); elm_layout_content_set(content, "elm.swallow.content", icon); } } } return content; }
static void flag_set (Smart_Data *sd, Evas_Object **obj, const char *icon, const char *edje) { if (!sd || !obj || !icon || !edje) return; ENNA_OBJECT_DEL(*obj); *obj = elm_icon_add(sd->o_edje); elm_image_file_set(*obj, enna_config_theme_get(), icon); evas_object_show(*obj); elm_layout_content_set(sd->o_edje, edje, *obj); }
static Evas_Object *_gl_content_get(void *data, Evas_Object *obj, const char *part) { if (data == NULL) { return NULL; } devpkr_gl_data_t *gdata = (devpkr_gl_data_t *) data; Evas_Object* icon = NULL; if (!strncmp(part, "elm.icon.1", strlen(part))) { char *temp_str = NULL; Evas_Object *ic = elm_layout_add(obj); icon = elm_image_add(ic); elm_layout_theme_set(ic, "layout", "list/B/type.1", "default"); temp_str = g_strdup_printf("%s.png", gdata->dev_info->ap_image_path); elm_image_file_set(icon, CUSTOM_EDITFIELD_PATH, temp_str); g_free(temp_str); if (gdata->highlighted == TRUE) { ea_theme_object_color_set(icon, "AO001P"); } else { ea_theme_object_color_set(icon, "AO001"); } evas_object_size_hint_align_set(icon, EVAS_HINT_FILL, EVAS_HINT_FILL); evas_object_size_hint_weight_set(icon, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); elm_layout_content_set(ic, "elm.swallow.content", icon); return ic; } else if (!strncmp(part, "elm.icon.2", strlen(part))) { switch (gdata->connection_mode) { case ITEM_CONNECTION_MODE_OFF: break; case ITEM_CONNECTION_MODE_CONNECTING: icon = elm_progressbar_add(obj); elm_object_style_set(icon, "process_medium"); evas_object_size_hint_align_set(icon, EVAS_HINT_FILL, 0.5); evas_object_size_hint_weight_set(icon, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); elm_progressbar_pulse(icon, TRUE); break; default: break; } } return icon; }
static void bs_service_set_bg (const char *bg) { if (bg) { Evas_Object *old; old = mod->service_bg; mod->service_bg = elm_layout_add(mod->o_layout); elm_layout_file_set(mod->service_bg, enna_config_theme_get(), bg); elm_layout_content_set(mod->o_layout, "service.bg.swallow", mod->service_bg); evas_object_show(mod->service_bg); evas_object_del(old); } else { evas_object_hide(mod->service_bg); elm_layout_file_set(mod->o_layout, "service.bg.swallow", NULL); } }
static void bs_service_ctrl_btn_add (const char *icon, const char *part, void (*cb) (void *data, Evas_Object *obj, void *ev)) { Evas_Object *layout, *ic, *bt; layout = elm_layout_add(enna->layout); ic = elm_icon_add(layout); elm_image_file_set(ic, enna_config_theme_get(), icon); elm_icon_resizable_set(ic, 0, 0); evas_object_show(ic); bt = elm_button_add(layout); evas_object_smart_callback_add(bt, "clicked", cb, NULL); elm_object_part_content_set(bt, NULL, ic); elm_object_style_set(bt, "mediaplayer"); evas_object_size_hint_weight_set(bt, 0.0, 1.0); evas_object_size_hint_align_set(bt, 0.5, 0.5); evas_object_show(bt); elm_layout_content_set(mod->o_layout, part, bt); }
/* externally accessible functions */ Evas_Object * enna_photo_slideshow_add(Evas_Object *parent) { Smart_Data *sd; Evas_Object *bx, *bt, *ic; Evas_Coord w, h; sd = calloc(1, sizeof(Smart_Data)); sd->delay = enna_config->slideshow_delay; sd->layout = elm_layout_add(parent); elm_layout_file_set(sd->layout, enna_config_theme_get(), "enna/slideshow"); evas_object_size_hint_weight_set(sd->layout, 1.0, 1.0); evas_object_show(sd->layout); sd->slideshow = elm_slideshow_add(sd->layout); elm_slideshow_transition_set(sd->slideshow, "horizontal"); elm_slideshow_loop_set(sd->slideshow, 1); // sd->controls = elm_notify_add(sd->layout); // elm_notify_orient_set(sd->controls, ELM_NOTIFY_ORIENT_BOTTOM); evas_object_geometry_get(enna->layout, NULL, NULL, &w, &h); evas_object_move(sd->controls, 0, 0); evas_object_resize(sd->controls, w, h); //elm_object_style_set(sd->controls, "enna_bottom"); /* Fixme : add a config value */ // elm_notify_timeout_set(sd->controls, 10); bx = elm_box_add(sd->layout); elm_box_horizontal_set(bx, 1); // elm_notify_content_set(sd->controls, bx); evas_object_show(bx); evas_object_event_callback_add(bx, EVAS_CALLBACK_MOUSE_IN, _mouse_in, sd); evas_object_event_callback_add(bx, EVAS_CALLBACK_MOUSE_OUT, _mouse_out, sd); ELM_ADD ("icon/mp_prev", _button_clicked_prev_cb); ELM_ADD ("icon/mp_pause", _button_clicked_play_cb); sd->btplay = bt; ELM_ADD ("icon/mp_next", _button_clicked_next_cb); ELM_ADD ("icon/mp_stop", _button_clicked_stop_cb); sd->spin = elm_spinner_add(bx); elm_spinner_label_format_set(sd->spin, "%2.f secs."); evas_object_smart_callback_add(sd->spin, "changed", _spin, sd); elm_spinner_step_set(sd->spin, 1); elm_spinner_min_max_set(sd->spin, 1, 100); elm_spinner_value_set(sd->spin, sd->delay); elm_box_pack_end(bx, sd->spin); evas_object_show(sd->spin); #ifdef FEATURE_ROTATION ELM_ADD ("icon/rotate_ccw", _button_clicked_rotate_ccw_cb); ELM_ADD ("icon/rotate_cw", _button_clicked_rotate_cw_cb); #endif /* FEATURE_ROTATION */ evas_object_show(sd->layout); evas_object_show(sd->slideshow); elm_layout_content_set(sd->layout, "enna.content.swallow", sd->slideshow); evas_object_data_set(sd->layout, "sd", sd); sd->state = 4; /* Catch mouse wheel event */ evas_object_event_callback_add(sd->layout, EVAS_CALLBACK_MOUSE_WHEEL, _mouse_wheel_cb, sd); /* connect to the input signal */ sd->listener = enna_input_listener_add("slideshow", _input_events_cb, sd->layout); enna_input_listener_demote(sd->listener); evas_object_event_callback_add(sd->layout, EVAS_CALLBACK_MOUSE_UP, _controls_show, sd); evas_object_event_callback_add(sd->layout, EVAS_CALLBACK_MOUSE_MOVE, _controls_show, sd); evas_object_event_callback_add(sd->layout, EVAS_CALLBACK_DEL, _sd_del, sd); return sd->layout; }
static Eina_Bool _elm_fileselector_smart_theme(Evas_Object *obj) { const char *style; const char *data; char buf[1024]; ELM_FILESELECTOR_DATA_GET(obj, sd); if (!ELM_WIDGET_CLASS(_elm_fileselector_parent_sc)->theme(obj)) return EINA_FALSE; style = elm_widget_style_get(obj); _mirrored_set(obj, elm_widget_mirrored_get(obj)); data = edje_object_data_get (ELM_WIDGET_DATA(sd)->resize_obj, "path_separator"); if (data) sd->path_separator = data; else sd->path_separator = "/"; snprintf(buf, sizeof(buf), "fileselector/%s", style); #define SWALLOW(part_name, object_ptn) \ if (object_ptn) \ { \ elm_widget_style_set(object_ptn, buf); \ if (!elm_layout_content_set(obj, part_name, object_ptn)) \ evas_object_hide(object_ptn); \ } SWALLOW("elm.swallow.up", sd->up_button); SWALLOW("elm.swallow.home", sd->home_button); SWALLOW("elm.swallow.spinner", sd->spinner); elm_object_style_set(sd->spinner, "wheel"); if (sd->mode == ELM_FILESELECTOR_LIST) { if (elm_layout_content_set(obj, "elm.swallow.files", sd->files_list)) evas_object_hide(sd->files_grid); else evas_object_hide(sd->files_list); } else { if (elm_layout_content_set(obj, "elm.swallow.files", sd->files_grid)) evas_object_hide(sd->files_list); else evas_object_hide(sd->files_grid); } SWALLOW("elm.swallow.filename", sd->filename_entry); SWALLOW("elm.swallow.path", sd->path_entry); snprintf(buf, sizeof(buf), "fileselector/actions/%s", style); SWALLOW("elm.swallow.cancel", sd->cancel_button); SWALLOW("elm.swallow.ok", sd->ok_button); #undef SWALLOW edje_object_message_signal_process(ELM_WIDGET_DATA(sd)->resize_obj); elm_layout_sizing_eval(obj); return EINA_TRUE; }
static void _conformant_parts_swallow(Evas_Object *obj) { Evas *e; ELM_CONFORMANT_DATA_GET(obj, sd); ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); e = evas_object_evas_get(obj); sd->scroller = NULL; //Virtual Keyboard if (edje_object_part_exists(wd->resize_obj, VIRTUALKEYPAD_PART)) { if (!sd->virtualkeypad) { sd->virtualkeypad = evas_object_rectangle_add(e); elm_widget_sub_object_add(obj, sd->virtualkeypad); evas_object_size_hint_max_set(sd->virtualkeypad, -1, 0); } else _conformant_part_sizing_eval(obj, ELM_CONFORMANT_VIRTUAL_KEYPAD_PART); evas_object_color_set(sd->virtualkeypad, 0, 0, 0, 0); elm_layout_content_set(obj, VIRTUALKEYPAD_PART, sd->virtualkeypad); } else ELM_SAFE_FREE(sd->virtualkeypad, evas_object_del); //Clipboard if (edje_object_part_exists(wd->resize_obj, CLIPBOARD_PART)) { if (!sd->clipboard) { sd->clipboard = evas_object_rectangle_add(e); evas_object_size_hint_min_set(sd->clipboard, -1, 0); evas_object_size_hint_max_set(sd->clipboard, -1, 0); } else _conformant_part_sizing_eval(obj, ELM_CONFORMANT_CLIPBOARD_PART); evas_object_color_set(sd->clipboard, 0, 0, 0, 0); elm_layout_content_set(obj, CLIPBOARD_PART, sd->clipboard); } else ELM_SAFE_FREE(sd->clipboard, evas_object_del); //Softkey if (edje_object_part_exists(wd->resize_obj, SOFTKEY_PART)) { if (!sd->softkey) { sd->softkey = evas_object_rectangle_add(e); evas_object_size_hint_min_set(sd->softkey, -1, 0); evas_object_size_hint_max_set(sd->softkey, -1, 0); } else _conformant_part_sizing_eval(obj, ELM_CONFORMANT_SOFTKEY_PART); evas_object_color_set(sd->softkey, 0, 0, 0, 0); elm_layout_content_set(obj, SOFTKEY_PART, sd->softkey); } else ELM_SAFE_FREE(sd->softkey, evas_object_del); }
EOLIAN static void _jk_spinner_efl_canvas_group_group_add(Eo *obj, Jk_Spinner_Data *priv) { printf("jk spinner group group add \n"); ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); JK_SPINNER_DATA_GET(obj, sd); efl_canvas_group_add(efl_super(obj, JK_SPINNER_CLASS)); elm_widget_sub_object_parent_add(obj); /* pd->rect = evas_object_rectangle_add(evas_object_evas_get(obj)); //evas_object_color_set(pd->rect, rand() % 255, rand() % 255, rand() % 255, 255/2); evas_object_show(pd->rect); evas_object_color_set(pd->rect, rand() % 255, rand() % 255, rand() % 255, 255/2); int r,g,b,a; evas_object_color_get(pd->rect, &r, &g, &b, &a); printf("color before : %d, %d, %d, %d \n", r, g, b, a); // evas_object_smart_member_add(pd->rect, obj); //elm_layout_content_set(obj, "elm.swallow.content", pd->rect); evas_object_color_get(pd->rect, &r, &g, &b, &a); printf("color after : %d, %d, %d, %d \n", r, g, b, a); evas_object_color_set(pd->rect, rand() % 255, rand() % 255, rand() % 255, 255/2); elm_widget_sub_object_add(obj, pd->rect); evas_object_color_get(pd->rect, &r, &g, &b, &a); printf("color after 222: %d, %d, %d, %d \n", r, g, b, a); */ elm_layout_file_set(obj, "edc/entry.edj", "main"); Evas_Object* en = elm_entry_add(obj); elm_entry_single_line_set(en, EINA_TRUE); elm_entry_editable_set(en, EINA_FALSE); //pd->entry = en; evas_object_size_hint_weight_set(en, EVAS_HINT_EXPAND, 0.0); //evas_object_size_hint_weight_set(en, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); evas_object_size_hint_align_set(en, EVAS_HINT_FILL, 0.5); //evas_object_size_hint_align_set(en, EVAS_HINT_FILL, EVAS_HINT_FILL); //elm_object_text_set(en, "<align=center>hello</align>"); //elm_entry_text_style_user_push(en, "DEFAULT='align=center'"); //elm_entry_text_style_user_push(en, "DEFAULT='color=#0f0'"); elm_entry_text_style_user_push(en, user_style); evas_object_data_set(obj, "realentry", en); const char* cur_style = elm_entry_text_style_user_peek(en); /* if (cur_style) printf("Current style user: %s\n", cur_style); else printf("Style user stack is empty.\n"); */ const char* yep = "aaa"; /* elm_object_text_set(en, "aaa"); if (test == 1) yep = "xxx"; if (test == 2) yep = "yyy"; if (test == 3) yep = "zzz"; test++; */ elm_object_text_set(en, yep); evas_object_name_set(en, yep); //elm_entry_scrollable_set(en, EINA_TRUE); //elm_entry_scrollbar_policy_set(en, // ELM_SCROLLER_POLICY_OFF, ELM_SCROLLER_POLICY_OFF); //evas_object_smart_member_add(rect, en); elm_layout_content_set(obj, "content", en); elm_widget_sub_object_add(obj, en); evas_object_show(en); elm_widget_can_focus_set(obj, EINA_TRUE); elm_layout_sizing_eval(obj); evas_object_data_set(en, "smart", obj); /* evas_object_smart_callback_add(en, "activated", _entry_activated, obj); evas_object_smart_callback_add(en, "unfocused", _entry_unfocused, obj); evas_object_smart_callback_add(en, "changed,user", _entry_changed, obj); //evas_object_smart_callback_add(en, "focused", _select_all, pd); //evas_object_smart_callback_add(en, "selection,changed", _print_signal, "selection changed"); evas_object_smart_callback_add(en, "selection,cleared", _entry_cleared, pd); //evas_object_smart_callback_add(en, "selection,start", _print_signal, "selection start"); //evas_object_smart_callback_add(en, "clicked", _print_signal, "clicked"); //evas_object_smart_callback_add(en, "cursor,changed", _print_signal, "cursor,changed"); //evas_object_smart_callback_add(en, "cursor,changed,manual", _print_signal, "cursor,changed,manual"); elm_layout_signal_callback_add(obj, "mouse,down,1", "bg",_ondown, pd); elm_layout_signal_callback_add(obj, "mouse,move", "bg", _onmove, obj); elm_layout_signal_callback_add(obj, "mouse,up,1", "bg", _onup, obj); elm_layout_signal_callback_add(obj, "mouse,clicked,1", "bg", _onclicked, pd); elm_layout_signal_callback_add(obj, "drag", "*", _drag_cb, obj); elm_layout_signal_callback_add(obj, "drag,start", "*", _drag_start_cb, obj); elm_layout_signal_callback_add(obj, "drag,stop", "*", _drag_stop_cb, obj); elm_layout_signal_callback_add(obj, "drag,step", "*", _drag_stop_cb, obj); elm_layout_signal_callback_add(obj, "drag,page", "*", _drag_stop_cb, obj); */ }
static void _conformant_parts_swallow(Evas_Object *obj) { Evas *e; ELM_CONFORMANT_DATA_GET(obj, sd); e = evas_object_evas_get(obj); sd->scroller = NULL; //Indicator if (!sd->indicator) { sd->indicator = evas_object_rectangle_add(e); evas_object_size_hint_min_set(sd->indicator, -1, 0); evas_object_size_hint_max_set(sd->indicator, -1, 0); } else _conformant_part_sizing_eval(obj, ELM_CONFORMANT_INDICATOR_PART); evas_object_color_set(sd->indicator, 0, 0, 0, 0); elm_layout_content_set(obj, "elm.swallow.indicator", sd->indicator); //Virtual Keyboard if (!sd->virtualkeypad) { sd->virtualkeypad = evas_object_rectangle_add(e); elm_widget_sub_object_add(obj, sd->virtualkeypad); evas_object_size_hint_max_set(sd->virtualkeypad, -1, 0); } else _conformant_part_sizing_eval(obj, ELM_CONFORMANT_VIRTUAL_KEYPAD_PART); evas_object_color_set(sd->virtualkeypad, 0, 0, 0, 0); elm_layout_content_set(obj, "elm.swallow.virtualkeypad", sd->virtualkeypad); //Clipboard if (!sd->clipboard) { sd->clipboard = evas_object_rectangle_add(e); evas_object_size_hint_min_set(sd->clipboard, -1, 0); evas_object_size_hint_max_set(sd->clipboard, -1, 0); } else _conformant_part_sizing_eval(obj, ELM_CONFORMANT_CLIPBOARD_PART); evas_object_color_set(sd->clipboard, 0, 0, 0, 0); elm_layout_content_set(obj, "elm.swallow.clipboard", sd->clipboard); //Softkey if (!sd->softkey) { sd->softkey = evas_object_rectangle_add(e); evas_object_size_hint_min_set(sd->softkey, -1, 0); evas_object_size_hint_max_set(sd->softkey, -1, 0); } else _conformant_part_sizing_eval(obj, ELM_CONFORMANT_SOFTKEY_PART); evas_object_color_set(sd->softkey, 0, 0, 0, 0); elm_layout_content_set(obj, "elm.swallow.softkey", sd->softkey); }
/* Win */ int creat_win(Em_Smart_Data *em) { Evas_Object *obj, *win; win = elm_win_add(NULL, "e_music", ELM_WIN_BASIC); em->win = win; em->evas = evas_object_evas_get(win); em->layout = elm_layout_add(win); if (!em->layout) { ERR("could not create layout.\n"); evas_object_del(win); return 0; } evas_object_size_hint_weight_set(em->layout, 1.0, 1.0); elm_win_resize_object_add(win, em->layout); evas_object_show(em->layout); em->edje = elm_layout_edje_get(em->layout); if (!elm_layout_file_set(em->layout, emusic_config_theme_get(), "emusic/main")) { int err = edje_object_load_error_get(em->edje); const char *errmsg = edje_load_error_str(err); ERR("cannot load theme '%s', group '%s': %s\n", emusic_config_theme_get(), "emusic/main", errmsg); evas_object_del(win); return 0; } Evas_Object *pg = elm_pager_add(win); em->pager = pg; elm_layout_content_set(em->layout, "pager", pg); elm_object_style_set(pg, "slide_invisible"); evas_object_show(pg); if (emusic_playlist_toolbar_creat(em)) { elm_pager_content_push(pg, em->playlist_view); } else { ERR("could not create playlist dialog.\n"); } Evas_Object *notify = emusic_notify_creat(em); if (notify) { //edje_object_part_swallow(em->edje, _EDJE_PART_NOTIFY, notify); } else { ERR("could not create notify.\n"); } if (emusic_event_bg_creat(em)) { edje_object_part_swallow(em->edje, "event_bg", em->event_bg); } else { ERR("could not create event bg.\n"); } elm_win_title_set(win, "E_Music"); evas_object_smart_callback_add(win, "delete,request", _win_del, NULL); evas_object_resize(win, 800, 400); evas_object_show(win); return 1; }