Added Reorder icon according to 4.0 UX 77/123077/2
authorbhutani.92 <bhutani.92@samsung.com>
Tue, 4 Apr 2017 10:25:54 +0000 (15:55 +0530)
committerAkhil Bhutani <bhutani.92@samsung.com>
Tue, 4 Apr 2017 11:00:15 +0000 (04:00 -0700)
Change-Id: Iada04db029c9cf1f39239fcaed6b2bce7f46c015
Signed-off-by: bhutani.92 <bhutani.92@samsung.com>
inc/mp-images.h
res/edje/mp-button.edc
res/edje/mp-images.edc
src/view/mp-player-view.c
src/widget/mp-track-list.c

index 632cf45..8675577 100644 (file)
@@ -23,7 +23,6 @@
 #define MP_LITE_PAUSE_ICON     "lite/play_list_control_pause.png"
 #define MP_LITE_PLAY_ICON      "lite/play_list_control_play.png"
 #define MP_LITE_SHUFFLE_ICON   "lite/Icon/play_icon_shuffle.png"
-#define MP_LITE_REORDER_ICON   "lite/core_button_reorder.png"
 
 #define NOCONTENT_MULTIMEDIA           "T02_Nocontents_multimedia.png"
 
index ac3e32c..5d90679 100644 (file)
 #define IMG_ARTIST_LIST_MORE_BTN_NORMAL                "button/T02_artist_list_more.png"
 #define IMG_ARTIST_LIST_MORE_BTN_PRESSED       "button/T02_artist_list_more_press.png"
 
-#define IMG_PLAYER_VIEW_OPTION_BTN             "player-view/T02_control_circle_button_03.png"
-#define IMG_PLAYER_VIEW_OPTION_BTN_PRESS       "player-view/T02_control_circle_button_03_press.png"
+#define IMG_PLAYER_VIEW_OPTION_BTN                     "player-view/T02_control_circle_button_03.png"
+#define IMG_PLAYER_VIEW_OPTION_BTN_PRESS       "player-view/T02_control_circle_button_03_press.png"
 
 /******************  lite path   ****************/
-#define IMG_PLAYER_VIEW_ICON_PATH              "lite/Icon/"
-#define IMG_PLAYER_VIEW_BUTTON_PATH            "lite/Button/"
+#define IMG_PLAYER_VIEW_ICON_PATH                      "lite/Icon/"
+#define IMG_PLAYER_VIEW_BUTTON_PATH                    "lite/Button/"
+#define IMG_LITE_REORDER_ICON                          "lite/core_button_reorder.png"
 
 #define IMG_PLAYER_VIEW_OPTION_VOLUME          IMG_PLAYER_VIEW_ICON_PATH"play_icon_vol.png"
 #define IMG_PLAYER_VIEW_OPTION_SHUFFLE_ON      IMG_PLAYER_VIEW_ICON_PATH"play_icon_shuffle.png"
 #define IMG_PLAYER_VIEW_OPTION_REP_A           IMG_PLAYER_VIEW_ICON_PATH"play_icon_rep_a.png"
 #define IMG_PLAYER_VIEW_OPTION_REP_1           IMG_PLAYER_VIEW_ICON_PATH"play_icon_rep_one.png"
 #define IMG_PLAYER_VIEW_OPTION_REP_ALL         IMG_PLAYER_VIEW_ICON_PATH"play_icon_rep_all.png"
-#define IMG_PLAYER_VIEW_OPTION_INFO            IMG_PLAYER_VIEW_ICON_PATH"play_icon_list.png"
+#define IMG_PLAYER_VIEW_OPTION_INFO                    IMG_PLAYER_VIEW_ICON_PATH"play_icon_list.png"
 //add favourite begin
-#define IMG_PLAYER_VIEW_OPTION_FAVOURITE_ON "player-view/T02_option_favorite_on.png"
-#define IMG_PLAYER_VIEW_OPTION_FAVOURITE_OFF "player-view/T02_option_favorite_off.png"
+#define IMG_PLAYER_VIEW_OPTION_FAVOURITE_ON                    "player-view/T02_option_favorite_on.png"
+#define IMG_PLAYER_VIEW_OPTION_FAVOURITE_OFF           "player-view/T02_option_favorite_off.png"
 
 //add like begin
