diff options
author | discomfitor <michael.blumenkrantz@gmail.com> | 2013-08-26 15:35:45 +0100 |
---|---|---|
committer | discomfitor <michael.blumenkrantz@gmail.com> | 2013-08-26 15:35:45 +0100 |
commit | c0fd17daf532a688fde83f323bd43f978665b6e6 (patch) | |
tree | 303dacda55469add02daf83a58d774ce13a7c24c /data | |
parent | e4cb87c9260758c9c7fef05bbd6ceea98dbe6032 (diff) |
add basic list module
Diffstat (limited to 'data')
-rw-r--r-- | data/themes/arrows_both.png | bin | 0 -> 7407 bytes | |||
-rw-r--r-- | data/themes/arrows_pending_left.png | bin | 0 -> 14536 bytes | |||
-rw-r--r-- | data/themes/arrows_pending_right.png | bin | 0 -> 12387 bytes | |||
-rw-r--r-- | data/themes/arrows_rejected.png | bin | 0 -> 12703 bytes | |||
-rw-r--r-- | data/themes/list_basic.edc | 156 | ||||
-rw-r--r-- | data/themes/list_basic.mk | 21 | ||||
-rw-r--r-- | data/themes/userunknown.png | bin | 0 -> 11471 bytes | |||
-rw-r--r-- | data/themes/x.png | bin | 0 -> 5219 bytes |
8 files changed, 177 insertions, 0 deletions
diff --git a/data/themes/arrows_both.png b/data/themes/arrows_both.png new file mode 100644 index 0000000..df0aa5b --- /dev/null +++ b/data/themes/arrows_both.png | |||
Binary files differ | |||
diff --git a/data/themes/arrows_pending_left.png b/data/themes/arrows_pending_left.png new file mode 100644 index 0000000..14ae207 --- /dev/null +++ b/data/themes/arrows_pending_left.png | |||
Binary files differ | |||
diff --git a/data/themes/arrows_pending_right.png b/data/themes/arrows_pending_right.png new file mode 100644 index 0000000..8b50374 --- /dev/null +++ b/data/themes/arrows_pending_right.png | |||
Binary files differ | |||
diff --git a/data/themes/arrows_rejected.png b/data/themes/arrows_rejected.png new file mode 100644 index 0000000..5291444 --- /dev/null +++ b/data/themes/arrows_rejected.png | |||
Binary files differ | |||
diff --git a/data/themes/list_basic.edc b/data/themes/list_basic.edc new file mode 100644 index 0000000..8eebf05 --- /dev/null +++ b/data/themes/list_basic.edc | |||
@@ -0,0 +1,156 @@ | |||
1 | collections { | ||
2 | group { name: "list"; | ||
3 | parts { | ||
4 | part { name: "base"; type: RECT; | ||
5 | description { state: "default"; | ||
6 | color: 0 0 0 255; | ||
7 | } | ||
8 | } | ||
9 | part { name: "swallow.list"; type: SWALLOW; | ||
10 | description { state: "default"; | ||
11 | } | ||
12 | } | ||
13 | } | ||
14 | } | ||
15 | |||
16 | group { name: "status_icon"; min: 16 16; | ||
17 | images { | ||
18 | image: "arrows_both.png" COMP; | ||
19 | image: "arrows_pending_left.png" COMP; | ||
20 | image: "arrows_pending_right.png" COMP; | ||
21 | image: "arrows_rejected.png" COMP; | ||
22 | image: "x.png" COMP; | ||
23 | } | ||
24 | script { | ||
25 | public message(Msg_Type:type, id, ...) { | ||
26 | if ((type == MSG_INT_SET) && (id == 0)) { | ||
27 | new idle, alpha; | ||
28 | |||
29 | idle = getarg(2); | ||
30 | |||
31 | custom_state(PART:"clip", "default", 0.0); | ||
32 | if (idle >= 10) { | ||
33 | alpha=255-(12*((idle-10)/10)); | ||
34 | if (alpha < 64) | ||
35 | alpha = 64; | ||
36 | } else | ||
37 | alpha=255; | ||
38 | set_state_val(PART:"clip", STATE_COLOR, 255, 255, 255, alpha); | ||
39 | } | ||
40 | } | ||
41 | } | ||
42 | parts { | ||
43 | part { name: "base"; type: RECT; | ||
44 | description { state: "default"; | ||
45 | color: 0 0 0 255; | ||
46 | } | ||
47 | } | ||
48 | part { name: "color_clip"; type: RECT; | ||
49 | description { state: "default"; | ||
50 | color: 255 255 255 255; | ||
51 | } | ||
52 | description { state: "normal"; | ||
53 | color: 0 230 0 255; | ||
54 | } | ||
55 | description { state: "away"; | ||
56 | color: 255 255 51 255; | ||
57 | } | ||
58 | description { state: "chat"; | ||
59 | color: 0 255 0 255; | ||
60 | } | ||
61 | description { state: "dnd"; | ||
62 | color: 0 0 255 255; | ||
63 | } | ||
64 | description { state: "xa"; | ||
65 | color: 255 0 0 255; | ||
66 | } | ||
67 | } | ||
68 | part { name: "clip"; type: RECT; clip_to: "color_clip"; | ||
69 | description { state: "default"; | ||
70 | color: 255 255 255 255; | ||
71 | } | ||
72 | } | ||
73 | part { name: "img"; clip_to: "clip"; | ||
74 | description { state: "default"; | ||
75 | aspect: 1.0 1.0; | ||
76 | aspect_preference: BOTH; | ||
77 | image.normal: "arrows_both.png"; | ||
78 | } | ||
79 | description { state: "left"; | ||
80 | inherit: "default"; | ||
81 | image.normal: "arrows_pending_left.png"; | ||
82 | } | ||
83 | description { state: "right"; | ||
84 | inherit: "default"; | ||
85 | image.normal: "arrows_pending_right.png"; | ||
86 | } | ||
87 | description { state: "rejected"; | ||
88 | inherit: "default"; | ||
89 | image.normal: "arrows_rejected.png"; | ||
90 | } | ||
91 | description { state: "x"; | ||
92 | inherit: "default"; | ||
93 | image.normal: "x.png"; | ||
94 | } | ||
95 | } | ||
96 | } | ||
97 | programs { | ||
98 | program { | ||
99 | signal: "s2.both"; source: "s2"; | ||
100 | action: STATE_SET "default" 0.0; | ||
101 | target: "img"; | ||
102 | } | ||
103 | program { | ||
104 | signal: "s2.left"; source: "s2"; | ||
105 | action: STATE_SET "left" 0.0; | ||
106 | target: "img"; | ||
107 | } | ||
108 | program { | ||
109 | signal: "s2.right"; source: "s2"; | ||
110 | action: STATE_SET "right" 0.0; | ||
111 | target: "img"; | ||
112 | } | ||
113 | program { | ||
114 | signal: "s2.rejected"; source: "s2"; | ||
115 | action: STATE_SET "rejected" 0.0; | ||
116 | target: "img"; | ||
117 | } | ||
118 | program { | ||
119 | signal: "s2.x"; source: "s2"; | ||
120 | action: STATE_SET "x" 0.0; | ||
121 | target: "img"; | ||
122 | } | ||
123 | #define STATUS(X) \ | ||
124 | program { \ | ||
125 | signal: X; source: "s2"; \ | ||
126 | action: STATE_SET X 0.0; \ | ||
127 | target: "color_clip"; \ | ||
128 | transition: LINEAR 0.3; \ | ||
129 | } | ||
130 | //STATUS("s2.none") | ||
131 | STATUS("s2.normal") | ||
132 | STATUS("s2.away") | ||
133 | STATUS("s2.chat") | ||
134 | STATUS("s2.dnd") | ||
135 | STATUS("s2.xa") | ||
136 | } | ||
137 | } | ||
138 | #define ICON(Name, Min, Max, Rel1, Rel2) \ | ||
139 | group { name: "list_basic/"##Name##""; min: Min Min; max: Max Max; \ | ||
140 | images.image: Name##".png" COMP; parts { part { name: "base"; \ | ||
141 | description { aspect: 1.0 1.0; aspect_preference: BOTH; rel1.offset: Rel1 Rel1; rel2.offset: Rel2 Rel2; \ | ||
142 | image.normal: Name##".png"; } } } } | ||
143 | #if 0 | ||
144 | ICON("x", 16, 0, 0, 0); | ||
145 | ICON("useradd", 16, 0, 0, 0); | ||
146 | ICON("userdel", 16, 0, 0, 0); | ||
147 | ICON("dialog_ok", 16, 0, 0, 0); | ||
148 | ICON("settings", 16, 0, 0, 0); | ||
149 | ICON("status", 16, 0, 0, 0); | ||
150 | ICON("logout", 16, 0, 0, 0); | ||
151 | |||
152 | ICON("useroffline", 16, 0, 5, -6); | ||
153 | #endif | ||
154 | ICON("userunknown", 16, 0, 5, -6); | ||
155 | |||
156 | } | ||
diff --git a/data/themes/list_basic.mk b/data/themes/list_basic.mk new file mode 100644 index 0000000..660d0e2 --- /dev/null +++ b/data/themes/list_basic.mk | |||
@@ -0,0 +1,21 @@ | |||
1 | EDJE_FLAGS = -id $(top_srcdir)/data/themes | ||
2 | |||
3 | list_basic_filesdir = $(datadir)/s2 | ||
4 | list_basic_files_DATA = data/themes/list_basic.edj | ||
5 | |||
6 | images = \ | ||
7 | data/themes/arrows_both.png \ | ||
8 | data/themes/arrows_pending_left.png \ | ||
9 | data/themes/arrows_pending_right.png \ | ||
10 | data/themes/arrows_rejected.png \ | ||
11 | data/themes/userunknown.png \ | ||
12 | data/themes/x.png | ||
13 | |||
14 | EXTRA_DIST += \ | ||
15 | data/themes/list_basic.edc \ | ||
16 | $(images) | ||
17 | |||
18 | data/themes/list_basic.edj: $(images) data/themes/list_basic.edc | ||
19 | @edje_cc@ $(EDJE_FLAGS) \ | ||
20 | $(top_srcdir)/data/themes/list_basic.edc \ | ||
21 | $(top_builddir)/data/themes/list_basic.edj | ||
diff --git a/data/themes/userunknown.png b/data/themes/userunknown.png new file mode 100644 index 0000000..cd34958 --- /dev/null +++ b/data/themes/userunknown.png | |||
Binary files differ | |||
diff --git a/data/themes/x.png b/data/themes/x.png new file mode 100644 index 0000000..55f7e8a --- /dev/null +++ b/data/themes/x.png | |||
Binary files differ | |||