forked from enlightenment/enlightenment
298 lines
6.0 KiB
Plaintext
298 lines
6.0 KiB
Plaintext
images {
|
|
image: "e17_battery_000.png" COMP;
|
|
image: "e17_battery_010.png" COMP;
|
|
image: "e17_battery_020.png" COMP;
|
|
image: "e17_battery_030.png" COMP;
|
|
image: "e17_battery_040.png" COMP;
|
|
image: "e17_battery_050.png" COMP;
|
|
image: "e17_battery_060.png" COMP;
|
|
image: "e17_battery_070.png" COMP;
|
|
image: "e17_battery_080.png" COMP;
|
|
image: "e17_battery_090.png" COMP;
|
|
image: "e17_battery_100.png" COMP;
|
|
image: "e17_battery_ac.png" COMP;
|
|
}
|
|
group {
|
|
name: "e/modules/battery/main";
|
|
max: 128 128;
|
|
script {
|
|
public message(Msg_Type:type, id, ...) {
|
|
if ((type == MSG_FLOAT) && (id == 1)) {
|
|
new Float:val;
|
|
val = getfarg(2);
|
|
set_state(PART:"battery", "default", val);
|
|
}
|
|
}
|
|
}
|
|
parts {
|
|
part {
|
|
name: "battery";
|
|
clip_to: "pulse_clip";
|
|
description {
|
|
state: "default" 0.0;
|
|
aspect: 0.669291339 0.669291339;
|
|
aspect_preference: BOTH;
|
|
align: 0.0 0.5;
|
|
max: 85 127;
|
|
rel1 {
|
|
relative: 0.0 0.0;
|
|
}
|
|
rel2 {
|
|
relative: 1.0 1.0;
|
|
}
|
|
image {
|
|
normal: "e17_battery_000.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.1;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_010.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.2;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_020.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.3;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_030.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.4;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_040.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.5;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_050.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.6;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_060.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.7;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_070.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.8;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_080.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 0.9;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_090.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "default" 1.0;
|
|
inherit: "default" 0.0;
|
|
image {
|
|
normal: "e17_battery_100.png";
|
|
}
|
|
}
|
|
}
|
|
part {
|
|
name: "ac";
|
|
clip_to: "fade_clip";
|
|
description {
|
|
state: "default" 0.0;
|
|
aspect: 0.975609756 0.975609756;
|
|
aspect_preference: BOTH;
|
|
align: 1.0 1.0;
|
|
max: 40 41;
|
|
visible: 0;
|
|
rel1 {
|
|
relative: 0.5 0.5;
|
|
}
|
|
rel2 {
|
|
relative: 1.0 1.0;
|
|
}
|
|
image {
|
|
normal: "e17_battery_ac.png";
|
|
}
|
|
}
|
|
description {
|
|
state: "active" 0.0;
|
|
inherit: "default" 0.0;
|
|
visible: 1;
|
|
}
|
|
}
|
|
part {
|
|
name: "e.text.reading";
|
|
type: TEXT;
|
|
effect: OUTLINE_SOFT_SHADOW;
|
|
clip_to: "fade_clip";
|
|
description {
|
|
state: "default" 0.0;
|
|
align: 1.0 0.0;
|
|
rel1 {
|
|
relative: 1.0 0.0;
|
|
to_x: "battery";
|
|
}
|
|
rel2 {
|
|
relative: 1.0 0.0;
|
|
}
|
|
color: 255 255 255 255;
|
|
color2: 0 0 0 128;
|
|
color3: 0 0 0 32;
|
|
color_class: "module_label";
|
|
text {
|
|
text: "100%";
|
|
font: "Edje-Vera-Bold";
|
|
size: 8;
|
|
min: 1 1;
|
|
align: 1.0 0.0;
|
|
text_class: "module_small";
|
|
}
|
|
}
|
|
}
|
|
part {
|
|
name: "e.text.time";
|
|
type: TEXT;
|
|
effect: OUTLINE_SOFT_SHADOW;
|
|
clip_to: "fade_clip";
|
|
description {
|
|
state: "default" 0.0;
|
|
align: 1.0 0.0;
|
|
rel1 {
|
|
relative: 1.0 1.0;
|
|
to_x: "battery";
|
|
to_y: "e.text.reading";
|
|
}
|
|
rel2 {
|
|
relative: 1.0 1.0;
|
|
to_y: "e.text.reading";
|
|
}
|
|
color: 255 255 255 255;
|
|
color2: 0 0 0 128;
|
|
color3: 0 0 0 32;
|
|
color_class: "module_label";
|
|
text {
|
|
text: "00:00";
|
|
font: "Edje-Vera-Bold";
|
|
size: 8;
|
|
min: 1 1;
|
|
align: 1.0 0.0;
|
|
text_class: "module_small";
|
|
}
|
|
}
|
|
}
|
|
part {
|
|
name: "fade_clip";
|
|
type: RECT;
|
|
mouse_events: 0;
|
|
description {
|
|
state: "default" 0.0;
|
|
color: 255 255 255 255;
|
|
}
|
|
description {
|
|
state: "faded" 0.0;
|
|
color: 255 255 255 128;
|
|
}
|
|
}
|
|
part {
|
|
name: "pulse_clip";
|
|
type: RECT;
|
|
mouse_events: 0;
|
|
clip_to: "fade_clip";
|
|
description {
|
|
state: "default" 0.0;
|
|
color: 255 255 255 255;
|
|
}
|
|
description {
|
|
state: "faded" 1.0;
|
|
color: 255 255 255 255;
|
|
}
|
|
description {
|
|
state: "faded" 0.0;
|
|
color: 255 255 255 0;
|
|
}
|
|
}
|
|
}
|
|
programs {
|
|
program {
|
|
name: "charge";
|
|
signal: "e,state,charging";
|
|
source: "e";
|
|
action: STATE_SET "default" 0.0;
|
|
target: "fade_clip";
|
|
}
|
|
program {
|
|
name: "charge2";
|
|
signal: "e,state,charging";
|
|
source: "e";
|
|
action: STATE_SET "active" 0.0;
|
|
target: "ac";
|
|
}
|
|
program {
|
|
name: "discharge";
|
|
signal: "e,state,discharging";
|
|
source: "e";
|
|
action: STATE_SET "default" 0.0;
|
|
target: "fade_clip";
|
|
}
|
|
program {
|
|
name: "discharge2";
|
|
signal: "e,state,discharging";
|
|
source: "e";
|
|
action: STATE_SET "default" 0.0;
|
|
target: "ac";
|
|
}
|
|
program {
|
|
name: "unknown";
|
|
signal: "e,state,unknown";
|
|
source: "e";
|
|
action: STATE_SET "faded" 0.0;
|
|
target: "fade_clip";
|
|
}
|
|
program {
|
|
name: "pulse";
|
|
signal: "e,action,pulse,start";
|
|
source: "e";
|
|
action: STATE_SET "faded" 0.0;
|
|
transition: ACCELERATE 0.3;
|
|
after: "pulse2";
|
|
target: "pulse_clip";
|
|
}
|
|
program {
|
|
name: "pulse2";
|
|
signal: "pulse2";
|
|
source: "e";
|
|
action: STATE_SET "faded" 1.0;
|
|
transition: ACCELERATE 0.1;
|
|
target: "pulse_clip";
|
|
}
|
|
program {
|
|
name: "pulsestop";
|
|
signal: "e,action,pulse,stop";
|
|
source: "e";
|
|
action: STATE_SET "default" 0.0;
|
|
target: "pulse_clip";
|
|
}
|
|
}
|
|
}
|