-#define IMG_PLAYER_VIEW_OPTION_LIKE_ON "player-view/T02_option_favorite_on.png"
-#define IMG_PLAYER_VIEW_OPTION_LIKE_OFF "player-view/T02_option_favorite_off.png"
-#define IMG_PLAYER_VIEW_OPTION_LIKE_ON_PRESS "player-view/T02_option_like_press.png"
+#define IMG_PLAYER_VIEW_OPTION_LIKE_ON                         "player-view/T02_option_favorite_on.png"
+#define IMG_PLAYER_VIEW_OPTION_LIKE_OFF                                "player-view/T02_option_favorite_off.png"
+#define IMG_PLAYER_VIEW_OPTION_LIKE_ON_PRESS           "player-view/T02_option_like_press.png"
 //add block begin
-#define IMG_PLAYER_VIEW_OPTION_BLOCK_ON "player-view/T02_option_blocking_on.png"
-#define IMG_PLAYER_VIEW_OPTION_BLOCK_OFF "player-view/T02_option_blocking_dim.png"
-#define IMG_PLAYER_VIEW_OPTION_BLOCK_ON_PRESS "player-view/T02_option_blocking_press.png"
+#define IMG_PLAYER_VIEW_OPTION_BLOCK_ON                                "player-view/T02_option_blocking_on.png"
+#define IMG_PLAYER_VIEW_OPTION_BLOCK_OFF                       "player-view/T02_option_blocking_dim.png"
+#define IMG_PLAYER_VIEW_OPTION_BLOCK_ON_PRESS          "player-view/T02_option_blocking_press.png"
 
 //add favorite radio
-#define IMG_PLAYER_VIEW_TITLE_FAVORITE_RADIO_ON "player-view/T02_radio_favorite_on.png"
-#define IMG_PLAYER_VIEW_TITLE_FAVORITE_RADIO_OFF "player-view/T02_radio_favorite_off.png"
+#define IMG_PLAYER_VIEW_TITLE_FAVORITE_RADIO_ON                "player-view/T02_radio_favorite_on.png"
+#define IMG_PLAYER_VIEW_TITLE_FAVORITE_RADIO_OFF       "player-view/T02_radio_favorite_off.png"
 
 // control img
 #define IMG_PLAYER_VIEW_CONTROL_CIRCLE_BT_01           IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_01.png"
 #define IMG_PLAYER_VIEW_CONTROL_CIRCLE_BT_01_CIRCLE    IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_01_ef.png"
 #define IMG_PLAYER_VIEW_CONTROL_CIRCLE_BT_02           IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_02.png"
 #define IMG_PLAYER_VIEW_CONTROL_CIRCLE_BT_02_CIRCLE    IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_02_ef.png"
