ilist: look less like arse :)

SVN revision: 18320
This commit is contained in:
Carsten Haitzler 2005-11-05 13:45:08 +00:00
parent 88281ed2fc
commit 26a521d8e9
6 changed files with 858 additions and 23 deletions

View File

@ -1,9 +1,142 @@
images {
image: "focus.png" COMP;
image: "e17_ilist_bg0.png" COMP;
image: "e17_ilist_bg1.png" COMP;
}
group {
name: "widgets/ilist";
parts {
part {
name: "base";
mouse_events: 0;
description {
state: "default" 0.0;
image {
normal: "e17_ilist_bg0.png";
border: 3 3 3 3;
}
}
}
part {
name: "title_shadow2";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
rel1 {
relative: 0.0 0.0;
offset: 0 0;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -1 -1;
to: "title_bar";
}
image {
normal: "e17_titlebar_shadow2.png";
border: 8 8 8 8;
}
fill {
smooth: 0;
}
color: 255 255 255 0;
}
description {
state: "active" 0.0;
visible: 1;
rel1 {
relative: 0.0 0.0;
offset: 0 0;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -1 -1;
to: "title_bar";
}
image {
normal: "e17_titlebar_shadow2.png";
border: 8 8 8 8;
}
fill {
smooth: 0;
}
color: 255 255 255 255;
}
}
part {
name: "title_shadow1";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
rel1 {
relative: 0.0 0.0;
offset: 0 0;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -1 -1;
to: "title_bar";
}
image {
normal: "e17_titlebar_shadow1.png";
border: 8 8 8 8;
}
fill {
smooth: 0;
}
color: 255 255 255 0;
}
description {
state: "active" 0.0;
visible: 1;
rel1 {
relative: 0.0 0.0;
offset: 0 0;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -1 -1;
to: "title_bar";
}
image {
normal: "e17_titlebar_shadow1.png";
border: 8 8 8 8;
}
fill {
smooth: 0;
}
color: 255 255 255 255;
}
}
part {
name: "title_bar";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
image {
normal: "e17_titlebar.png";
border: 8 8 8 8;
}
rel1 {
offset: -4 -4;
}
rel2 {
offset: 3 3;
}
color: 255 255 255 0;
}
description {
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
}
}
part {
name: "icon_swallow";
type: SWALLOW;
@ -52,26 +185,168 @@ group {
}
}
part {
name: "overlay";
mouse_events: 0;
name: "title_glint_clip";
type: RECT;
mouse_events: 0;
description {
state: "default" 0.0;
visible: 1;
color: 255 255 255 32;
rel1 {
offset: 3 3;
to: "title_bar";
}
rel2 {
offset: -4 -4;
to: "title_bar";
}
color: 255 255 255 255;
}
}
part {
name: "title_glint_1";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
color: 255 255 255 0;
align: 0.0 0.0;
max: 34 13;
rel1 {
relative: 0.0 0.0;
offset: 2 2;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -3 -3;
to: "title_bar";
}
image {
normal: "focus.png";
border: 7 7 7 7;
middle: 0;
normal: "e17_titlebar_glint1.png";
border: 5 0 5 0;
}
fill {
smooth: 0;
}
}
description {
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
}
}
part {
name: "title_glint_2";
mouse_events: 0;
clip_to: "title_glint_clip";
description {
state: "default" 0.0;
visible: 0;
color: 255 255 255 0;
align: 1.0 0.5;
max: 0 0;
rel1 {
relative: 0.0 0.0;
offset: 3 3;
to: "title_bar";
}
rel2 {
relative: 0.0 1.0;
offset: 3 -4;
to: "title_bar";
}
image {
normal: "e17_titlebar_glint2.png";
border: 0 0 5 5;
}
fill {
smooth: 0;
}
}
description {
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
max: 169 9999;
min: 169 8;
align: 0.5 0.5;
rel1 {
relative: 0.0 0.0;
offset: 3 3;
}
rel2 {
relative: 0.0 1.0;
offset: 3 -4;
}
}
description {
state: "active2" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 128;
max: 169 9999;
min: 169 8;
align: 0.5 0.5;
rel1 {
relative: 1.0 0.0;
offset: -4 3;
}
rel2 {
relative: 1.0 1.0;
offset: -4 -4;
}
}
description {
state: "active3" 0.0;
inherit: "default" 0.0;
visible: 0;
color: 255 255 255 0;
max: 169 9999;
min: 169 8;
align: 0.0 0.5;
rel1 {
relative: 1.0 0.0;
offset: -4 3;
}
rel2 {
relative: 1.0 1.0;
offset: -4 -4;
}
}
}
part {
name: "title_glint_3";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
color: 255 255 255 0;
align: 1.0 1.0;
max: 34 13;
rel1 {
relative: 0.0 0.0;
offset: 2 2;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -3 -3;
to: "title_bar";
}
image {
normal: "e17_titlebar_glint3.png";
border: 0 5 0 5;
}
fill {
smooth: 0;
}
}
description {
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
}
}
part {
@ -85,18 +360,574 @@ group {
}
programs {
program {
name: "go_active";
name: "go_active_pre";
signal: "active";
source: "";
action: STATE_SET "default" 0.0;
target: "title_bar";
target: "title_shadow1";
target: "title_shadow2";
after: "go_active";
}
program {
name: "go_active";
action: STATE_SET "active" 0.0;
target: "overlay";
target: "title_bar";
transition: LINEAR 0.05;
after: "go_active2";
}
program {
name: "go_active2";
action: STATE_SET "active" 0.0;
target: "title_shadow1";
transition: LINEAR 0.05;
after: "go_active3";
after: "go_active3b";
}
program {
name: "go_active3";
action: STATE_SET "active" 0.0;
target: "title_shadow2";
transition: LINEAR 0.05;
}
program {
name: "go_active3b";
action: STATE_SET "active" 0.0;
target: "title_glint_1";
target: "title_glint_2";
transition: LINEAR 0.05;
after: "go_active4";
after: "go_active4b";
}
program {
name: "go_active4";
action: STATE_SET "active2" 0.0;
target: "title_glint_2";
transition: LINEAR 0.2;
after: "go_active5";
after: "go_active5b";
}
program {
name: "go_active4b";
action: STATE_SET "active" 0.0;
target: "title_glint_3";
transition: LINEAR 0.2;
}
program {
name: "go_active5";
action: STATE_SET "active3" 0.0;
target: "title_glint_2";
transition: LINEAR 0.05;
}
program {
name: "go_active5b";
action: STATE_SET "default" 0.0;
target: "title_glint_3";
transition: LINEAR 0.1;
after: "go_active6";
}
program {
name: "go_active6";
action: STATE_SET "default" 0.0;
target: "title_glint_1";
target: "title_glint_2";
target: "title_glint_3";
}
program {
name: "go_passive_pre";
signal: "passive";
source: "";
action: STATE_SET "active" 0.0;
target: "title_bar";
target: "title_shadow1";
target: "title_shadow2";
after: "go_passive";
}
program {
name: "go_passive";
signal: "passive";
source: "";
action: STATE_SET "default" 0.0;
target: "overlay";
target: "title_shadow2";
transition: LINEAR 0.1;
after: "go_passive2";
}
program {
name: "go_passive2";
action: STATE_SET "default" 0.0;
target: "title_shadow1";
transition: LINEAR 0.1;
after: "go_passive3";
}
program {
name: "go_passive3";
action: STATE_SET "default" 0.0;
target: "title_bar";
transition: LINEAR 0.1;
}
}
}
group {
name: "widgets/ilist_odd";
parts {
part {
name: "base";
mouse_events: 0;
description {
state: "default" 0.0;
image {
normal: "e17_ilist_bg1.png";
border: 3 3 3 3;
}
}
}
part {
name: "title_shadow2";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
rel1 {
relative: 0.0 0.0;
offset: 0 0;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -1 -1;
to: "title_bar";
}
image {
normal: "e17_titlebar_shadow2.png";
border: 8 8 8 8;
}
fill {
smooth: 0;
}
color: 255 255 255 0;
}
description {
state: "active" 0.0;
visible: 1;
rel1 {
relative: 0.0 0.0;
offset: 0 0;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -1 -1;
to: "title_bar";
}
image {
normal: "e17_titlebar_shadow2.png";
border: 8 8 8 8;
}
fill {
smooth: 0;
}
color: 255 255 255 255;
}
}
part {
name: "title_shadow1";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
rel1 {
relative: 0.0 0.0;
offset: 0 0;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -1 -1;
to: "title_bar";
}
image {
normal: "e17_titlebar_shadow1.png";
border: 8 8 8 8;
}
fill {
smooth: 0;
}
color: 255 255 255 0;
}
description {
state: "active" 0.0;
visible: 1;
rel1 {
relative: 0.0 0.0;
offset: 0 0;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -1 -1;
to: "title_bar";
}
image {
normal: "e17_titlebar_shadow1.png";
border: 8 8 8 8;
}
fill {
smooth: 0;
}
color: 255 255 255 255;
}
}
part {
name: "title_bar";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
image {
normal: "e17_titlebar.png";
border: 8 8 8 8;
}
rel1 {
offset: -4 -4;
}
rel2 {
offset: 3 3;
}
color: 255 255 255 0;
}
description {
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
}
}
part {
name: "icon_swallow";
type: SWALLOW;
mouse_events: 0;
description {
state: "default" 0.0;
align: 0.0 0.5;
aspect: 1.0 1.0;
aspect_preference: VERTICAL;
rel1 {
relative: 0.0 0.0;
offset: 2 2;
}
rel2 {
relative: 0.0 1.0;
offset: 2 -3;
}
}
}
part {
name: "label";
type: TEXT;
effect: SHADOW;
mouse_events: 0;
description {
state: "default" 0.0;
min: 16 16;
rel1 {
to_x: "icon_swallow";
relative: 1.0 0.0;
offset: 2 2;
}
rel2 {
relative: 1.0 1.0;
offset: -2 -2;
}
color: 0 0 0 255;
color3: 255 255 255 128;
text {
text: "Item Label";
font: "Edje-Vera";
size: 10;
min: 1 1;
align: 0.0 0.5;
}
}
}
part {
name: "title_glint_clip";
type: RECT;
mouse_events: 0;
description {
state: "default" 0.0;
rel1 {
offset: 3 3;
to: "title_bar";
}
rel2 {
offset: -4 -4;
to: "title_bar";
}
color: 255 255 255 255;
}
}
part {
name: "title_glint_1";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
color: 255 255 255 0;
align: 0.0 0.0;
max: 34 13;
rel1 {
relative: 0.0 0.0;
offset: 2 2;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -3 -3;
to: "title_bar";
}
image {
normal: "e17_titlebar_glint1.png";
border: 5 0 5 0;
}
fill {
smooth: 0;
}
}
description {
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
}
}
part {
name: "title_glint_2";
mouse_events: 0;
clip_to: "title_glint_clip";
description {
state: "default" 0.0;
visible: 0;
color: 255 255 255 0;
align: 1.0 0.5;
max: 0 0;
rel1 {
relative: 0.0 0.0;
offset: 3 3;
to: "title_bar";
}
rel2 {
relative: 0.0 1.0;
offset: 3 -4;
to: "title_bar";
}
image {
normal: "e17_titlebar_glint2.png";
border: 0 0 5 5;
}
fill {
smooth: 0;
}
}
description {
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
max: 169 9999;
min: 169 8;
align: 0.5 0.5;
rel1 {
relative: 0.0 0.0;
offset: 3 3;
}
rel2 {
relative: 0.0 1.0;
offset: 3 -4;
}
}
description {
state: "active2" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 128;
max: 169 9999;
min: 169 8;
align: 0.5 0.5;
rel1 {
relative: 1.0 0.0;
offset: -4 3;
}
rel2 {
relative: 1.0 1.0;
offset: -4 -4;
}
}
description {
state: "active3" 0.0;
inherit: "default" 0.0;
visible: 0;
color: 255 255 255 0;
max: 169 9999;
min: 169 8;
align: 0.0 0.5;
rel1 {
relative: 1.0 0.0;
offset: -4 3;
}
rel2 {
relative: 1.0 1.0;
offset: -4 -4;
}
}
}
part {
name: "title_glint_3";
mouse_events: 0;
description {
state: "default" 0.0;
visible: 0;
color: 255 255 255 0;
align: 1.0 1.0;
max: 34 13;
rel1 {
relative: 0.0 0.0;
offset: 2 2;
to: "title_bar";
}
rel2 {
relative: 1.0 1.0;
offset: -3 -3;
to: "title_bar";
}
image {
normal: "e17_titlebar_glint3.png";
border: 0 5 0 5;
}
fill {
smooth: 0;
}
}
description {
state: "active" 0.0;
inherit: "default" 0.0;
visible: 1;
color: 255 255 255 255;
}
}
part {
name: "event";
type: RECT;
description {
state: "default" 0.0;
color: 0 0 0 0;
}
}
}
programs {
program {
name: "go_active_pre";
signal: "active";
source: "";
action: STATE_SET "default" 0.0;
target: "title_bar";
target: "title_shadow1";
target: "title_shadow2";
after: "go_active";
}
program {
name: "go_active";
action: STATE_SET "active" 0.0;
target: "title_bar";
transition: LINEAR 0.05;
after: "go_active2";
}
program {
name: "go_active2";
action: STATE_SET "active" 0.0;
target: "title_shadow1";
transition: LINEAR 0.05;
after: "go_active3";
after: "go_active3b";
}
program {
name: "go_active3";
action: STATE_SET "active" 0.0;
target: "title_shadow2";
transition: LINEAR 0.05;
}
program {
name: "go_active3b";
action: STATE_SET "active" 0.0;
target: "title_glint_1";
target: "title_glint_2";
transition: LINEAR 0.05;
after: "go_active4";
after: "go_active4b";
}
program {
name: "go_active4";
action: STATE_SET "active2" 0.0;
target: "title_glint_2";
transition: LINEAR 0.2;
after: "go_active5";
after: "go_active5b";
}
program {
name: "go_active4b";
action: STATE_SET "active" 0.0;
target: "title_glint_3";
transition: LINEAR 0.2;
}
program {
name: "go_active5";
action: STATE_SET "active3" 0.0;
target: "title_glint_2";
transition: LINEAR 0.05;
}
program {
name: "go_active5b";
action: STATE_SET "default" 0.0;
target: "title_glint_3";
transition: LINEAR 0.1;
after: "go_active6";
}
program {
name: "go_active6";
action: STATE_SET "default" 0.0;
target: "title_glint_1";
target: "title_glint_2";
target: "title_glint_3";
}
program {
name: "go_passive_pre";
signal: "passive";
source: "";
action: STATE_SET "active" 0.0;
target: "title_bar";
target: "title_shadow1";
target: "title_shadow2";
after: "go_passive";
}
program {
name: "go_passive";
action: STATE_SET "default" 0.0;
target: "title_shadow2";
transition: LINEAR 0.1;
after: "go_passive2";
}
program {
name: "go_passive2";
action: STATE_SET "default" 0.0;
target: "title_shadow1";
transition: LINEAR 0.1;
after: "go_passive3";
}
program {
name: "go_passive3";
action: STATE_SET "default" 0.0;
target: "title_bar";
transition: LINEAR 0.1;
}
}
}

