Fixed playspeed background and language translation for tabs 46/253346/1 submit/tizen/20210209.094606
authoraman.jeph <aman.jeph@samsung.com>
Tue, 9 Feb 2021 05:00:18 +0000 (10:30 +0530)
committeraman.jeph <aman.jeph@samsung.com>
Tue, 9 Feb 2021 05:00:18 +0000 (10:30 +0530)
Change-Id: I37762605ece6ed4b29da71659e05b54247c62a11
Signed-off-by: aman.jeph <aman.jeph@samsung.com>
playview/src/vp-play-view.c
src/view/mp-video-list-view-main.c
vp-main/res/edje/images/play_speed_bg.png [new file with mode: 0755]
vp-main/res/edje/pv-normal-main.edc

index 52fe7577770fb1fb70b530919b7b4e5461f8a8be..a7e7806044e68add785d8594c605629517968cfc 100755 (executable)
@@ -1992,7 +1992,7 @@ bool vp_play_view_realize(play_view_handle pViewHandle)
        if(pPlayView->stream_info == NULL) {
                vp_sound_init_session(pViewHandle);
        }
-
+       // Only capture the audio stream on resume when player was in play state before pause.
        if (!vp_play_normal_view_is_audio_only(pPlayView) && manual_paused == FALSE) {
                sound_stream_focus_state_e state_for_playback;
                sound_stream_focus_state_e state_for_recording;
index 9788d12c0697b2d264fdf50a4ea82734f1694d98..dac1c643c7bab7299ee0c65b6d82eb55c2c4f02c 100755 (executable)
@@ -65,8 +65,8 @@
 
 
 
-#define TOOLBAR_BUTTON_VIDEOS "Videos"
-#define TOOLBAR_BUTTOn_FOLDERS "Folders"
+#define TOOLBAR_BUTTON_VIDEOS VIDEOS_VIEWASOPT_OPT_THUMBNAIL
+#define TOOLBAR_BUTTOn_FOLDERS VIDEOS_TITLE_OPT_FOLDER
 
 static st_VideoListViewMainViewHandle *g_pMainViewHandle = NULL;
 static st_VideoListViewMainViewWidget *g_pMainViewWidget = NULL;
@@ -1277,6 +1277,12 @@ toolbar_folders_item_cb(void *data, Evas_Object *obj, void *event_info)
                                        LIST_UPDATE_TYPE_ALL, __mp_list_view_result_user_cb);
 }
 
+static void _tolbar_language_changed(void *data, Evas_Object *obj, void *event_info)
+{
+       elm_object_item_part_text_set(g_pToolbarItemData.videos_item, "elm.text", TOOLBAR_BUTTON_VIDEOS);
+       elm_object_item_part_text_set(g_pToolbarItemData.folders_item, "elm.text", TOOLBAR_BUTTOn_FOLDERS);
+}
+
 Evas_Object* mp_list_view_create_toolbar(Evas_Object* naviframe)
 {
        Evas_Object *toolbar;
@@ -1288,6 +1294,8 @@ Evas_Object* mp_list_view_create_toolbar(Evas_Object* naviframe)
        elm_toolbar_transverse_expanded_set(toolbar, EINA_TRUE);
        elm_toolbar_select_mode_set(toolbar, ELM_OBJECT_SELECT_MODE_ALWAYS);
 
+       evas_object_smart_callback_add(toolbar, "language,changed", _tolbar_language_changed, NULL);
+
        g_pToolbarItemData.videos_item = elm_toolbar_item_append(toolbar, NULL, TOOLBAR_BUTTON_VIDEOS, toolbar_videos_item_cb, NULL);
        g_pToolbarItemData.folders_item = elm_toolbar_item_append(toolbar, NULL, TOOLBAR_BUTTOn_FOLDERS, toolbar_folders_item_cb, NULL);
 
diff --git a/vp-main/res/edje/images/play_speed_bg.png b/vp-main/res/edje/images/play_speed_bg.png
new file mode 100755 (executable)
index 0000000..dcb9d36
Binary files /dev/null and b/vp-main/res/edje/images/play_speed_bg.png differ
index 4ab6311c9aa3d09e429df3779170640259263f04..735464ae946bd15d7e70d42fb427882e71692e88 100755 (executable)
@@ -39,6 +39,10 @@ externals {
           external: "feedback";
        }
 
+images {
+       image: "play_speed_bg.png" COMP;
+}
+
 collections {
        base_scale: CURRENT_BASE_SCALE;
        plugins {
@@ -639,19 +643,22 @@ collections {
 
                        part {
                                name: "pv.normal.main.playingspeed.rect";
-                               type: RECT;
+                               type: IMAGE;
                                mouse_events: 1;
                                repeat_events : 1;
                                scale: 1;
                                description {
                                        state: "default" 0.0;
                                        visible: 0;
-                                       min: 100 25;
+                                       min: 80 80;
+                                       max: 80 80;
                                        fixed: 1 1;
                                        align: 0.5 1.0;
-                                       rel1 { relative: 0.4 0.0; to_y : "pv.normal.main.control"; offset : 0 -20; }
-                                       rel2 { relative: 0.6 0.0; to_y : "pv.normal.main.control"; offset : 0 -20; }
-                                       color:  0 0 0 102;
+                                       rel1 { to: "pv.normal.main.control"; relative: 0.0 0.0; }
+                                       rel2 { to: "pv.normal.main.control"; relative: 1.0 0.0; offset: 0 -10; }
+                                       image {
+                                               normal: "play_speed_bg.png";
+                                       }
                                }
                                description {
                                        state: "show" 0.0;
@@ -668,7 +675,7 @@ collections {
                                description {
                                        state: "default" 0.0;
                                        visible: 0;
-                                       align: 0.0 0.0;
+                                       align: 0.5 0.5;
                                        rel1 { relative: 0.0 0.0; to : "pv.normal.main.playingspeed.rect";}
                                        rel2 { relative: 1.0 1.0; to : "pv.normal.main.playingspeed.rect";}
                                        color: FONT_COLOR;