-#define IMG_PLAYER_VIEW_CONTROL_PREVIOUS               IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_prev.png"
-#define IMG_PLAYER_VIEW_CONTROL_PLAY                   IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_play.png"
-#define IMG_PLAYER_VIEW_CONTROL_PAUSE                  IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_pause.png"
-#define IMG_PLAYER_VIEW_CONTROL_NEXT                   IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_next.png"
-#define IMG_PLAYER_VIEW_CONTROL_VOLUME                 IMG_PLAYER_VIEW_ICON_PATH"play_icon_vol.png"
-#define IMG_PLAYER_VIEW_CONTROL_VOLUME_OFF             IMG_PLAYER_VIEW_ICON_PATH"play_icon_vol_off.png"
-#define IMG_PLAYER_VIEW_CONTROL_QUEUE_ON               IMG_PLAYER_VIEW_ICON_PATH"play_icon_list.png"
-#define IMG_PLAYER_VIEW_CONTROL_PLUS "T02_icon_volume_control_plus.png"
-#define IMG_PLAYER_VIEW_CONTROL_PLUS_PRESS "T02_icon_volume_control_plus_press.png"
-#define IMG_PLAYER_VIEW_CONTROL_MINUS "T02_icon_volume_control_minus.png"
-#define IMG_PLAYER_VIEW_CONTROL_MINUS_PRESS "T02_icon_volume_control_minus_press.png"
-#define IMG_PLAYER_VIEW_CONTROL_MUTE "T02_icon_volume_control_mute.png"
-#define IMG_PLAYER_VIEW_CONTROL_MUTE_PRESS "T02_icon_volume_control_mute_press.png"
+#define IMG_PLAYER_VIEW_CONTROL_PREVIOUS                       IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_prev.png"
+#define IMG_PLAYER_VIEW_CONTROL_PLAY                           IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_play.png"
+#define IMG_PLAYER_VIEW_CONTROL_PAUSE                          IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_pause.png"
+#define IMG_PLAYER_VIEW_CONTROL_NEXT                           IMG_PLAYER_VIEW_BUTTON_PATH"full_player_button_next.png"
+#define IMG_PLAYER_VIEW_CONTROL_VOLUME                         IMG_PLAYER_VIEW_ICON_PATH"play_icon_vol.png"
+#define IMG_PLAYER_VIEW_CONTROL_VOLUME_OFF                     IMG_PLAYER_VIEW_ICON_PATH"play_icon_vol_off.png"
+#define IMG_PLAYER_VIEW_CONTROL_QUEUE_ON                       IMG_PLAYER_VIEW_ICON_PATH"play_icon_list.png"
+#define IMG_PLAYER_VIEW_CONTROL_PLUS                           "T02_icon_volume_control_plus.png"
+#define IMG_PLAYER_VIEW_CONTROL_PLUS_PRESS                     "T02_icon_volume_control_plus_press.png"
+#define IMG_PLAYER_VIEW_CONTROL_MINUS                          "T02_icon_volume_control_minus.png"
+#define IMG_PLAYER_VIEW_CONTROL_MINUS_PRESS                    "T02_icon_volume_control_minus_press.png"
+#define IMG_PLAYER_VIEW_CONTROL_MUTE                           "T02_icon_volume_control_mute.png"
+#define IMG_PLAYER_VIEW_CONTROL_MUTE_PRESS                     "T02_icon_volume_control_mute_press.png"
 
 #define BUTTON_STATE_ENABLED 0
 #define BUTTON_STATE_DISABLED 1
@@ -95,12 +96,12 @@ images {
        image: IMG_PLAYER_VIEW_CONTROL_VOLUME COMP;
        image: IMG_PLAYER_VIEW_CONTROL_VOLUME_OFF COMP;
        image: IMG_PLAYER_VIEW_CONTROL_QUEUE_ON COMP;
-        image: IMG_PLAYER_VIEW_CONTROL_PLUS COMP;
-        image: IMG_PLAYER_VIEW_CONTROL_PLUS_PRESS COMP;
-        image: IMG_PLAYER_VIEW_CONTROL_MINUS COMP;
-        image: IMG_PLAYER_VIEW_CONTROL_MINUS_PRESS COMP;
-        image: IMG_PLAYER_VIEW_CONTROL_MUTE COMP;
-        image: IMG_PLAYER_VIEW_CONTROL_MUTE_PRESS COMP;
+       image: IMG_PLAYER_VIEW_CONTROL_PLUS COMP;
+       image: IMG_PLAYER_VIEW_CONTROL_PLUS_PRESS COMP;
+       image: IMG_PLAYER_VIEW_CONTROL_MINUS COMP;
+       image: IMG_PLAYER_VIEW_CONTROL_MINUS_PRESS COMP;
+       image: IMG_PLAYER_VIEW_CONTROL_MUTE COMP;
+       image: IMG_PLAYER_VIEW_CONTROL_MUTE_PRESS COMP;
 
        image: IMG_PLAYER_VIEW_OPTION_LIKE_ON COMP;
        image: IMG_PLAYER_VIEW_OPTION_LIKE_OFF COMP;
@@ -111,6 +112,7 @@ images {
 
        image: IMG_PLAYER_VIEW_TITLE_FAVORITE_RADIO_ON COMP;
        image: IMG_PLAYER_VIEW_TITLE_FAVORITE_RADIO_OFF COMP;
+       image: IMG_LITE_REORDER_ICON COMP;
 }
 
 #define MP_PLAYER_BUTTON_NOSOUND_STYLE(__name,__bg_normal,__bg_circle,__normal) \
@@ -2186,5 +2188,40 @@ group { name: "elm/button/base/music/artist/more";
         }
       }
 