View File

@ -406,4 +406,6 @@ e17_sb_btr2.png \
e17_sb_btu1.png \
e17_sb_btu2.png \
e17_sb_runnerh.png \
e17_sb_runnerv.png
e17_sb_runnerv.png \
e17_ilist_bg0.png \
e17_ilist_bg1.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 627 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 669 B

View File

@ -97,10 +97,10 @@ e_ilist_append(Evas_Object *obj, Evas_Object *icon, char *label, void (*func) (
si = E_NEW(E_Smart_Item, 1);
si->sd = sd;
si->base_obj = edje_object_add(evas_object_evas_get(sd->smart_obj));
// if (evas_list_count(sd->items) & 0x1)
// e_theme_edje_object_set(si->base_obj, "base/theme/widgets",
// "widgets/ilist_odd");
// else
if (evas_list_count(sd->items) & 0x1)
e_theme_edje_object_set(si->base_obj, "base/theme/widgets",
"widgets/ilist_odd");
else
e_theme_edje_object_set(si->base_obj, "base/theme/widgets",
"widgets/ilist");
edje_object_part_text_set(si->base_obj, "label", label);
@ -128,6 +128,7 @@ e_ilist_append(Evas_Object *obj, Evas_Object *icon, char *label, void (*func) (
edje_object_signal_emit(si->base_obj, "active", "");
if (si->func) si->func(si->data);
}
evas_object_lower(si->base_obj);
evas_object_event_callback_add(si->base_obj, EVAS_CALLBACK_MOUSE_DOWN, _e_smart_event_mouse_down, si);
evas_object_show(si->base_obj);
}
@ -148,6 +149,7 @@ e_ilist_select_set(Evas_Object *obj, int n)
si = evas_list_nth(sd->items, sd->selected);
if (si)
{
evas_object_raise(si->base_obj);
edje_object_signal_emit(si->base_obj, "active", "");
if (si->func) si->func(si->data);
}

View File

@ -392,7 +392,7 @@ _e_test_internal(E_Container *con)
tcon = con;
_e_test_timer(NULL);
}
#elif 0
#elif 1
struct _tmp
{