[Telegram] Add the pressed effect of button in message view 98/52098/2
authormoon87.park <moon87.park@samsung.com>
Thu, 19 Nov 2015 05:29:30 +0000 (14:29 +0900)
committermoon87.park <moon87.park@samsung.com>
Thu, 19 Nov 2015 05:30:25 +0000 (14:30 +0900)
Change-Id: I78491d699ee6b447218c1a5dcb2507038aa64bed

TelegramTizen/res/edje/telegram_init_screen.edc

index cf77b5f..62a3b53 100644 (file)
@@ -158,6 +158,9 @@ collections {
                image: "telegram_emotion.png" COMP;
                image: "telegram_add_object.png" COMP;
                image: "telegram_send.png" COMP;
+               image: "telegram_attach_image_round_bg.#.png" COMP;
+               image: "telegram_attach_image_round_line.#.png" COMP;
+               image: "telegram_attach_image_round_shadow.#.png" COMP;
        }
 
    group {
@@ -1287,6 +1290,26 @@ group
                                }
                        }
                        part {
+                               name: "pressed,smile";
+                               type: IMAGE;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.5 0.5; to: "image,smile"; }
+                                       rel2 { relative: 0.5 0.5; to: "image,smile"; }
+                                       fixed: 1 1;
+                                       min: 50 50;
+                                       image.normal: "telegram_attach_image_round_bg.#.png";
+                                       color: 45 165 224 76;
+                                       visible: 0;
+                               }
+                               description {
+                                       state: "pressed" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 72 72;
+                                       visible: 1;
+                               }
+                       }
+                       part {
                                name: "image,smile";
                        type: IMAGE;
                        description{
@@ -1301,6 +1324,26 @@ group
                        }
                        }
                        part {
+                               name: "pressed,attach";
+                               type: IMAGE;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.5 0.5; to: "image,attach"; }
+                                       rel2 { relative: 0.5 0.5; to: "image,attach"; }
+                                       fixed: 1 1;
+                                       min: 50 50;
+                                       image.normal: "telegram_attach_image_round_bg.#.png";
+                                       color: 45 165 224 76;
+                                       visible: 0;
+                               }
+                               description {
+                                       state: "pressed" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 72 72;
+                                       visible: 1;
+                               }
+                       }
+                       part {
                                name: "image,attach";
                        type: IMAGE;
                        description{
@@ -1319,6 +1362,26 @@ group
                                        visible: 0;
                                }
                        }
+                       part {
+                               name: "pressed,send";
+                               type: IMAGE;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.5 0.5; to: "image,send"; }
+                                       rel2 { relative: 0.5 0.5; to: "image,send"; }
+                                       fixed: 1 1;
+                                       min: 50 50;
+                                       image.normal: "telegram_attach_image_round_bg.#.png";
+                                       color: 45 165 224 76;
+                                       visible: 0;
+                               }
+                               description {
+                                       state: "pressed" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 72 72;
+                                       visible: 1;
+                               }
+                       }
                part {
                                name: "image,send";
                        type: IMAGE;
@@ -1391,6 +1454,53 @@ group
                        target: "image,send";
                        target: "image,attach";
                }
+               /* pressed effect */
+               program {
+                       name: "smile,pressed";
+                       signal: "mouse,down,1";
+                       source: "image,smile";
+                       action: STATE_SET "pressed" 0.0;
+                       target: "pressed,smile";
+                       transition: LINEAR 0.2;
+               }
+               program {
+                       name: "smile,release";
+                       signal: "mouse,up,1";
+                       source: "image,smile";
+                       action: STATE_SET "default" 0.0;
+                       target: "pressed,smile";
+               }
+               program {
+                       name: "attach,pressed";
+                       signal: "mouse,down,1";
+                       source: "image,attach";
+                       action: STATE_SET "pressed" 0.0;
+                       target: "pressed,attach";
+                       transition: LINEAR 0.2;
+               }
+               program {
+                       name: "attach,release";
+                       signal: "mouse,up,1";
+                       source: "image,attach";
+                       action: STATE_SET "default" 0.0;
+                       target: "pressed,attach";
+               }
+               program {
+                       name: "send,pressed";
+                       signal: "mouse,down,1";
+                       source: "image,send";
+                       action: STATE_SET "pressed" 0.0;
+                       target: "pressed,send";
+                       transition: LINEAR 0.2;
+               }
+               program {
+                       name: "send,release";
+                       signal: "mouse,up,1";
+                       source: "image,send";
+                       action: STATE_SET "default" 0.0;
+                       target: "pressed,send";
+               }
+               /* clicked effect and send the signal to c file */
                program {
                        name: "smile,clicked";
                        signal: "mouse,clicked,1";
@@ -3121,17 +3231,7 @@ group
          }
       }
     }
-    
-    
-    images {
-               image: "telegram_attach_image_round_bg.#.png" COMP;
-               image: "telegram_attach_image_round_line.#.png" COMP;
-               image: "telegram_attach_image_round_shadow.#.png" COMP;         
-       }
-       
-       
-       
-       
+
     group { 
          name: "rounded_corner_layout";
       parts {