forked from enlightenment/enventor
help: code refactoring.
Replaced bg to image. Put the bg image resource into enventor theme.
This commit is contained in:
parent
09ea8541bb
commit
17ba4a2cd3
|
@ -34,7 +34,6 @@ files_DATA = ENVENTOR_EMBEDDED_IMAGE.png \
|
|||
ENVENTOR_EMBEDDED_ICON_DOCK_DOWN.png \
|
||||
ENVENTOR_EMBEDDED_ICON_LOCK.png \
|
||||
ENVENTOR_EMBEDDED_ICON_LOCK_DOWN.png \
|
||||
ENVENTOR_EMBEDDED_FULL_LOGO.png \
|
||||
enventor_logo.png
|
||||
|
||||
EXTRA_DIST = $(files_DATA)
|
||||
|
|
|
@ -48,6 +48,7 @@ images {
|
|||
image: "left.png" COMP;
|
||||
image: "right.png" COMP;
|
||||
image: "filetab.png" COMP;
|
||||
image: "about.png" COMP;
|
||||
}
|
||||
|
||||
#define ICON_GROUP(_group_name, _image_path) \
|
||||
|
@ -109,5 +110,6 @@ ICON_GROUP("wireframes_icon", "icon_wireframes.png")
|
|||
ICON_GROUP("left_arrow", "left.png")
|
||||
ICON_GROUP("right_arrow", "right.png")
|
||||
ICON_GROUP("filetab", "filetab.png")
|
||||
ICON_GROUP("about", "about.png")
|
||||
|
||||
#undef ICON_GROUP
|
||||
|
|
|
@ -101,4 +101,5 @@ EXTRA_DIST = \
|
|||
bevel_curved_vert_out.png \
|
||||
vgrad_med_dark.png \
|
||||
shadow_rounded_vert.png \
|
||||
wireframes.png
|
||||
wireframes.png \
|
||||
about.png
|
||||
|
|
Before Width: | Height: | Size: 43 KiB After Width: | Height: | Size: 43 KiB |
|
@ -154,7 +154,8 @@ help_open(void)
|
|||
//Win
|
||||
win = elm_win_add(base_win_get(), _("Enventor Help"), ELM_WIN_BASIC);
|
||||
elm_win_focus_highlight_enabled_set(win, EINA_TRUE);
|
||||
elm_win_title_set(win, _("About Enventor"));
|
||||
snprintf(buf, sizeof(buf), "About Enventor v%s", PACKAGE_VERSION);
|
||||
elm_win_title_set(win, buf);
|
||||
evas_object_smart_callback_add(win, "delete,request", win_delete_request_cb,
|
||||
NULL);
|
||||
evas_object_smart_callback_add(win, "moved", win_moved_cb, NULL);
|
||||
|
@ -172,21 +173,13 @@ help_open(void)
|
|||
evas_object_show(box);
|
||||
|
||||
//Title Bg
|
||||
Evas_Object *title_bg = elm_bg_add(box);
|
||||
snprintf(buf, sizeof(buf), "%s/images/ENVENTOR_EMBEDDED_FULL_LOGO.png",
|
||||
elm_app_data_dir_get());
|
||||
elm_bg_file_set(title_bg, buf, NULL);
|
||||
Evas_Object *title_bg = elm_image_add(box);
|
||||
elm_image_file_set(title_bg, EDJE_PATH, "about");
|
||||
evas_object_size_hint_align_set(title_bg, EVAS_HINT_FILL, EVAS_HINT_FILL);
|
||||
evas_object_size_hint_min_set(title_bg, 430, 100);
|
||||
elm_box_pack_end(box, title_bg);
|
||||
evas_object_show(title_bg);
|
||||
|
||||
//Version Label
|
||||
Evas_Object *label = elm_label_add(title_bg);
|
||||
elm_object_text_set(label, "<align=0.95>Enventor v0.9.0</align>");
|
||||
elm_object_content_set(title_bg, label);
|
||||
evas_object_show(label);
|
||||
|
||||
//Entry Box
|
||||
Evas_Object *entry_box = elm_box_add(win);
|
||||
evas_object_size_hint_weight_set(entry_box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
|
||||
|
@ -258,6 +251,6 @@ help_close(void)
|
|||
//Save last state
|
||||
evas_object_geometry_get(win, NULL, NULL, &win_w, &win_h);
|
||||
elm_win_screen_position_get(win, &win_x, &win_y);
|
||||
evas_object_del(win);
|
||||
evas_object_del(win);
|
||||
g_win = NULL;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue