Item : intial version
[apps/native/sample/adventure.git] / res / edje / item.edc
old mode 100644 (file)
new mode 100755 (executable)
index 660bbb5..d8e8641
+#define ITEM_TYPING_WIDTH 442
+#define ITEM_TYPING_HEIGHT 30
 
-styles {
-       style {
-               /* Font size is changed from 24 to 20 because of resolution issues. */
-               name: "text_style";
-               base: "font=Tizen:style=Regular font_size=20 color=#ffffff align=center style=shadow shadow_color=#000000bf wrap=mixed ellipsis=-1";
-               tag:  "br" "\n";
-               tag:  "hilight" "+ font_weight=Bold";
-               tag:  "b" "+ font_weight=Bold";
-               tag:  "tab" "\t";
-       }
+#define ITEM_SELECTING_WIDTH 480
+#define ITEM_SELECTING_HEIGHT 75
+
+#define ITEM_RESULT_WIDTH ITEM_SELECTING_WIDTH
+#define ITEM_RESULT_HEIGHT ITEM_SELECTING_HEIGHT
+
+images {
+       image: "my_status_small.png" COMP;
+       image: "other_location_blue_small.png" COMP;
+       image: "other_location_mint_small.png" COMP;
+       image: "delete_button.png" COMP;
 }
 
 collections {
-       base_scale: 1.7;
        group {
-               name: "item";
+               name: "item_typing";
                parts {
                        part {
                                name: "bg";
-                               type: SWALLOW;
+                               type: RECT;
+                               description {
+                                       rel1 { relative: 0.0 0.0; }
+                                       rel2 { relative: 1.0 1.0; }
+                                       min: ITEM_TYPING_WIDTH ITEM_TYPING_HEIGHT;
+                                       color: 247 208 143 255;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "city";
+                               type: TEXT;
+                               mouse_events: 0;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 0.0; to: "city_event"; }
+                                       rel2 { relative: 1.0 1.0; to: "city_event"; }
+                                       color: 255 255 255 255;
+                                       text {
+                                               text: "Hong kong";
+                                               font: "Tizen:style=LIGHT";
+                                               text_class: "tizen";
+                                               min: 0 1;
+                                               size: 20;
+                                               align: 0.0 0.5;
+                                       }
+                                       align: 0.0 1.0;
+                                       visible: 1;
+                               }
+                               description {
+                                       state: "press" 0.0;
+                                       inherit: "default" 0.0;
+                                       color: 255 255 255 100;
+                               }
+                       }
+                       part {
+                               name: "city_event";
+                               type: RECT;
                                mouse_events: 1;
+                               scale: 1;
                                description {
                                        state: "default" 0.0;
+                                       rel1 { relative: 73/ITEM_TYPING_WIDTH 0.0; to: "bg"; }
+                                       rel2 { relative: 400/ITEM_TYPING_WIDTH 1.0; to: "bg"; }
+                                       align: 0.5 0.5;
+                                       min: ITEM_SELECTING_HEIGHT ITEM_SELECTING_HEIGHT;
+                                       fixed: 1 1;
+                                       color: 0 0 0 0;
+                                       visible: 1;
+                               }
+                       }
+               } //parts
+               programs {
+                       program {
+                               signal: "mouse,down,1";
+                               source: "city_event";
+                               action: SIGNAL_EMIT "delete,down" "entry";
+                               after: "delete,down,after";
+                       }   
+                       program {
+                               name: "delete,down,after";
+                               action: STATE_SET "press" 0.0;
+                               target: "city";
+                       }
+                       program {
+                               signal: "mouse,up,1";
+                               source: "city_event";
+                               action: SIGNAL_EMIT "delete,up" "entry";
+                               after: "delete,up,after";
+                       }
+                       program {
+                               name: "delete,up,after";
+                               action: STATE_SET "default" 0.0;
+                               target: "city";
+                       }
+               }
+       }
+
+       group {
+               name: "item_selecting";
+               parts {
+                       part {
+                               name: "bg";
+                               type: RECT;
+                               description {
                                        rel1 { relative: 0.0 0.0; }
                                        rel2 { relative: 1.0 1.0; }
+                                       min: ITEM_SELECTING_WIDTH ITEM_SELECTING_HEIGHT;
+                                       color: 255 255 255 255;
+                                       visible: 1;
                                }
                        }
                        part {
-                               name: "icon";
-                               type: SWALLOW;
-                               mouse_events: 1;
+                               name: "mark";
+                               type: IMAGE;
                                scale: 1;
                                description {
                                        state: "default" 0.0;
-                                       rel1 { relative: 0.1 0.1; to: "bg"; }
-                                       rel2 { relative: 0.9 0.66; to: "bg"; }
+                                       rel1 { relative: 38/ITEM_SELECTING_WIDTH 0.5; to: "bg"; }
+                                       rel2 { relative: 38/ITEM_SELECTING_WIDTH 0.5; to: "bg"; }
+                                       align: 0.5 0.5;
+                                       min: 14 12;
+                                       fixed: 1 1;
+                                       image {
+                                               normal: "my_status_small.png";
+                                       }
+                                       visible: 1;
+                               }
+                               description {
+                                       state: "1" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 14 14;
+                                       image {
+                                               normal: "other_location_blue_small.png";
+                                       }
+                               }
+                               description {
+                                       state: "2" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 14 14;
+                                       image {
+                                               normal: "other_location_mint_small.png";
+                                       }
+                               }
+                               description {
+                                       state: "3" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 14 14;
+                                       image {
+                                               normal: "other_location_blue_small.png";
+                                       }
+                               }
+                               description {
+                                       state: "4" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 14 14;
+                                       image {
+                                               normal: "other_location_mint_small.png";
+                                       }
+                               }
+                       }
+                       part {
+                               name: "city";
+                               type: TEXT;
+                               mouse_events: 0;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 73/ITEM_SELECTING_WIDTH 0.45; to: "bg"; }
+                                       rel2 { relative: 400/ITEM_SELECTING_WIDTH 0.45; to: "bg"; }
+                                       color: 197 191 181 255;
+                                       text {
+                                               text: "Seoul, Korea";
+                                               font: "Tizen:style=LIGHT";
+                                               text_class: "tizen";
+                                               min: 0 1;
+                                               size: 20;
+                                               align: 0.0 1.0;
+                                       }
+                                       align: 0.0 1.0;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "gmt";
+                               type: TEXT;
+                               mouse_events: 0;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 73/ITEM_SELECTING_WIDTH 0.55; to: "bg"; }
+                                       rel2 { relative: 400/ITEM_SELECTING_WIDTH 0.55; to: "bg"; }
+                                       color: 221 218 213 255;
+                                       text {
+                                               text: "GMT + 8";
+                                               font: "Tizen:style=LIGHT";
+                                               text_class: "tizen";
+                                               min: 0 1;
+                                               size: 20;
+                                               align: 0.0 1.0;
+                                       }
+                                       align: 0.0 0.0;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "delete";
+                               type: IMAGE;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.5 0.5; to: "delete_event"; }
+                                       rel2 { relative: 0.5 0.5; to: "delete_event"; }
+                                       align: 0.5 0.5;
+                                       min: 34 34;
+                                       fixed: 1 1;
+                                       image {
+                                               normal: "delete_button.png";
+                                       }
                                        color: 255 255 255 255;
                                        visible: 1;
                                }
                                description {
-                                       state: "pressed" 0.0;
+                                       state: "press" 0.0;
                                        inherit: "default" 0.0;
-                                       color: 100 100 100 255;
+                                       color: 255 255 255 100;
                                }
                        }
                        part {
-                               name: "name";
-                               type: TEXTBLOCK;
+                               name: "delete_event";
+                               type: RECT;
                                mouse_events: 1;
                                scale: 1;
                                description {
                                        state: "default" 0.0;
-                                       rel1 { relative: 0.0 0.7; to: "bg"; }
-                                       rel2 { relative: 1.0 1.0; to: "bg"; }
-                                       align: 0.5 0.0;
-                                       color: 0 0 0 100;
+                                       rel1 { relative: 444/ITEM_SELECTING_WIDTH 0.5; to: "bg"; }
+                                       rel2 { relative: 444/ITEM_SELECTING_WIDTH 0.5; to: "bg"; }
+                                       align: 0.5 0.5;
+                                       min: ITEM_SELECTING_HEIGHT ITEM_SELECTING_HEIGHT;
+                                       fixed: 1 1;
+                                       color: 0 0 0 0;
+                                       visible: 1;
+                               }
+                       }
+               } //parts
+               programs {
+                       program {
+                               signal: "mouse,down,1";
+                               source: "delete_event";
+                               action: SIGNAL_EMIT "delete,down" "entry";
+                               after: "delete,down,after";
+                       }   
+                       program {
+                               name: "delete,down,after";
+                               action: STATE_SET "press" 0.0;
+                               target: "delete";
+                       }
+                       program {
+                               signal: "mouse,up,1";
+                               source: "delete_event";
+                               action: SIGNAL_EMIT "delete,up" "entry";
+                               after: "delete,up,after";
+                       }
+                       program {
+                               name: "delete,up,after";
+                               action: STATE_SET "default" 0.0;
+                               target: "delete";
+                       }
+               }
+       }
+
+       group {
+               name: "item_result";
+               parts {
+                       part {
+                               name: "bg";
+                               type: RECT;
+                               description {
+                                       rel1 { relative: 0.0 0.0; }
+                                       rel2 { relative: 1.0 1.0; }
+                                       min: ITEM_RESULT_WIDTH ITEM_RESULT_HEIGHT;
+                                       color: 255 255 255 255;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "mark";
+                               type: IMAGE;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 38/ITEM_RESULT_WIDTH 0.5; to: "bg"; }
+                                       rel2 { relative: 38/ITEM_RESULT_WIDTH 0.5; to: "bg"; }
+                                       align: 0.5 0.5;
+                                       min: 14 12;
+                                       fixed: 1 1;
+                                       image {
+                                               normal: "my_status_small.png";
+                                       }
+                                       visible: 1;
+                               }
+                               description {
+                                       state: "1" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 14 14;
+                                       image {
+                                               normal: "other_location_blue_small.png";
+                                       }
+                               }
+                               description {
+                                       state: "2" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 14 14;
+                                       image {
+                                               normal: "other_location_mint_small.png";
+                                       }
+                               }
+                               description {
+                                       state: "3" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 14 14;
+                                       image {
+                                               normal: "other_location_blue_small.png";
+                                       }
+                               }
+                               description {
+                                       state: "4" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 14 14;
+                                       image {
+                                               normal: "other_location_mint_small.png";
+                                       }
+                               }
+                       }
+                       part {
+                               name: "city";
+                               type: TEXT;
+                               mouse_events: 0;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 73/ITEM_RESULT_WIDTH 0.45; to: "bg"; }
+                                       rel2 { relative: 400/ITEM_RESULT_WIDTH 0.45; to: "bg"; }
+                                       color: 197 191 181 255;
                                        text {
-                                               style: "text_style";
-                                               align: 0.5 0.0;
+                                               text: "Seoul, Korea";
+                                               font: "Tizen:style=LIGHT";
+                                               text_class: "tizen";
+                                               min: 0 1;
+                                               size: 20;
+                                               align: 0.0 1.0;
                                        }
+                                       align: 0.0 1.0;
                                        visible: 1;
                                }
                        }
                        part {
-                               name: "button";
-                               type: SWALLOW;
+                               name: "gmt";
+                               type: TEXT;
+                               mouse_events: 0;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 73/ITEM_RESULT_WIDTH 0.55; to: "bg"; }
+                                       rel2 { relative: 400/ITEM_RESULT_WIDTH 0.55; to: "bg"; }
+                                       color: 221 218 213 255;
+                                       text {
+                                               text: "GMT + 8";
+                                               font: "Tizen:style=LIGHT";
+                                               text_class: "tizen";
+                                               min: 0 1;
+                                               size: 20;
+                                               align: 0.0 1.0;
+                                       }
+                                       align: 0.0 0.0;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "delete";
+                               type: IMAGE;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.5 0.5; to: "delete_event"; }
+                                       rel2 { relative: 0.5 0.5; to: "delete_event"; }
+                                       align: 0.5 0.5;
+                                       min: 34 34;
+                                       fixed: 1 1;
+                                       image {
+                                               normal: "delete_button.png";
+                                       }
+                                       color: 255 255 255 255;
+                                       visible: 1;
+                               }
+                               description {
+                                       state: "press" 0.0;
+                                       inherit: "default" 0.0;
+                                       color: 255 255 255 100;
+                               }
+                       }
+                       part {
+                               name: "delete_event";
+                               type: RECT;
                                mouse_events: 1;
+                               scale: 1;
                                description {
                                        state: "default" 0.0;
-                                       rel1 { relative: 0.0 0.0; to: "bg"; }
-                                       rel2 { relative: 1.0 1.0; to: "bg"; }
+                                       rel1 { relative: 444/ITEM_RESULT_WIDTH 0.5; to: "bg"; }
+                                       rel2 { relative: 444/ITEM_RESULT_WIDTH 0.5; to: "bg"; }
+                                       align: 0.5 0.5;
+                                       min: ITEM_RESULT_HEIGHT ITEM_RESULT_HEIGHT;
+                                       fixed: 1 1;
+                                       color: 0 0 0 0;
                                        visible: 1;
                                }
                        }
                } //parts
+               programs {
+                       program {
+                               signal: "mouse,down,1";
+                               source: "delete_event";
+                               action: SIGNAL_EMIT "delete,down" "entry";
+                               after: "delete,down,after";
+                       }   
+                       program {
+                               name: "delete,down,after";
+                               action: STATE_SET "press" 0.0;
+                               target: "delete";
+                       }
+                       program {
+                               signal: "mouse,up,1";
+                               source: "delete_event";
+                               action: SIGNAL_EMIT "delete,up" "entry";
+                               after: "delete,up,after";
+                       }
+                       program {
+                               name: "delete,up,after";
+                               action: STATE_SET "default" 0.0;
+                               target: "delete";
+                       }
+               }
        }
 } //collections