+group {
+       name: "elm/button/base/music/reorder_button";
+       parts {
+               part {
+                       name: "elm.swallow.content";
+                       type: RECT;
+                       mouse_events: 1;
+                       repeat_events: 1;
+                       description {
+                               state: "default" 0.0;
+                               visible: 1;
+                               rel1.relative: 0.0 0.0;
+                               rel2.relative: 1.0 1.0;
+                               align: 1.0 0.5;
+                               color: 0 0 0 0;
+                       }
+               }
+               part {
+                       name: "elm.swallow.icon";
+                       type: IMAGE;
+                       scale: 1;
+                       mouse_events: 1;
+                       repeat_events: 1;
+                       description {
+                               state: "default" 0.0;
+                               min: 100 0;
+                               rel1.to: "elm.swallow.content";
+                               rel2.to: "elm.swallow.content";
+                               align: 1.0 0.5;
+                               color: 8 8 8 100;
+                               image.normal: IMG_LITE_REORDER_ICON;
+                       }
+               }
+       }
+}
 
 
index 98c8f38..491b0ca 100644 (file)
@@ -179,6 +179,5 @@ RESOURCE_IMAGE(MP_MINI_SHUFFLE_ON_ICON);
 RESOURCE_IMAGE(MP_LITE_PAUSE_ICON);
 RESOURCE_IMAGE(MP_LITE_PLAY_ICON);
 RESOURCE_IMAGE(MP_LITE_SHUFFLE_ICON);
-RESOURCE_IMAGE(MP_LITE_REORDER_ICON);
 
 }
index 0ebb951..1f068bc 100644 (file)
@@ -444,7 +444,6 @@ static void _mp_player_view_update_control_queue_list_btn(void *data)
                return;
        }
        snprintf(mp_image_path, 1024, "%s%s/%s", path, "edje", IMAGE_EDJ_NAME);
-       EVENT_TRACE("path of IMAGE_EDJ_NAME is %s", IMAGE_EDJ_NAME);
        free(path);
 
        if (view->queue_list) {
index 3127b58..d2591f5 100644 (file)
@@ -227,7 +227,6 @@ Evas_Object *_mp_track_list_icon_get(void *data, Evas_Object * obj,
                // if edit mode
                if (!strcmp(part, "elm.swallow.end")) {
                        // swallow checkbox or radio button
-
                        check = elm_check_add(obj);
                        elm_object_style_set(check, "default");
                        evas_object_propagate_events_set(check, EINA_FALSE);
@@ -242,17 +241,16 @@ Evas_Object *_mp_track_list_icon_get(void *data, Evas_Object * obj,
 
        if (list->reorderable) {
                if (!strcmp(part, "elm.swallow.end")) {
-                       Evas_Object *thumbnail = NULL;
-                       thumbnail = elm_image_add(obj);
-                       elm_image_file_set(thumbnail, IMAGE_EDJ_NAME,
-                                                          MP_LITE_REORDER_ICON);
-                       evas_object_color_set(thumbnail, 8, 8, 8, 204);
-                       evas_object_size_hint_align_set(thumbnail, EVAS_HINT_FILL,
+                       Evas_Object *reorder_btn = elm_button_add(obj);
+                       elm_object_style_set(reorder_btn, "music/reorder_button");
+                       evas_object_repeat_events_set(reorder_btn, EINA_TRUE);
+                       evas_object_propagate_events_set(reorder_btn, EINA_FALSE);
+                       evas_object_size_hint_align_set(reorder_btn, EVAS_HINT_FILL,
                                                                                        EVAS_HINT_FILL);
-                       evas_object_size_hint_weight_set(thumbnail, EVAS_HINT_EXPAND,
+                       evas_object_size_hint_weight_set(reorder_btn, EVAS_HINT_EXPAND,
                                                                                         EVAS_HINT_EXPAND);
 
-                       return thumbnail;
+                       return reorder_btn;
                }
 
        }