summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler <raster@rasterman.com>2006-09-10 04:51:07 +0000
committerCarsten Haitzler <raster@rasterman.com>2006-09-10 04:51:07 +0000
commit71be7e7882046f53831a8f4101014b516846dd26 (patch)
treefd2a3a8bfa175491919b61b3cd110615b960e792
parenta2691b6c1eabdfd036b57ad971164cb35fcb513c (diff)
sys actions have status/info/progress dialogs that should work right for all
actions (so you know what is going on and have some feedback/status). SVN revision: 25670
-rw-r--r--data/themes/Makefile.am3
-rw-r--r--data/themes/default.edc1
-rw-r--r--data/themes/default_sys.edc1210
-rw-r--r--src/bin/Makefile.am2
-rw-r--r--src/bin/e_about.h2
-rw-r--r--src/bin/e_color_dialog.h2
-rw-r--r--src/bin/e_entry_dialog.h2
-rw-r--r--src/bin/e_file_dialog.h2
-rw-r--r--src/bin/e_gadcon.h4
-rw-r--r--src/bin/e_includes.h1
-rw-r--r--src/bin/e_obj_dialog.c129
-rw-r--r--src/bin/e_obj_dialog.h30
-rw-r--r--src/bin/e_shelf.h2
-rw-r--r--src/bin/e_sys.c85
14 files changed, 1457 insertions, 18 deletions
diff --git a/data/themes/Makefile.am b/data/themes/Makefile.am
index bf4be83..c4a508c 100644
--- a/data/themes/Makefile.am
+++ b/data/themes/Makefile.am
@@ -56,7 +56,8 @@ default_shelf.edc \
56default_preview.edc \ 56default_preview.edc \
57default_cslider.edc \ 57default_cslider.edc \
58default_spectrum.edc \ 58default_spectrum.edc \
59default_color_well.edc 59default_color_well.edc \
60default_sys.edc
60 61
61default.edj: Makefile $(EXTRA_DIST) 62default.edj: Makefile $(EXTRA_DIST)
62 $(EDJE_CC) $(EDJE_FLAGS) \ 63 $(EDJE_CC) $(EDJE_FLAGS) \
diff --git a/data/themes/default.edc b/data/themes/default.edc
index 5bd1dce..51ad5db 100644
--- a/data/themes/default.edc
+++ b/data/themes/default.edc
@@ -74,5 +74,6 @@ collections {
74#include "default_cslider.edc" 74#include "default_cslider.edc"
75#include "default_spectrum.edc" 75#include "default_spectrum.edc"
76#include "default_color_well.edc" 76#include "default_color_well.edc"
77#include "default_sys.edc"
77} 78}
78 79
diff --git a/data/themes/default_sys.edc b/data/themes/default_sys.edc
new file mode 100644
index 0000000..1021f58
--- /dev/null
+++ b/data/themes/default_sys.edc
@@ -0,0 +1,1210 @@
1images {
2 image: "e17_menu_bg_border.png" COMP;
3 image: "e17_dialog_watermark.png" COMP;
4
5 image: "e17_logo_small.png" COMP;
6 image: "e17_logo_small_p1.png" COMP;
7 image: "e17_logo_small_p2.png" COMP;
8 image: "e17_logo_small_p3.png" COMP;
9 image: "e17_logo_small_p4.png" COMP;
10 image: "e17_logo_small_p5.png" COMP;
11 image: "e17_logo_small_p6.png" COMP;
12 image: "e17_logo_small_p7.png" COMP;
13 image: "e17_logo_small_p8.png" COMP;
14 image: "e17_logo_small_p9.png" COMP;
15 image: "e17_logo_small_p21.png" COMP;
16 image: "e17_logo_small_p22.png" COMP;
17 image: "e17_logo_small_p23.png" COMP;
18 image: "e17_logo_small_p24.png" COMP;
19 image: "e17_logo_small_p25.png" COMP;
20 image: "e17_logo_small_p26.png" COMP;
21 image: "e17_logo_small_p27.png" COMP;
22 image: "e17_logo_small_p28.png" COMP;
23 image: "e17_logo_small_p29.png" COMP;
24}
25
26styles
27{
28 style {
29 name: "sys_style";
30 base: "font=Edje-Vera-Bold font_size=16 text_class=tb_large align=center color=#fff style=soft_shadow shadow_color=#0002 wrap=word";
31
32 tag: "br" "\n";
33 tag: "hilight" "+ font=Edje-Vera-Bold text_class=tb_large_light style=glow color=#fff glow2_color=#fe87 glow_color=#fa14";
34 }
35}
36
37group {
38 name: "e/sys/logout";
39 parts {
40 part {
41 name: "base";
42 mouse_events: 0;
43 type: RECT;
44 description {
45 state: "default" 0.0;
46 rel1 {
47 relative: 0.0 0.0;
48 offset: 1 1;
49 }
50 rel2 {
51 relative: 1.0 1.0;
52 offset: -2 -2;
53 }
54 color: 221 221 221 255;
55 }
56 }
57 part {
58 name: "base2";
59 mouse_events: 0;
60 description {
61 state: "default" 0.0;
62 min: 200 138;
63 max: 200 138;
64 align: 1.0 1.0;
65 fixed: 1 1;
66 rel1 {
67 relative: 1.0 1.0;
68 offset: -1 -1;
69 }
70 rel2 {
71 relative: 1.0 1.0;
72 offset: -1 -1;
73 }
74 image {
75 normal: "e17_dialog_watermark.png";
76 }
77 }
78 }
79 part {
80 name: "base3";
81 mouse_events: 0;
82 description {
83 state: "default" 0.0;
84 rel1 {
85 relative: 0.0 0.0;
86 offset: 0 0;
87 }
88 rel2 {
89 relative: 1.0 1.0;
90 offset: -1 -1;
91 }
92 image {
93 normal: "e17_menu_bg_border.png";
94 border: 1 1 1 1;
95 middle: 0;
96 }
97 fill {
98 smooth: 0;
99 }
100 }
101 }
102 part {
103 name: "e.textblock.message";
104 type: TEXTBLOCK;
105 mouse_events: 0;
106 description {
107 state: "default" 0.0;
108 rel1 {
109 to_y: "logo";
110 relative: 0.0 1.0;
111 offset: 8 8;
112 }
113 rel2 {
114 offset: -9 -9;
115 }
116 text {
117 style: "sys_style";
118 min: 1 1;
119 }
120 }
121 }
122 part {
123 name: "logo";
124 mouse_events: 0;
125 description {
126 state: "default" 0.0;
127 aspect: 1.0 1.0;
128 aspect_preference: BOTH;
129 min: 128 128;
130 max: 128 128;
131 align: 0.5 0.0;
132 rel1 {
133 relative: 0.0 0.0;
134 offset: 8 8;
135 }
136 rel2 {
137 relative: 1.0 0.0;
138 offset: -9 8;
139 }
140 image {
141 normal: "e17_logo_small.png";
142 }
143 }
144 }
145#define PT(_name, _p1, _p2, _p3, _p4) \
146 part { \
147 name: _name; \
148 mouse_events: 0; \
149 description { \
150 state: "default" 0.0; \
151 visible: 0; \
152 rel1 { \
153 to: "logo"; \
154 relative: _p1 _p2; \
155 } \
156 rel2 { \
157 to: "logo"; \
158 relative: _p3 _p4; \
159 } \
160 image { \
161 normal: "e17_logo_small_"_name".png"; \
162 } \
163 color: 255 255 255 0; \
164 } \
165 description { \
166 state: "active" 0.0; \
167 inherit: "default" 0.0; \
168 rel1 { \
169 to: "logo"; \
170 relative: _p1 _p2; \
171 } \
172 rel2 { \
173 to: "logo"; \
174 relative: _p3 _p4; \
175 } \
176 visible: 1; \
177 color: 255 255 255 255; \
178 } \
179 }
180 PT("p1", 0.1328125, 0.1640625, 0.3359375, 0.3593750);
181 PT("p2", 0.1953125, 0.1093750, 0.3906250, 0.3125000);
182 PT("p3", 0.2656250, 0.0625000, 0.4531250, 0.2734375);
183 PT("p4", 0.3359375, 0.0312500, 0.5234375, 0.2500000);
184 PT("p5", 0.4062500, 0.0234375, 0.5937500, 0.2421875);
185 PT("p6", 0.4765625, 0.0312500, 0.6640625, 0.2500000);
186 PT("p7", 0.5468750, 0.0625000, 0.7343750, 0.2734375);
187 PT("p8", 0.6093750, 0.1093750, 0.8046875, 0.3125000);
188 PT("p9", 0.6640625, 0.1640625, 0.8671875, 0.3593750);
189
190 PT("p21", 0.1328125, 0.6406250, 0.3359375, 0.8359375);
191 PT("p22", 0.1953125, 0.6875000, 0.3906250, 0.8906250);
192 PT("p23", 0.2656250, 0.7265625, 0.4531250, 0.9375000);
193 PT("p24", 0.3359375, 0.7500000, 0.5234375, 0.9687500);
194 PT("p25", 0.4062500, 0.7578125, 0.5937500, 0.9765625);
195 PT("p26", 0.4765625, 0.7500000, 0.6640625, 0.9687500);
196 PT("p27", 0.5468750, 0.7265625, 0.7343750, 0.9375000);
197 PT("p28", 0.6093750, 0.6875000, 0.8046875, 0.8906250);
198 PT("p29", 0.6640625, 0.6406250, 0.8671875, 0.8359375);
199
200 }
201 programs {
202 program {
203 name: "init";
204 signal: "show";
205 source: "";
206 after: "go_active_pre";
207 }
208 program {
209 name: "go_active_pre";
210 action: STATE_SET "default" 0.0;
211 target: "logo";
212 after: "go_active1";
213 after: "go_active2";
214 after: "go_active3";
215 after: "go_active4";
216 after: "go_active5";
217 after: "go_active6";
218 after: "go_active7";
219 after: "go_active8";
220 after: "go_active9";
221 after: "go_active21";
222 after: "go_active22";
223 after: "go_active23";
224 after: "go_active24";
225 after: "go_active25";
226 after: "go_active26";
227 after: "go_active27";
228 after: "go_active28";
229 after: "go_active29";
230 }
231#define PR(_name, _delay, _part) \
232 program { \
233 name: "go_active"_name; \
234 in: _delay 0.0; \
235 after: "go_activeb"_name; \
236 } \
237 program { \
238 name: "go_activeb"_name; \
239 action: STATE_SET "active" 0.0; \
240 target: _part; \
241 transition: LINEAR 0.5; \
242 after: "go_activec"_name; \
243 } \
244 program { \
245 name: "go_activec"_name; \
246 action: STATE_SET "default" 0.0; \
247 target: _part; \
248 transition: LINEAR 1.2; \
249 after: "go_activeb"_name; \
250 }
251 PR("1", 0.0, "p1");
252 PR("2", 0.2, "p2");
253 PR("3", 0.4, "p3");
254 PR("4", 0.6, "p4");
255 PR("5", 0.8, "p5");
256 PR("6", 1.0, "p6");
257 PR("7", 1.2, "p7");
258 PR("8", 1.4, "p8");
259 PR("9", 1.6, "p9");
260 PR("21", 1.6, "p21");
261 PR("22", 1.4, "p22");
262 PR("23", 1.2, "p23");
263 PR("24", 1.0, "p24");
264 PR("25", 0.8, "p25");
265 PR("26", 0.6, "p26");
266 PR("27", 0.4, "p27");
267 PR("28", 0.2, "p28");
268 PR("29", 0.0, "p29");
269 }
270}
271
272group {
273 name: "e/sys/halt";
274 parts {
275 part {
276 name: "base";
277 mouse_events: 0;
278 type: RECT;
279 description {
280 state: "default" 0.0;
281 rel1 {
282 relative: 0.0 0.0;
283 offset: 1 1;
284 }
285 rel2 {
286 relative: 1.0 1.0;
287 offset: -2 -2;
288 }
289 color: 221 221 221 255;
290 }
291 }
292 part {
293 name: "base2";
294 mouse_events: 0;
295 description {
296 state: "default" 0.0;
297 min: 200 138;
298 max: 200 138;
299 align: 1.0 1.0;
300 fixed: 1 1;
301 rel1 {
302 relative: 1.0 1.0;
303 offset: -1 -1;
304 }
305 rel2 {
306 relative: 1.0 1.0;
307 offset: -1 -1;
308 }
309 image {
310 normal: "e17_dialog_watermark.png";
311 }
312 }
313 }
314 part {
315 name: "base3";
316 mouse_events: 0;
317 description {
318 state: "default" 0.0;
319 rel1 {
320 relative: 0.0 0.0;
321 offset: 0 0;
322 }
323 rel2 {
324 relative: 1.0 1.0;
325 offset: -1 -1;
326 }
327 image {
328 normal: "e17_menu_bg_border.png";
329 border: 1 1 1 1;
330 middle: 0;
331 }
332 fill {
333 smooth: 0;
334 }
335 }
336 }
337 part {
338 name: "e.textblock.message";
339 type: TEXTBLOCK;
340 mouse_events: 0;
341 description {
342 state: "default" 0.0;
343 rel1 {
344 to_y: "logo";
345 relative: 0.0 1.0;
346 offset: 8 8;
347 }
348 rel2 {
349 offset: -9 -9;
350 }
351 text {
352 style: "sys_style";
353 min: 1 1;
354 }
355 }
356 }
357 part {
358 name: "logo";
359 mouse_events: 0;
360 description {
361 state: "default" 0.0;
362 aspect: 1.0 1.0;
363 aspect_preference: BOTH;
364 min: 128 128;
365 max: 128 128;
366 align: 0.5 0.0;
367 rel1 {
368 relative: 0.0 0.0;
369 offset: 8 8;
370 }
371 rel2 {
372 relative: 1.0 0.0;
373 offset: -9 8;
374 }
375 image {
376 normal: "e17_logo_small.png";
377 }
378 }
379 }
380#define PT(_name, _p1, _p2, _p3, _p4) \
381 part { \
382 name: _name; \
383 mouse_events: 0; \
384 description { \
385 state: "default" 0.0; \
386 visible: 0; \
387 rel1 { \
388 to: "logo"; \
389 relative: _p1 _p2; \
390 } \
391 rel2 { \
392 to: "logo"; \
393 relative: _p3 _p4; \
394 } \
395 image { \
396 normal: "e17_logo_small_"_name".png"; \
397 } \
398 color: 255 255 255 0; \
399 } \
400 description { \
401 state: "active" 0.0; \
402 inherit: "default" 0.0; \
403 rel1 { \
404 to: "logo"; \
405 relative: _p1 _p2; \
406 } \
407 rel2 { \
408 to: "logo"; \
409 relative: _p3 _p4; \
410 } \
411 visible: 1; \
412 color: 255 255 255 255; \
413 } \
414 }
415 PT("p1", 0.1328125, 0.1640625, 0.3359375, 0.3593750);
416 PT("p2", 0.1953125, 0.1093750, 0.3906250, 0.3125000);
417 PT("p3", 0.2656250, 0.0625000, 0.4531250, 0.2734375);
418 PT("p4", 0.3359375, 0.0312500, 0.5234375, 0.2500000);
419 PT("p5", 0.4062500, 0.0234375, 0.5937500, 0.2421875);
420 PT("p6", 0.4765625, 0.0312500, 0.6640625, 0.2500000);
421 PT("p7", 0.5468750, 0.0625000, 0.7343750, 0.2734375);
422 PT("p8", 0.6093750, 0.1093750, 0.8046875, 0.3125000);
423 PT("p9", 0.6640625, 0.1640625, 0.8671875, 0.3593750);
424
425 PT("p21", 0.1328125, 0.6406250, 0.3359375, 0.8359375);
426 PT("p22", 0.1953125, 0.6875000, 0.3906250, 0.8906250);
427 PT("p23", 0.2656250, 0.7265625, 0.4531250, 0.9375000);
428 PT("p24", 0.3359375, 0.7500000, 0.5234375, 0.9687500);
429 PT("p25", 0.4062500, 0.7578125, 0.5937500, 0.9765625);
430 PT("p26", 0.4765625, 0.7500000, 0.6640625, 0.9687500);
431 PT("p27", 0.5468750, 0.7265625, 0.7343750, 0.9375000);
432 PT("p28", 0.6093750, 0.6875000, 0.8046875, 0.8906250);
433 PT("p29", 0.6640625, 0.6406250, 0.8671875, 0.8359375);
434
435 }
436 programs {
437 program {
438 name: "init";
439 signal: "show";
440 source: "";
441 after: "go_active_pre";
442 }
443 program {
444 name: "go_active_pre";
445 action: STATE_SET "default" 0.0;
446 target: "logo";
447 after: "go_active1";
448 after: "go_active2";
449 after: "go_active3";
450 after: "go_active4";
451 after: "go_active5";
452 after: "go_active6";
453 after: "go_active7";
454 after: "go_active8";
455 after: "go_active9";
456 after: "go_active21";
457 after: "go_active22";
458 after: "go_active23";
459 after: "go_active24";
460 after: "go_active25";
461 after: "go_active26";
462 after: "go_active27";
463 after: "go_active28";
464 after: "go_active29";
465 }
466#define PR(_name, _delay, _part) \
467 program { \
468 name: "go_active"_name; \
469 in: _delay 0.0; \
470 after: "go_activeb"_name; \
471 } \
472 program { \
473 name: "go_activeb"_name; \
474 action: STATE_SET "active" 0.0; \
475 target: _part; \
476 transition: LINEAR 0.5; \
477 after: "go_activec"_name; \
478 } \
479 program { \
480 name: "go_activec"_name; \
481 action: STATE_SET "default" 0.0; \
482 target: _part; \
483 transition: LINEAR 1.2; \
484 after: "go_activeb"_name; \
485 }
486 PR("1", 0.0, "p1");
487 PR("2", 0.2, "p2");
488 PR("3", 0.4, "p3");
489 PR("4", 0.6, "p4");
490 PR("5", 0.8, "p5");
491 PR("6", 1.0, "p6");
492 PR("7", 1.2, "p7");
493 PR("8", 1.4, "p8");
494 PR("9", 1.6, "p9");
495 PR("21", 1.6, "p21");
496 PR("22", 1.4, "p22");
497 PR("23", 1.2, "p23");
498 PR("24", 1.0, "p24");
499 PR("25", 0.8, "p25");
500 PR("26", 0.6, "p26");
501 PR("27", 0.4, "p27");
502 PR("28", 0.2, "p28");
503 PR("29", 0.0, "p29");
504 }
505}
506
507group {
508 name: "e/sys/reboot";
509 parts {
510 part {
511 name: "base";
512 mouse_events: 0;
513 type: RECT;
514 description {
515 state: "default" 0.0;
516 rel1 {
517 relative: 0.0 0.0;
518 offset: 1 1;
519 }
520 rel2 {
521 relative: 1.0 1.0;
522 offset: -2 -2;
523 }
524 color: 221 221 221 255;
525 }
526 }
527 part {
528 name: "base2";
529 mouse_events: 0;
530 description {
531 state: "default" 0.0;
532 min: 200 138;
533 max: 200 138;
534 align: 1.0 1.0;
535 fixed: 1 1;
536 rel1 {
537 relative: 1.0 1.0;
538 offset: -1 -1;
539 }
540 rel2 {
541 relative: 1.0 1.0;
542 offset: -1 -1;
543 }
544 image {
545 normal: "e17_dialog_watermark.png";
546 }
547 }
548 }
549 part {
550 name: "base3";
551 mouse_events: 0;
552 description {
553 state: "default" 0.0;
554 rel1 {
555 relative: 0.0 0.0;
556 offset: 0 0;
557 }
558 rel2 {
559 relative: 1.0 1.0;
560 offset: -1 -1;
561 }
562 image {
563 normal: "e17_menu_bg_border.png";
564 border: 1 1 1 1;
565 middle: 0;
566 }
567 fill {
568 smooth: 0;
569 }
570 }
571 }
572 part {
573 name: "e.textblock.message";
574 type: TEXTBLOCK;
575 mouse_events: 0;
576 description {
577 state: "default" 0.0;
578 rel1 {
579 to_y: "logo";
580 relative: 0.0 1.0;
581 offset: 8 8;
582 }
583 rel2 {
584 offset: -9 -9;
585 }
586 text {
587 style: "sys_style";
588 min: 1 1;
589 }
590 }
591 }
592 part {
593 name: "logo";
594 mouse_events: 0;
595 description {
596 state: "default" 0.0;
597 aspect: 1.0 1.0;
598 aspect_preference: BOTH;
599 min: 128 128;
600 max: 128 128;
601 align: 0.5 0.0;
602 rel1 {
603 relative: 0.0 0.0;
604 offset: 8 8;
605 }
606 rel2 {
607 relative: 1.0 0.0;
608 offset: -9 8;
609 }
610 image {
611 normal: "e17_logo_small.png";
612 }
613 }
614 }
615#define PT(_name, _p1, _p2, _p3, _p4) \
616 part { \
617 name: _name; \
618 mouse_events: 0; \
619 description { \
620 state: "default" 0.0; \
621 visible: 0; \
622 rel1 { \
623 to: "logo"; \
624 relative: _p1 _p2; \
625 } \
626 rel2 { \
627 to: "logo"; \
628 relative: _p3 _p4; \
629 } \
630 image { \
631 normal: "e17_logo_small_"_name".png"; \
632 } \
633 color: 255 255 255 0; \
634 } \
635 description { \
636 state: "active" 0.0; \
637 inherit: "default" 0.0; \
638 rel1 { \
639 to: "logo"; \
640 relative: _p1 _p2; \
641 } \
642 rel2 { \
643 to: "logo"; \
644 relative: _p3 _p4; \
645 } \
646 visible: 1; \
647 color: 255 255 255 255; \
648 } \
649 }
650 PT("p1", 0.1328125, 0.1640625, 0.3359375, 0.3593750);
651 PT("p2", 0.1953125, 0.1093750, 0.3906250, 0.3125000);
652 PT("p3", 0.2656250, 0.0625000, 0.4531250, 0.2734375);
653 PT("p4", 0.3359375, 0.0312500, 0.5234375, 0.2500000);
654 PT("p5", 0.4062500, 0.0234375, 0.5937500, 0.2421875);
655 PT("p6", 0.4765625, 0.0312500, 0.6640625, 0.2500000);
656 PT("p7", 0.5468750, 0.0625000, 0.7343750, 0.2734375);
657 PT("p8", 0.6093750, 0.1093750, 0.8046875, 0.3125000);
658 PT("p9", 0.6640625, 0.1640625, 0.8671875, 0.3593750);
659
660 PT("p21", 0.1328125, 0.6406250, 0.3359375, 0.8359375);
661 PT("p22", 0.1953125, 0.6875000, 0.3906250, 0.8906250);
662 PT("p23", 0.2656250, 0.7265625, 0.4531250, 0.9375000);
663 PT("p24", 0.3359375, 0.7500000, 0.5234375, 0.9687500);
664 PT("p25", 0.4062500, 0.7578125, 0.5937500, 0.9765625);
665 PT("p26", 0.4765625, 0.7500000, 0.6640625, 0.9687500);
666 PT("p27", 0.5468750, 0.7265625, 0.7343750, 0.9375000);
667 PT("p28", 0.6093750, 0.6875000, 0.8046875, 0.8906250);
668 PT("p29", 0.6640625, 0.6406250, 0.8671875, 0.8359375);
669
670 }
671 programs {
672 program {
673 name: "init";
674 signal: "show";
675 source: "";
676 after: "go_active_pre";
677 }
678 program {
679 name: "go_active_pre";
680 action: STATE_SET "default" 0.0;
681 target: "logo";
682 after: "go_active1";
683 after: "go_active2";
684 after: "go_active3";
685 after: "go_active4";
686 after: "go_active5";
687 after: "go_active6";
688 after: "go_active7";
689 after: "go_active8";
690 after: "go_active9";
691 after: "go_active21";
692 after: "go_active22";
693 after: "go_active23";
694 after: "go_active24";
695 after: "go_active25";
696 after: "go_active26";
697 after: "go_active27";
698 after: "go_active28";
699 after: "go_active29";
700 }
701#define PR(_name, _delay, _part) \
702 program { \
703 name: "go_active"_name; \
704 in: _delay 0.0; \
705 after: "go_activeb"_name; \
706 } \
707 program { \
708 name: "go_activeb"_name; \
709 action: STATE_SET "active" 0.0; \
710 target: _part; \
711 transition: LINEAR 0.5; \
712 after: "go_activec"_name; \
713 } \
714 program { \
715 name: "go_activec"_name; \
716 action: STATE_SET "default" 0.0; \
717 target: _part; \
718 transition: LINEAR 1.2; \
719 after: "go_activeb"_name; \
720 }
721 PR("1", 0.0, "p1");
722 PR("2", 0.2, "p2");
723 PR("3", 0.4, "p3");
724 PR("4", 0.6, "p4");
725 PR("5", 0.8, "p5");
726 PR("6", 1.0, "p6");
727 PR("7", 1.2, "p7");
728 PR("8", 1.4, "p8");
729 PR("9", 1.6, "p9");
730 PR("21", 1.6, "p21");
731 PR("22", 1.4, "p22");
732 PR("23", 1.2, "p23");
733 PR("24", 1.0, "p24");
734 PR("25", 0.8, "p25");
735 PR("26", 0.6, "p26");
736 PR("27", 0.4, "p27");
737 PR("28", 0.2, "p28");
738 PR("29", 0.0, "p29");
739 }
740}
741
742group {
743 name: "e/sys/suspend";
744 parts {
745 part {
746 name: "base";
747 mouse_events: 0;
748 type: RECT;
749 description {
750 state: "default" 0.0;
751 rel1 {
752 relative: 0.0 0.0;
753 offset: 1 1;
754 }
755 rel2 {
756 relative: 1.0 1.0;
757 offset: -2 -2;
758 }
759 color: 221 221 221 255;
760 }
761 }
762 part {
763 name: "base2";
764 mouse_events: 0;
765 description {
766 state: "default" 0.0;
767 min: 200 138;
768 max: 200 138;
769 align: 1.0 1.0;
770 fixed: 1 1;
771 rel1 {
772 relative: 1.0 1.0;
773 offset: -1 -1;
774 }
775 rel2 {
776 relative: 1.0 1.0;
777 offset: -1 -1;
778 }
779 image {
780 normal: "e17_dialog_watermark.png";
781 }
782 }
783 }
784 part {
785 name: "base3";
786 mouse_events: 0;
787 description {
788 state: "default" 0.0;
789 rel1 {
790 relative: 0.0 0.0;
791 offset: 0 0;
792 }
793 rel2 {
794 relative: 1.0 1.0;
795 offset: -1 -1;
796 }
797 image {
798 normal: "e17_menu_bg_border.png";
799 border: 1 1 1 1;
800 middle: 0;
801 }
802 fill {
803 smooth: 0;
804 }
805 }
806 }
807 part {
808 name: "e.textblock.message";
809 type: TEXTBLOCK;
810 mouse_events: 0;
811 description {
812 state: "default" 0.0;
813 rel1 {
814 to_y: "logo";
815 relative: 0.0 1.0;
816 offset: 8 8;
817 }
818 rel2 {
819 offset: -9 -9;
820 }
821 text {
822 style: "sys_style";
823 min: 1 1;
824 }
825 }
826 }
827 part {
828 name: "logo";
829 mouse_events: 0;
830 description {
831 state: "default" 0.0;
832 aspect: 1.0 1.0;
833 aspect_preference: BOTH;
834 min: 128 128;
835 max: 128 128;
836 align: 0.5 0.0;
837 rel1 {
838 relative: 0.0 0.0;
839 offset: 8 8;
840 }
841 rel2 {
842 relative: 1.0 0.0;
843 offset: -9 8;
844 }
845 image {
846 normal: "e17_logo_small.png";
847 }
848 }
849 }
850#define PT(_name, _p1, _p2, _p3, _p4) \
851 part { \
852 name: _name; \
853 mouse_events: 0; \
854 description { \
855 state: "default" 0.0; \
856 visible: 0; \
857 rel1 { \
858 to: "logo"; \
859 relative: _p1 _p2; \
860 } \
861 rel2 { \
862 to: "logo"; \
863 relative: _p3 _p4; \
864 } \
865 image { \
866 normal: "e17_logo_small_"_name".png"; \
867 } \
868 color: 255 255 255 0; \
869 } \
870 description { \
871 state: "active" 0.0; \
872 inherit: "default" 0.0; \
873 rel1 { \
874 to: "logo"; \
875 relative: _p1 _p2; \
876 } \
877 rel2 { \
878 to: "logo"; \
879 relative: _p3 _p4; \
880 } \
881 visible: 1; \
882 color: 255 255 255 255; \
883 } \
884 }
885 PT("p1", 0.1328125, 0.1640625, 0.3359375, 0.3593750);
886 PT("p2", 0.1953125, 0.1093750, 0.3906250, 0.3125000);
887 PT("p3", 0.2656250, 0.0625000, 0.4531250, 0.2734375);
888 PT("p4", 0.3359375, 0.0312500, 0.5234375, 0.2500000);
889 PT("p5", 0.4062500, 0.0234375, 0.5937500, 0.2421875);
890 PT("p6", 0.4765625, 0.0312500, 0.6640625, 0.2500000);
891 PT("p7", 0.5468750, 0.0625000, 0.7343750, 0.2734375);
892 PT("p8", 0.6093750, 0.1093750, 0.8046875, 0.3125000);
893 PT("p9", 0.6640625, 0.1640625, 0.8671875, 0.3593750);
894
895 PT("p21", 0.1328125, 0.6406250, 0.3359375, 0.8359375);
896 PT("p22", 0.1953125, 0.6875000, 0.3906250, 0.8906250);
897 PT("p23", 0.2656250, 0.7265625, 0.4531250, 0.9375000);
898 PT("p24", 0.3359375, 0.7500000, 0.5234375, 0.9687500);
899 PT("p25", 0.4062500, 0.7578125, 0.5937500, 0.9765625);
900 PT("p26", 0.4765625, 0.7500000, 0.6640625, 0.9687500);
901 PT("p27", 0.5468750, 0.7265625, 0.7343750, 0.9375000);
902 PT("p28", 0.6093750, 0.6875000, 0.8046875, 0.8906250);
903 PT("p29", 0.6640625, 0.6406250, 0.8671875, 0.8359375);
904
905 }
906 programs {
907 program {
908 name: "init";
909 signal: "show";
910 source: "";
911 after: "go_active_pre";
912 }
913 program {
914 name: "go_active_pre";
915 action: STATE_SET "default" 0.0;
916 target: "logo";
917 after: "go_active1";
918 after: "go_active2";
919 after: "go_active3";
920 after: "go_active4";
921 after: "go_active5";
922 after: "go_active6";
923 after: "go_active7";
924 after: "go_active8";
925 after: "go_active9";
926 after: "go_active21";
927 after: "go_active22";
928 after: "go_active23";
929 after: "go_active24";
930 after: "go_active25";
931 after: "go_active26";
932 after: "go_active27";
933 after: "go_active28";
934 after: "go_active29";
935 }
936#define PR(_name, _delay, _part) \
937 program { \
938 name: "go_active"_name; \
939 in: _delay 0.0; \
940 after: "go_activeb"_name; \
941 } \
942 program { \
943 name: "go_activeb"_name; \
944 action: STATE_SET "active" 0.0; \
945 target: _part; \
946 transition: LINEAR 0.5; \
947 after: "go_activec"_name; \
948 } \
949 program { \
950 name: "go_activec"_name; \
951 action: STATE_SET "default" 0.0; \
952 target: _part; \
953 transition: LINEAR 1.2; \
954 after: "go_activeb"_name; \
955 }
956 PR("1", 0.0, "p1");
957 PR("2", 0.2, "p2");
958 PR("3", 0.4, "p3");
959 PR("4", 0.6, "p4");
960 PR("5", 0.8, "p5");
961 PR("6", 1.0, "p6");
962 PR("7", 1.2, "p7");
963 PR("8", 1.4, "p8");
964 PR("9", 1.6, "p9");
965 PR("21", 1.6, "p21");
966 PR("22", 1.4, "p22");
967 PR("23", 1.2, "p23");
968 PR("24", 1.0, "p24");
969 PR("25", 0.8, "p25");
970 PR("26", 0.6, "p26");
971 PR("27", 0.4, "p27");
972 PR("28", 0.2, "p28");
973 PR("29", 0.0, "p29");
974 }
975}
976
977group {
978 name: "e/sys/hibernate";
979 parts {
980 part {
981 name: "base";
982 mouse_events: 0;
983 type: RECT;
984 description {
985 state: "default" 0.0;
986 rel1 {
987 relative: 0.0 0.0;
988 offset: 1 1;
989 }
990 rel2 {
991 relative: 1.0 1.0;
992 offset: -2 -2;
993 }
994 color: 221 221 221 255;
995 }
996 }
997 part {
998 name: "base2";
999 mouse_events: 0;
1000 description {
1001 state: "default" 0.0;
1002 min: 200 138;
1003 max: 200 138;
1004 align: 1.0 1.0;
1005 fixed: 1 1;
1006 rel1 {
1007 relative: 1.0 1.0;
1008 offset: -1 -1;
1009 }
1010 rel2 {
1011 relative: 1.0 1.0;
1012 offset: -1 -1;
1013 }
1014 image {
1015 normal: "e17_dialog_watermark.png";
1016 }
1017 }
1018 }
1019 part {
1020 name: "base3";
1021 mouse_events: 0;
1022 description {
1023 state: "default" 0.0;
1024 rel1 {
1025 relative: 0.0 0.0;
1026 offset: 0 0;
1027 }
1028 rel2 {
1029 relative: 1.0 1.0;
1030 offset: -1 -1;
1031 }
1032 image {
1033 normal: "e17_menu_bg_border.png";
1034 border: 1 1 1 1;
1035 middle: 0;
1036 }
1037 fill {
1038 smooth: 0;
1039 }
1040 }
1041 }
1042 part {
1043 name: "e.textblock.message";
1044 type: TEXTBLOCK;
1045 mouse_events: 0;
1046 description {
1047 state: "default" 0.0;
1048 rel1 {
1049 to_y: "logo";
1050 relative: 0.0 1.0;
1051 offset: 8 8;
1052 }
1053 rel2 {
1054 offset: -9 -9;
1055 }
1056 text {
1057 style: "sys_style";
1058 min: 1 1;
1059 }
1060 }
1061 }
1062 part {
1063 name: "logo";
1064 mouse_events: 0;
1065 description {
1066 state: "default" 0.0;
1067 aspect: 1.0 1.0;
1068 aspect_preference: BOTH;
1069 min: 128 128;
1070 max: 128 128;
1071 align: 0.5 0.0;
1072 rel1 {
1073 relative: 0.0 0.0;
1074 offset: 8 8;
1075 }
1076 rel2 {
1077 relative: 1.0 0.0;
1078 offset: -9 8;
1079 }
1080 image {
1081 normal: "e17_logo_small.png";
1082 }
1083 }
1084 }
1085#define PT(_name, _p1, _p2, _p3, _p4) \
1086 part { \
1087 name: _name; \
1088 mouse_events: 0; \
1089 description { \
1090 state: "default" 0.0; \
1091 visible: 0; \
1092 rel1 { \
1093 to: "logo"; \
1094 relative: _p1 _p2; \
1095 } \
1096 rel2 { \
1097 to: "logo"; \
1098 relative: _p3 _p4; \
1099 } \
1100 image { \
1101 normal: "e17_logo_small_"_name".png"; \
1102 } \
1103 color: 255 255 255 0; \
1104 } \
1105 description { \
1106 state: "active" 0.0; \
1107 inherit: "default" 0.0; \
1108 rel1 { \
1109 to: "logo"; \
1110 relative: _p1 _p2; \
1111 } \
1112 rel2 { \
1113 to: "logo"; \
1114 relative: _p3 _p4; \
1115 } \
1116 visible: 1; \
1117 color: 255 255 255 255; \
1118 } \
1119 }
1120 PT("p1", 0.1328125, 0.1640625, 0.3359375, 0.3593750);
1121 PT("p2", 0.1953125, 0.1093750, 0.3906250, 0.3125000);
1122 PT("p3", 0.2656250, 0.0625000, 0.4531250, 0.2734375);
1123 PT("p4", 0.3359375, 0.0312500, 0.5234375, 0.2500000);
1124 PT("p5", 0.4062500, 0.0234375, 0.5937500, 0.2421875);
1125 PT("p6", 0.4765625, 0.0312500, 0.6640625, 0.2500000);
1126 PT("p7", 0.5468750, 0.0625000, 0.7343750, 0.2734375);
1127 PT("p8", 0.6093750, 0.1093750, 0.8046875, 0.3125000);
1128 PT("p9", 0.6640625, 0.1640625, 0.8671875, 0.3593750);
1129
1130 PT("p21", 0.1328125, 0.6406250, 0.3359375, 0.8359375);
1131 PT("p22", 0.1953125, 0.6875000, 0.3906250, 0.8906250);
1132 PT("p23", 0.2656250, 0.7265625, 0.4531250, 0.9375000);
1133 PT("p24", 0.3359375, 0.7500000, 0.5234375, 0.9687500);
1134 PT("p25", 0.4062500, 0.7578125, 0.5937500, 0.9765625);
1135 PT("p26", 0.4765625, 0.7500000, 0.6640625, 0.9687500);
1136 PT("p27", 0.5468750, 0.7265625, 0.7343750, 0.9375000);
1137 PT("p28", 0.6093750, 0.6875000, 0.8046875, 0.8906250);
1138 PT("p29", 0.6640625, 0.6406250, 0.8671875, 0.8359375);
1139
1140 }
1141 programs {
1142 program {
1143 name: "init";
1144 signal: "show";
1145 source: "";
1146 after: "go_active_pre";
1147 }
1148 program {
1149 name: "go_active_pre";
1150 action: STATE_SET "default" 0.0;
1151 target: "logo";
1152 after: "go_active1";
1153 after: "go_active2";
1154 after: "go_active3";
1155 after: "go_active4";
1156 after: "go_active5";
1157 after: "go_active6";
1158 after: "go_active7";
1159 after: "go_active8";
1160 after: "go_active9";
1161 after: "go_active21";
1162 after: "go_active22";
1163 after: "go_active23";
1164 after: "go_active24";
1165 after: "go_active25";
1166 after: "go_active26";
1167 after: "go_active27";
1168 after: "go_active28";
1169 after: "go_active29";
1170 }
1171#define PR(_name, _delay, _part) \
1172 program { \
1173 name: "go_active"_name; \
1174 in: _delay 0.0; \
1175 after: "go_activeb"_name; \
1176 } \
1177 program { \
1178 name: "go_activeb"_name; \
1179 action: STATE_SET "active" 0.0; \
1180 target: _part; \
1181 transition: LINEAR 0.5; \
1182 after: "go_activec"_name; \
1183 } \
1184 program { \
1185 name: "go_activec"_name; \
1186 action: STATE_SET "default" 0.0; \
1187 target: _part; \
1188 transition: LINEAR 1.2; \
1189 after: "go_activeb"_name; \
1190 }
1191 PR("1", 0.0, "p1");
1192 PR("2", 0.2, "p2");
1193 PR("3", 0.4, "p3");
1194 PR("4", 0.6, "p4");
1195 PR("5", 0.8, "p5");
1196 PR("6", 1.0, "p6");
1197 PR("7", 1.2, "p7");
1198 PR("8", 1.4, "p8");
1199 PR("9", 1.6, "p9");
1200 PR("21", 1.6, "p21");
1201 PR("22", 1.4, "p22");
1202 PR("23", 1.2, "p23");
1203 PR("24", 1.0, "p24");
1204 PR("25", 0.8, "p25");
1205 PR("26", 0.6, "p26");
1206 PR("27", 0.4, "p27");
1207 PR("28", 0.2, "p28");
1208 PR("29", 0.0, "p29");
1209 }
1210}
diff --git a/src/bin/Makefile.am b/src/bin/Makefile.am
index eb45291..7488101 100644
--- a/src/bin/Makefile.am
+++ b/src/bin/Makefile.am
@@ -171,6 +171,7 @@ e_int_config_wallpaper_gradient.h \
171e_color_dialog.h \ 171e_color_dialog.h \
172e_fdo_menu_to_order.h \ 172e_fdo_menu_to_order.h \
173e_sys.h \ 173e_sys.h \
174e_obj_dialog.h \
174e_int_config_transitions.h 175e_int_config_transitions.h
175 176
176enlightenment_src = \ 177enlightenment_src = \
@@ -317,6 +318,7 @@ e_color_dialog.c \
317e_fdo_menu_to_order.c \ 318e_fdo_menu_to_order.c \
318e_sys.c \ 319e_sys.c \
319e_int_config_transitions.c \ 320e_int_config_transitions.c \
321e_obj_dialog.c \
320$(ENLIGHTENMENTHEADERS) 322$(ENLIGHTENMENTHEADERS)
321 323
322enlightenment_SOURCES = \ 324enlightenment_SOURCES = \
diff --git a/src/bin/e_about.h b/src/bin/e_about.h
index f73404f..1fc76ce 100644
--- a/src/bin/e_about.h
+++ b/src/bin/e_about.h
@@ -9,7 +9,7 @@ typedef struct _E_About E_About;
9#ifndef E_ABOUT_H 9#ifndef E_ABOUT_H
10#define E_ABOUT_H 10#define E_ABOUT_H
11 11
12#define E_ABOUT_TYPE 0xE0b01013 12#define E_ABOUT_TYPE 0xE0b0101a
13 13
14struct _E_About 14struct _E_About
15{ 15{
diff --git a/src/bin/e_color_dialog.h b/src/bin/e_color_dialog.h
index 5616ccf..0311f0b 100644
--- a/src/bin/e_color_dialog.h
+++ b/src/bin/e_color_dialog.h
@@ -9,7 +9,7 @@ typedef struct _E_Color_Dialog E_Color_Dialog;
9#ifndef E_COLOR_DIALOG_H 9#ifndef E_COLOR_DIALOG_H
10#define E_COLOR_DIALOG_H 10#define E_COLOR_DIALOG_H
11 11
12#define E_COLOR_DIALOG_TYPE 0xE0b01026 12#define E_COLOR_DIALOG_TYPE 0xE0b0101c
13 13
14struct _E_Color_Dialog 14struct _E_Color_Dialog
15{ 15{
diff --git a/src/bin/e_entry_dialog.h b/src/bin/e_entry_dialog.h
index f6603d9..2224938 100644
--- a/src/bin/e_entry_dialog.h
+++ b/src/bin/e_entry_dialog.h
@@ -9,7 +9,7 @@ typedef struct _E_Entry_Dialog E_Entry_Dialog;
9#ifndef E_ENTRY_DIALOG_H 9#ifndef E_ENTRY_DIALOG_H
10#define E_ENTRY_DIALOG_H 10#define E_ENTRY_DIALOG_H
11 11
12#define E_ENTRY_DIALOG_TYPE 0xE0b01025 12#define E_ENTRY_DIALOG_TYPE 0xE0b0101d
13 13
14struct _E_Entry_Dialog 14struct _E_Entry_Dialog
15{ 15{
diff --git a/src/bin/e_file_dialog.h b/src/bin/e_file_dialog.h
index 855d4c6..4cd99f5 100644
--- a/src/bin/e_file_dialog.h
+++ b/src/bin/e_file_dialog.h
@@ -9,7 +9,7 @@ typedef struct _E_File_Dialog E_File_Dialog;
9#ifndef E_FILE_DIALOG_H 9#ifndef E_FILE_DIALOG_H
10#define E_FILE_DIALOG_H 10#define E_FILE_DIALOG_H
11 11
12#define E_FILE_DIALOG_TYPE 0xE0b01020 12#define E_FILE_DIALOG_TYPE 0xE0b0101f
13 13
14struct _E_File_Dialog 14struct _E_File_Dialog
15{ 15{
diff --git a/src/bin/e_gadcon.h b/src/bin/e_gadcon.h
index 7c4d8e1..51ed495 100644
--- a/src/bin/e_gadcon.h
+++ b/src/bin/e_gadcon.h
@@ -40,8 +40,8 @@ typedef struct _E_Gadcon_Client_Class E_Gadcon_Client_Class;
40#ifndef E_GADCON_H 40#ifndef E_GADCON_H
41#define E_GADCON_H 41#define E_GADCON_H
42 42
43#define E_GADCON_TYPE 0xE0b01022 43#define E_GADCON_TYPE 0xE0b01006
44#define E_GADCON_CLIENT_TYPE 0xE0b01023 44#define E_GADCON_CLIENT_TYPE 0xE0b01007
45 45
46struct _E_Gadcon 46struct _E_Gadcon
47{ 47{
diff --git a/src/bin/e_includes.h b/src/bin/e_includes.h
index d9a6075..3bfdaae 100644
--- a/src/bin/e_includes.h
+++ b/src/bin/e_includes.h
@@ -146,3 +146,4 @@
146#include "e_fdo_menu_to_order.h" 146#include "e_fdo_menu_to_order.h"
147#include "e_sys.h" 147#include "e_sys.h"
148#include "e_int_config_transitions.h" 148#include "e_int_config_transitions.h"
149#include "e_obj_dialog.h"
diff --git a/src/bin/e_obj_dialog.c b/src/bin/e_obj_dialog.c
new file mode 100644
index 0000000..7217208
--- /dev/null
+++ b/src/bin/e_obj_dialog.c
@@ -0,0 +1,129 @@
1/*
2 * vim:ts=8:sw=3:sts=8:noexpandtab:cino=>5n-3f0^-2{2
3 */
4#include "e.h"
5
6/* local subsystem functions */
7static void _e_obj_dialog_free(E_Obj_Dialog *od);
8static void _e_obj_dialog_cb_delete(E_Win *win);
9static void _e_obj_dialog_cb_close(void *data, Evas_Object *obj, const char *emission, const char *source);
10
11/* local subsystem globals */
12
13/* externally accessible functions */
14
15EAPI E_Obj_Dialog *
16e_obj_dialog_new(E_Container *con, char *title, char *class_name, char *class_class)
17{
18 E_Obj_Dialog *od;
19 E_Manager *man;
20 Evas_Object *o;
21
22 if (!con)
23 {
24 man = e_manager_current_get();
25 if (!man) return NULL;
26 con = e_container_current_get(man);
27 if (!con) con = e_container_number_get(man, 0);
28 if (!con) return NULL;
29 }
30 od = E_OBJECT_ALLOC(E_Obj_Dialog, E_OBJ_DIALOG_TYPE, _e_obj_dialog_free);
31 if (!od) return NULL;
32 od->win = e_win_new(con);
33 if (!od->win)
34 {
35 free(od);
36 return NULL;
37 }
38 e_win_delete_callback_set(od->win, _e_obj_dialog_cb_delete);
39 od->win->data = od;
40 e_win_dialog_set(od->win, 1);
41 e_win_name_class_set(od->win, class_name, class_class);
42 e_win_title_set(od->win, title);
43
44 o = edje_object_add(e_win_evas_get(od->win));
45 od->bg_object = o;
46
47 e_win_centered_set(od->win, 1);
48
49 return od;
50}
51
52EAPI void
53e_obj_dialog_icon_set(E_Obj_Dialog *od, char *icon)
54{
55 E_OBJECT_CHECK(od);
56 E_OBJECT_TYPE_CHECK(od, E_OBJ_DIALOG_TYPE);
57 if (od->win->border->internal_icon)
58 {
59 evas_stringshare_del(od->win->border->internal_icon);
60 od->win->border->internal_icon = NULL;
61 }
62 if (icon)
63 od->win->border->internal_icon = evas_stringshare_add(icon);
64}
65
66EAPI void
67e_obj_dialog_show(E_Obj_Dialog *od)
68{
69 Evas_Coord mw, mh, w, h;
70
71 E_OBJECT_CHECK(od);
72 E_OBJECT_TYPE_CHECK(od, E_OBJ_DIALOG_TYPE);
73
74 edje_object_size_min_calc(od->bg_object, &mw, &mh);
75 evas_object_resize(od->bg_object, mw, mh);
76 e_win_resize(od->win, mw, mh);
77 e_win_size_min_set(od->win, mw, mh);
78 e_win_size_max_set(od->win, mw, mh);
79
80 e_win_show(od->win);
81}
82
83EAPI void
84e_obj_dialog_obj_part_text_set(E_Obj_Dialog *od, char *part, char *text)
85{
86 E_OBJECT_CHECK(od);
87 E_OBJECT_TYPE_CHECK(od, E_OBJ_DIALOG_TYPE);
88 edje_object_part_text_set(od->bg_object, part, text);
89}
90
91EAPI void
92e_obj_dialog_obj_theme_set(E_Obj_Dialog *od, char *theme_cat, char *theme_obj)
93{
94 E_OBJECT_CHECK(od);
95 E_OBJECT_TYPE_CHECK(od, E_OBJ_DIALOG_TYPE);
96
97 e_theme_edje_object_set(od->bg_object, theme_cat, theme_obj);
98 evas_object_move(od->bg_object, 0, 0);
99 evas_object_show(od->bg_object);
100 edje_object_signal_callback_add(od->bg_object, "e,action,close", "",
101 _e_obj_dialog_cb_close, od);
102}
103
104/* local subsystem functions */
105static void
106_e_obj_dialog_free(E_Obj_Dialog *od)
107{
108 if (od->bg_object) evas_object_del(od->bg_object);
109 e_object_del(E_OBJECT(od->win));
110 free(od);
111}
112
113static void
114_e_obj_dialog_cb_delete(E_Win *win)
115{
116 E_Obj_Dialog *od;
117
118 od = win->data;
119 e_object_del(E_OBJECT(od));
120}
121
122static void
123_e_obj_dialog_cb_close(void *data, Evas_Object *obj, const char *emission, const char *source)
124{
125 E_Obj_Dialog *od;
126
127 od = data;
128 e_object_del(E_OBJECT(od));
129}
diff --git a/src/bin/e_obj_dialog.h b/src/bin/e_obj_dialog.h
new file mode 100644
index 0000000..9f6728f
--- /dev/null
+++ b/src/bin/e_obj_dialog.h
@@ -0,0 +1,30 @@
1/*
2 * vim:ts=8:sw=3:sts=8:noexpandtab:cino=>5n-3f0^-2{2
3 */
4#ifdef E_TYPEDEFS
5
6typedef struct _E_Obj_Dialog E_Obj_Dialog;
7
8#else
9#ifndef E_OBJ_DIALOG_H
10#define E_OBJ_DIALOG_H
11
12#define E_OBJ_DIALOG_TYPE 0xE0b0101b
13
14struct _E_Obj_Dialog
15{
16 E_Object e_obj_inherit;
17
18 E_Win *win;
19 Evas_Object *bg_object;
20 void *data;
21};
22
23EAPI E_Obj_Dialog *e_obj_dialog_new(E_Container *con, char *title, char *class_name, char *class_class);
24EAPI void e_obj_dialog_icon_set(E_Obj_Dialog *od, char *icon);
25EAPI void e_obj_dialog_show(E_Obj_Dialog *od);
26EAPI void e_obj_dialog_obj_part_text_set(E_Obj_Dialog *od, char *part, char *text);
27EAPI void e_obj_dialog_obj_theme_set(E_Obj_Dialog *od, char *theme_cat, char *theme_obj);
28
29#endif
30#endif
diff --git a/src/bin/e_shelf.h b/src/bin/e_shelf.h
index 0915635..66cbdea 100644
--- a/src/bin/e_shelf.h
+++ b/src/bin/e_shelf.h
@@ -9,7 +9,7 @@ typedef struct _E_Shelf E_Shelf;
9#ifndef E_SHELF_H 9#ifndef E_SHELF_H
10#define E_SHELF_H 10#define E_SHELF_H
11 11
12#define E_SHELF_TYPE 0xE0b01024 12#define E_SHELF_TYPE 0xE0b0101e
13 13
14struct _E_Shelf 14struct _E_Shelf
15{ 15{
diff --git a/src/bin/e_sys.c b/src/bin/e_sys.c
index 427ec12..3ff0027 100644
--- a/src/bin/e_sys.c
+++ b/src/bin/e_sys.c
@@ -30,6 +30,7 @@ static E_Sys_Action _e_sys_action_after = E_SYS_NONE;
30static Ecore_Exe *_e_sys_exe = NULL; 30static Ecore_Exe *_e_sys_exe = NULL;
31static double _e_sys_logout_begin_time = 0.0; 31static double _e_sys_logout_begin_time = 0.0;
32static Ecore_Timer *_e_sys_logout_timer = NULL; 32static Ecore_Timer *_e_sys_logout_timer = NULL;
33static E_Obj_Dialog *_e_sys_dialog = NULL;
33 34
34/* externally accessible functions */ 35/* externally accessible functions */
35EAPI int 36EAPI int
@@ -134,11 +135,18 @@ _e_sys_cb_exit(void *data, int type, void *event)
134 if ((_e_sys_exe) && (ev->exe == _e_sys_exe)) 135 if ((_e_sys_exe) && (ev->exe == _e_sys_exe))
135 { 136 {
136 if (ev->exit_code != 0) _e_sys_action_failed(); 137 if (ev->exit_code != 0) _e_sys_action_failed();
138 if (((_e_sys_action_current != E_SYS_HALT) &&
139 (_e_sys_action_current != E_SYS_REBOOT)) ||
140 (ev->exit_code != 0))
141 {
142 if (_e_sys_dialog)
143 {
144 e_object_del(E_OBJECT(_e_sys_dialog));
145 _e_sys_dialog = NULL;
146 }
147 }
137 _e_sys_action_current = E_SYS_NONE; 148 _e_sys_action_current = E_SYS_NONE;
138 _e_sys_exe = NULL; 149 _e_sys_exe = NULL;
139 /* if we have a suspend or hibernate status popup/dialog - close it
140 * here as we have finished suspend/hibernate (and probably just
141 * came back out of suspend/hibernate */
142 return 1; 150 return 1;
143 } 151 }
144 if ((_e_sys_halt_check_exe) && (ev->exe == _e_sys_halt_check_exe)) 152 if ((_e_sys_halt_check_exe) && (ev->exe == _e_sys_halt_check_exe))
@@ -212,6 +220,11 @@ _e_sys_cb_logout_abort(void *data, E_Dialog *dia)
212 e_object_del(E_OBJECT(dia)); 220 e_object_del(E_OBJECT(dia));
213 _e_sys_action_current = E_SYS_NONE; 221 _e_sys_action_current = E_SYS_NONE;
214 _e_sys_action_after = E_SYS_NONE; 222 _e_sys_action_after = E_SYS_NONE;
223 if (_e_sys_dialog)
224 {
225 e_object_del(E_OBJECT(_e_sys_dialog));
226 _e_sys_dialog = NULL;
227 }
215} 228}
216 229
217static int 230static int
@@ -255,7 +268,7 @@ _e_sys_cb_logout_timer(void *data)
255 e_dialog_button_focus_num(dia, 1); 268 e_dialog_button_focus_num(dia, 1);
256 e_win_centered_set(dia->win, 1); 269 e_win_centered_set(dia->win, 1);
257 e_dialog_show(dia); 270 e_dialog_show(dia);
258 _e_sys_logout_begin_time = ecore_time_get() + (60 * 60 * 24 * 365); 271 _e_sys_logout_begin_time = 0.0;
259 } 272 }
260 _e_sys_logout_timer = NULL; 273 _e_sys_logout_timer = NULL;
261 return 0; 274 return 0;
@@ -271,8 +284,13 @@ _e_sys_cb_logout_timer(void *data)
271static void 284static void
272_e_sys_logout_after(void) 285_e_sys_logout_after(void)
273{ 286{
287 if (_e_sys_dialog)
288 {
289 e_object_del(E_OBJECT(_e_sys_dialog));
290 _e_sys_dialog = NULL;
291 }
292 _e_sys_action_current = _e_sys_action_after;
274 _e_sys_action_do(_e_sys_action_after, NULL); 293 _e_sys_action_do(_e_sys_action_after, NULL);
275 _e_sys_action_current = E_SYS_NONE;
276 _e_sys_action_after = E_SYS_NONE; 294 _e_sys_action_after = E_SYS_NONE;
277} 295}
278 296
@@ -280,14 +298,20 @@ static void
280_e_sys_logout_begin(E_Sys_Action a_after) 298_e_sys_logout_begin(E_Sys_Action a_after)
281{ 299{
282 Evas_List *l; 300 Evas_List *l;
301 E_Obj_Dialog *od;
283 302
284 /* start logout - at end do the a_after action */ 303 /* start logout - at end do the a_after action */
304 od = e_obj_dialog_new(e_container_current_get(e_manager_current_get()),
305 _("Logout in progress"), "E", "_sys_logout");
306 e_obj_dialog_obj_theme_set(od, "base/theme/sys", "e/sys/logout");
307 e_obj_dialog_obj_part_text_set(od, "e.textblock.message",
308 _("Logout is currently in progress.<br>"
309 "<hilight>Please wait.</hilight>"));
310 e_obj_dialog_show(od);
311 e_obj_dialog_icon_set(od, "enlightenment/logout");
312 if (_e_sys_dialog) e_object_del(E_OBJECT(_e_sys_dialog));
313 _e_sys_dialog = od;
285 _e_sys_action_after = a_after; 314 _e_sys_action_after = a_after;
286 /* FIXME: go through to every window and if it wants delete req - ask
287 * it to delete, otherwise just close it. set handler for window
288 * deletes, and once all windows are deleted - exit, OR if a timer
289 * expires - pop up dialog saying something is not responding
290 */
291 for (l = e_border_client_list(); l; l = l->next) 315 for (l = e_border_client_list(); l; l = l->next)
292 { 316 {
293 E_Border *bd; 317 E_Border *bd;
@@ -410,6 +434,7 @@ static int
410_e_sys_action_do(E_Sys_Action a, char *param) 434_e_sys_action_do(E_Sys_Action a, char *param)
411{ 435{
412 char buf[4096]; 436 char buf[4096];
437 E_Obj_Dialog *od;
413 438
414 switch (a) 439 switch (a)
415 { 440 {
@@ -439,6 +464,16 @@ _e_sys_action_do(E_Sys_Action a, char *param)
439 else 464 else
440 { 465 {
441 _e_sys_exe = ecore_exe_run(buf, NULL); 466 _e_sys_exe = ecore_exe_run(buf, NULL);
467 od = e_obj_dialog_new(e_container_current_get(e_manager_current_get()),
468 _("Shutting down"), "E", "_sys_halt");
469 e_obj_dialog_obj_theme_set(od, "base/theme/sys", "e/sys/halt");
470 e_obj_dialog_obj_part_text_set(od, "e.textblock.message",
471 _("Shutting down your Computer.<br>"
472 "<hilight>Please wait.</hilight>"));
473 e_obj_dialog_show(od);
474 e_obj_dialog_icon_set(od, "enlightenment/logout");
475 if (_e_sys_dialog) e_object_del(E_OBJECT(_e_sys_dialog));
476 _e_sys_dialog = od;
442 /* FIXME: display halt status */ 477 /* FIXME: display halt status */
443 } 478 }
444 break; 479 break;
@@ -455,6 +490,16 @@ _e_sys_action_do(E_Sys_Action a, char *param)
455 else 490 else
456 { 491 {
457 _e_sys_exe = ecore_exe_run(buf, NULL); 492 _e_sys_exe = ecore_exe_run(buf, NULL);
493 od = e_obj_dialog_new(e_container_current_get(e_manager_current_get()),
494 _("Rebooting"), "E", "_sys_reboot");
495 e_obj_dialog_obj_theme_set(od, "base/theme/sys", "e/sys/reboot");
496 e_obj_dialog_obj_part_text_set(od, "e.textblock.message",
497 _("Rebooting your Computer.<br>"
498 "<hilight>Please wait.</hilight>"));
499 e_obj_dialog_show(od);
500 e_obj_dialog_icon_set(od, "enlightenment/logout");
501 if (_e_sys_dialog) e_object_del(E_OBJECT(_e_sys_dialog));
502 _e_sys_dialog = od;
458 /* FIXME: display reboot status */ 503 /* FIXME: display reboot status */
459 } 504 }
460 break; 505 break;
@@ -470,6 +515,16 @@ _e_sys_action_do(E_Sys_Action a, char *param)
470 else 515 else
471 { 516 {
472 _e_sys_exe = ecore_exe_run(buf, NULL); 517 _e_sys_exe = ecore_exe_run(buf, NULL);
518 od = e_obj_dialog_new(e_container_current_get(e_manager_current_get()),
519 _("Suspending"), "E", "_sys_suspend");
520 e_obj_dialog_obj_theme_set(od, "base/theme/sys", "e/sys/suspend");
521 e_obj_dialog_obj_part_text_set(od, "e.textblock.message",
522 _("Suspending your Computer.<br>"
523 "<hilight>Please wait.</hilight>"));
524 e_obj_dialog_show(od);
525 e_obj_dialog_icon_set(od, "enlightenment/logout");
526 if (_e_sys_dialog) e_object_del(E_OBJECT(_e_sys_dialog));
527 _e_sys_dialog = od;
473 /* FIXME: display suspend status */ 528 /* FIXME: display suspend status */
474 } 529 }
475 break; 530 break;
@@ -485,6 +540,16 @@ _e_sys_action_do(E_Sys_Action a, char *param)
485 else 540 else
486 { 541 {
487 _e_sys_exe = ecore_exe_run(buf, NULL); 542 _e_sys_exe = ecore_exe_run(buf, NULL);
543 od = e_obj_dialog_new(e_container_current_get(e_manager_current_get()),
544 _("Hibernating"), "E", "_sys_hibernate");
545 e_obj_dialog_obj_theme_set(od, "base/theme/sys", "e/sys/hibernate");
546 e_obj_dialog_obj_part_text_set(od, "e.textblock.message",
547 _("Hibernating your Computer.<br>"
548 "<hilight>Please wait.</hilight>"));
549 e_obj_dialog_show(od);
550 e_obj_dialog_icon_set(od, "enlightenment/logout");
551 if (_e_sys_dialog) e_object_del(E_OBJECT(_e_sys_dialog));
552 _e_sys_dialog = od;
488 /* FIXME: display hibernate status */ 553 /* FIXME: display hibernate status */
489 } 554 }
490 break; 555 break;