diff options
author | aman.jeph <aman.jeph@samsung.com> | 2020-08-25 16:37:31 +0530 |
---|---|---|
committer | aman.jeph <aman.jeph@samsung.com> | 2020-08-25 16:37:31 +0530 |
commit | 0a5382619f306d4840dfd0e39599b89d43e76d0b (patch) | |
tree | 4b54fe6636170864d85a93d5ff5007be830fc021 | |
parent | 2b0c0959a31b4d3ac1861dae08a5be858e693509 (diff) | |
download | video-player-0a5382619f306d4840dfd0e39599b89d43e76d0b.tar.gz video-player-0a5382619f306d4840dfd0e39599b89d43e76d0b.tar.bz2 video-player-0a5382619f306d4840dfd0e39599b89d43e76d0b.zip |
Implemented subtitle according to new guidline[TIZENIOT-1846] and added new default [TIZENIOT-1584]submit/tizen/20200825.121753
Change-Id: I8643783fcfa12b2f9232fbdfc9f5dda5e5b55c56
Signed-off-by: aman.jeph <aman.jeph@samsung.com>
-rwxr-xr-x | playview/src/feature/include/vp-subtitle-select.h | 1 | ||||
-rwxr-xr-x | playview/src/feature/vp-subtitle-select.c | 135 | ||||
-rwxr-xr-x | playview/src/feature/vp-subtitle.c | 27 | ||||
-rwxr-xr-x | playview/src/include/vp-play-macro-define.h | 2 | ||||
-rwxr-xr-x | playview/src/view/vp-play-normal-view.c | 11 | ||||
-rwxr-xr-x | playview/src/widget/include/vp-play-popup.h | 2 | ||||
-rwxr-xr-x | playview/src/widget/vp-play-popup.c | 14 | ||||
-rwxr-xr-x | res/images/default_folder_thumbnail.png | bin | 0 -> 2615 bytes | |||
-rwxr-xr-x | src/view/mp-video-list-remove-view.c | 2 | ||||
-rwxr-xr-x | src/view/mp-video-list-view-folder.c | 2 | ||||
-rwxr-xr-x | vp-main/res/edje/pv-normal-main.edc | 38 | ||||
-rwxr-xr-x | vp-main/res/edje/pv-subtitle.edc | 15 | ||||
-rwxr-xr-x | vp-main/res/po/en.po | 2 | ||||
-rwxr-xr-x | vp-main/res/po/en_PH.po | 2 | ||||
-rwxr-xr-x | vp-main/res/po/en_US.po | 2 | ||||
-rwxr-xr-x | vp-main/src/vp-main.c | 2 |
16 files changed, 161 insertions, 96 deletions
diff --git a/playview/src/feature/include/vp-subtitle-select.h b/playview/src/feature/include/vp-subtitle-select.h index 0908764..46070b5 100755 --- a/playview/src/feature/include/vp-subtitle-select.h +++ b/playview/src/feature/include/vp-subtitle-select.h @@ -33,6 +33,7 @@ subtitle_select_handle vp_subtitle_select_create(Evas_Object * pParent, pButtonCb, GList * pFileList, char *szCurrentPath, + char *fileName, bool isSubtitleOff); void vp_subtitle_select_destroy(subtitle_select_handle pSubtitleSelectHandle); diff --git a/playview/src/feature/vp-subtitle-select.c b/playview/src/feature/vp-subtitle-select.c index 3666170..f50899f 100755 --- a/playview/src/feature/vp-subtitle-select.c +++ b/playview/src/feature/vp-subtitle-select.c @@ -68,7 +68,11 @@ static void __vp_subtitle_select_genlist_realized(void *data, Evas_Object * obj, void *event_info) { - VP_GENLIST_HIDE_BOTTOMLINE(data, obj, event_info); + Elm_Widget_Item *current_item = (Elm_Widget_Item*)event_info; + if(current_item == elm_genlist_last_item_get(obj)) + { + elm_object_item_signal_emit(current_item, "elm,state,bottomline,hide", "elm"); + } } /** @@ -103,7 +107,7 @@ static void __vp_subtitle_select_popup_rotate_cb(void *data, * @param pPart * @return */ -static char *__vp_subtitle_select_genlist_text_get_cb(const void +static char *__vp_subtitle_select_genlist_text_get_cb(void *pUserData, Evas_Object * pObj, const char *pPart) @@ -132,7 +136,7 @@ static char *__vp_subtitle_select_genlist_text_get_cb(const void * @param pPart * @return */ -static Evas_Object *__vp_subtitle_select_genlist_content_get_cb(const void +static Evas_Object *__vp_subtitle_select_genlist_content_get_cb(void *pUserData, Evas_Object *pObj, @@ -146,7 +150,7 @@ static Evas_Object *__vp_subtitle_select_genlist_content_get_cb(const void char *szTxt = (char *) pUserData; - if (!strcmp(pPart, "elm.swallow.end")) { + if (!strcmp(pPart, "elm.icon")) { Evas_Object *pRadioObj = NULL; SubtitleSelectPopup *pSubtitleSelect = @@ -187,11 +191,8 @@ static Evas_Object *__vp_subtitle_select_genlist_content_get_cb(const void pRadioObj = elm_radio_add(pObj); elm_radio_state_value_set(pRadioObj, nIndex); elm_radio_group_add(pRadioObj, pSubtitleSelect->pRadio); - elm_radio_value_set(pSubtitleSelect->pRadio, - pSubtitleSelect->nSubtitleIdx); - evas_object_smart_callback_add(pRadioObj, "changed", - __vp_subtitle_select_genlist_item_selected_cb, - pSubtitleSelect); + elm_radio_value_set(pSubtitleSelect->pRadio, pSubtitleSelect->nSubtitleIdx); + elm_object_signal_emit(pRadioObj, "elm,activate,radio,on", "elm"); evas_object_show(pRadioObj); return pRadioObj; } @@ -221,8 +222,7 @@ static void __vp_subtitle_select_genlist_item_selected_cb(void *pUserData, } Elm_Object_Item *pItem = (Elm_Object_Item *) pEventInfo; - Elm_Object_Item *pSelectedItem = - elm_genlist_selected_item_get(pObject); + Elm_Object_Item *pSelectedItem = elm_genlist_selected_item_get(pObject); if (pSelectedItem) { elm_genlist_item_selected_set(pSelectedItem, EINA_FALSE); } @@ -234,8 +234,7 @@ static void __vp_subtitle_select_genlist_item_selected_cb(void *pUserData, return; } - SubtitleSelectPopup *pSubtitleSelect = - (SubtitleSelectPopup *) pUserData; + SubtitleSelectPopup *pSubtitleSelect = (SubtitleSelectPopup *) pUserData; int nIndex = 0; int nCount = 0; int i = 0; @@ -255,15 +254,7 @@ static void __vp_subtitle_select_genlist_item_selected_cb(void *pUserData, } pSubtitleSelect->nSubtitleIdx = nIndex; - if (szTxt) { - char *szName = NULL; - VP_STRDUP(szName, szTxt); - if (pSubtitleSelect->pCloseCb) { - pSubtitleSelect->pCloseCb(szName, - (void *) pSubtitleSelect->pUserData); - } - VP_FREE(szName); - } + elm_radio_value_set(pSubtitleSelect->pRadio, pSubtitleSelect->nSubtitleIdx); } /** @@ -272,7 +263,28 @@ static void __vp_subtitle_select_genlist_item_selected_cb(void *pUserData, * @param pObj * @param pEventInfo */ -static void __vp_subtitle_select_popup_cancel_cb(void *pUserData, +static void __vp_subtitle_select_popup_back_cb(void *pUserData, Evas_Object * pObj, void *pEventInfo) +{ + if (pUserData == NULL) { + VideoLogError("pUserData is NULL"); + return; + } + + SubtitleSelectPopup *pSubtitleSelect = (SubtitleSelectPopup *) pUserData; + + if (pSubtitleSelect->pButtonCb) { + pSubtitleSelect->pButtonCb("cancel", (void *) pSubtitleSelect->pUserData); + } +} + + +/** + * + * @param pUserData + * @param pObj + * @param pEventInfo + */ +static void __vp_subtitle_select_popup_done_cb(void *pUserData, Evas_Object * pObj, void *pEventInfo) { @@ -281,12 +293,16 @@ static void __vp_subtitle_select_popup_cancel_cb(void *pUserData, return; } - SubtitleSelectPopup *pSubtitleSelect = - (SubtitleSelectPopup *) pUserData; + SubtitleSelectPopup *pSubtitleSelect = (SubtitleSelectPopup *) pUserData; - if (pSubtitleSelect->pButtonCb) { - pSubtitleSelect->pButtonCb("cancel", - (void *) pSubtitleSelect->pUserData); + if((pSubtitleSelect && (pSubtitleSelect->nSubtitleIdx >= 0) && (pSubtitleSelect->nSubtitleIdx < g_list_length(pSubtitleSelect->pItemList)))) + { + char *path = (char*) g_list_nth_data(pSubtitleSelect->pItemList, pSubtitleSelect->nSubtitleIdx); + if(pSubtitleSelect->pCloseCb) { + char *path_cp = NULL; + VP_STRDUP(path_cp, path); + pSubtitleSelect->pCloseCb(path_cp, pSubtitleSelect->pUserData); + } } } @@ -413,11 +429,9 @@ static bool _vp_subtitle_select_add_genlist_item(Evas_Object * pObj, if (pSubtitleSelect->st_SubtitleSelect_Itc != NULL) { pSubtitleSelect->st_SubtitleSelect_Itc->version = ELM_GENLIST_ITEM_CLASS_VERSION; - pSubtitleSelect->st_SubtitleSelect_Itc->item_style = "type1"; - pSubtitleSelect->st_SubtitleSelect_Itc->func.text_get = - (void *) __vp_subtitle_select_genlist_text_get_cb; - pSubtitleSelect->st_SubtitleSelect_Itc->func.content_get = - (void *) __vp_subtitle_select_genlist_content_get_cb; + pSubtitleSelect->st_SubtitleSelect_Itc->item_style = "1line"; + pSubtitleSelect->st_SubtitleSelect_Itc->func.text_get = __vp_subtitle_select_genlist_text_get_cb; + pSubtitleSelect->st_SubtitleSelect_Itc->func.content_get = __vp_subtitle_select_genlist_content_get_cb; pSubtitleSelect->st_SubtitleSelect_Itc->func.state_get = NULL; pSubtitleSelect->st_SubtitleSelect_Itc->func.del = NULL; } @@ -469,6 +483,7 @@ subtitle_select_handle vp_subtitle_select_create(Evas_Object * pParent, pButtonCb, GList * pFileList, char *szCurrentPath, + char *fileName, bool isSubtitleOff) { if (pParent == NULL) { @@ -496,30 +511,28 @@ subtitle_select_handle vp_subtitle_select_create(Evas_Object * pParent, pSubtitleSelect->pPopup = vp_two_button_popup_create(pParent, VP_PLAY_STRING_SUBTITLE_SELECT_SUBTITLES, - NULL, VP_PLAY_STRING_COM_CANCEL, - __vp_subtitle_select_popup_cancel_cb, - VP_PLAY_STRING_SETTINGS, + NULL, VP_PLAY_STRING_COM_DONE, "border", + __vp_subtitle_select_popup_done_cb, + VP_PLAY_STRING_SETTINGS, NULL, __vp_subtitle_select_popup_settings_cb, (void *) pSubtitleSelect); else { pSubtitleSelect->pPopup = vp_two_button_popup_create(pParent, VP_PLAY_STRING_SUBTITLE_SELECT_SUBTITLES, - NULL, VP_PLAY_STRING_COM_CANCEL, - __vp_subtitle_select_popup_cancel_cb, - VP_PLAY_STRING_SETTINGS, NULL, + NULL, VP_PLAY_STRING_COM_DONE, "border", + __vp_subtitle_select_popup_done_cb, + VP_PLAY_STRING_SETTINGS, NULL, NULL, (void *) pSubtitleSelect); - Elm_Object_Item *it = NULL; - it = (Evas_Object *) elm_object_part_content_get(pSubtitleSelect-> - pPopup, - "button2"); - if (it) { - elm_object_disabled_set(it, EINA_TRUE); + Evas_Object *button = NULL; + button = elm_object_part_content_get(pSubtitleSelect->pPopup, "button2"); + if (button) { + elm_object_disabled_set(button, EINA_TRUE); } } eext_object_event_callback_add(pSubtitleSelect->pPopup, EEXT_CALLBACK_BACK, - __vp_subtitle_select_popup_cancel_cb, + __vp_subtitle_select_popup_back_cb, (void *) pSubtitleSelect); if (pSubtitleSelect->pPopup == NULL) { VideoLogError("vp_popup_create fail"); @@ -546,7 +559,7 @@ subtitle_select_handle vp_subtitle_select_create(Evas_Object * pParent, int i = 0; int nCount = 0; - + bool subtitle_file_exist = false; if (pFileList) { for (i = 0; i < nItemCount; i++) { char *szName = NULL; @@ -555,16 +568,33 @@ subtitle_select_handle vp_subtitle_select_create(Evas_Object * pParent, if (szName == NULL) { continue; } + bool found = false; if (szCurrentPath) { if (strcmp(szName, szCurrentPath) == 0) { - pSubtitleSelect->nSubtitleIdx = nCount; + pSubtitleSelect->nSubtitleIdx = 0; elm_radio_value_set(pSubtitleSelect->pRadio, pSubtitleSelect->nSubtitleIdx); + found = true; + } + } else { + char *file = vp_file_get(szName); + char *title = vp_strip_ext(file); + if(strcmp(title, fileName) == 0) + { + pSubtitleSelect->nSubtitleIdx = 0; + elm_radio_value_set(pSubtitleSelect->pRadio, pSubtitleSelect->nSubtitleIdx); + found = true; + subtitle_file_exist = true; } + VP_FREE(title) } VP_STRDUP(szItem, szName); - pSubtitleSelect->pItemList = - g_list_append(pSubtitleSelect->pItemList, (void *) szItem); + if(found) { + pSubtitleSelect->pItemList = g_list_prepend(pSubtitleSelect->pItemList, (void *) szItem); + found = false; + } else { + pSubtitleSelect->pItemList = g_list_append(pSubtitleSelect->pItemList, (void *) szItem); + } nCount++; } } @@ -582,10 +612,9 @@ subtitle_select_handle vp_subtitle_select_create(Evas_Object * pParent, _vp_subtitle_select_destroy_handle(pSubtitleSelect); return FALSE; } - if (isSubtitleOff || !bOn) { + if (subtitle_file_exist == false && (isSubtitleOff || !bOn)) { pSubtitleSelect->nSubtitleIdx = (nCount - 1); - elm_radio_value_set(pSubtitleSelect->pRadio, - pSubtitleSelect->nSubtitleIdx); + elm_radio_value_set(pSubtitleSelect->pRadio, pSubtitleSelect->nSubtitleIdx); } evas_object_smart_callback_add(pSubtitleSelect->pParent, "rotation,changed", diff --git a/playview/src/feature/vp-subtitle.c b/playview/src/feature/vp-subtitle.c index abe8af2..4b6183d 100755 --- a/playview/src/feature/vp-subtitle.c +++ b/playview/src/feature/vp-subtitle.c @@ -385,7 +385,7 @@ static char *__vp_subtitle_get_color_and_opacity(char *szColorHex) * @param pPart * @return */ -static char *__vp_subtitle_genlist_text_get_cb(const void *pUserData, +static char *__vp_subtitle_genlist_text_get_cb(void *pUserData, Evas_Object * pObj, const char *pPart) { @@ -607,7 +607,7 @@ static Evas_Object *__vp_subtitle_genlist_content_get_cb(void *data, } VideoLogWarning("part = %s", part); - if (!strcmp(part, "elm.swallow.icon")) { + if (!strcmp(part, "elm.icon")) { if (!g_strcmp0(VP_PLAY_STRING_PREVIEW_SUBTITLE_CC, (char *) data)) { Evas_Object *pCaption = _vp_subtitle_create_caption_layout(pSubtitle, obj); @@ -619,7 +619,7 @@ static Evas_Object *__vp_subtitle_genlist_content_get_cb(void *data, } } - if (!strcmp(part, "elm.swallow.end")) { + if (!strcmp(part, "elm.icon")) { if (!g_strcmp0(VP_PLAY_STRING_ACTIVATION, (char *) data)) { Evas_Object *pCheck = NULL; pCheck = elm_check_add(obj); @@ -1020,11 +1020,9 @@ static bool _vp_subtitle_add_genlist_item(Evas_Object * pObj, if (pSubtitle->st_Subtitle_Itc_1 != NULL) { pSubtitle->st_Subtitle_Itc_1->version = ELM_GENLIST_ITEM_CLASS_VERSION; - pSubtitle->st_Subtitle_Itc_1->item_style = "type1"; - pSubtitle->st_Subtitle_Itc_1->func.text_get = - (void *) __vp_subtitle_genlist_text_get_cb; - pSubtitle->st_Subtitle_Itc_1->func.content_get = - (void *) __vp_subtitle_genlist_content_get_cb; + pSubtitle->st_Subtitle_Itc_1->item_style = "1line"; + pSubtitle->st_Subtitle_Itc_1->func.text_get = __vp_subtitle_genlist_text_get_cb; + pSubtitle->st_Subtitle_Itc_1->func.content_get = __vp_subtitle_genlist_content_get_cb; pSubtitle->st_Subtitle_Itc_1->func.state_get = NULL; pSubtitle->st_Subtitle_Itc_1->func.del = NULL; } @@ -1034,9 +1032,8 @@ static bool _vp_subtitle_add_genlist_item(Evas_Object * pObj, if (pSubtitle->st_Subtitle_Itc_2 != NULL) { pSubtitle->st_Subtitle_Itc_2->version = ELM_GENLIST_ITEM_CLASS_VERSION; - pSubtitle->st_Subtitle_Itc_2->item_style = "type1"; - pSubtitle->st_Subtitle_Itc_2->func.text_get = - (void *) __vp_subtitle_genlist_text_get_cb; + pSubtitle->st_Subtitle_Itc_2->item_style = "2line"; + pSubtitle->st_Subtitle_Itc_2->func.text_get = __vp_subtitle_genlist_text_get_cb; pSubtitle->st_Subtitle_Itc_2->func.content_get = NULL; pSubtitle->st_Subtitle_Itc_2->func.state_get = NULL; pSubtitle->st_Subtitle_Itc_2->func.del = NULL; @@ -1047,10 +1044,9 @@ static bool _vp_subtitle_add_genlist_item(Evas_Object * pObj, if (pSubtitle->st_Subtitle_Itc_1icon != NULL) { pSubtitle->st_Subtitle_Itc_1icon->version = ELM_GENLIST_ITEM_CLASS_VERSION; - pSubtitle->st_Subtitle_Itc_1icon->item_style = "1icon"; + pSubtitle->st_Subtitle_Itc_1icon->item_style = "1line"; pSubtitle->st_Subtitle_Itc_1icon->func.text_get = NULL; - pSubtitle->st_Subtitle_Itc_1icon->func.content_get = - (void *) __vp_subtitle_genlist_content_get_cb; + pSubtitle->st_Subtitle_Itc_1icon->func.content_get = __vp_subtitle_genlist_content_get_cb; pSubtitle->st_Subtitle_Itc_1icon->func.state_get = NULL; pSubtitle->st_Subtitle_Itc_1icon->func.del = NULL; } @@ -1061,8 +1057,7 @@ static bool _vp_subtitle_add_genlist_item(Evas_Object * pObj, pSubtitle->st_Subtitle_Itc_groupindex->version = ELM_GENLIST_ITEM_CLASS_VERSION; pSubtitle->st_Subtitle_Itc_groupindex->item_style = "group_index"; - pSubtitle->st_Subtitle_Itc_groupindex->func.text_get = - (void *) __vp_subtitle_genlist_text_get_cb; + pSubtitle->st_Subtitle_Itc_groupindex->func.text_get = __vp_subtitle_genlist_text_get_cb; pSubtitle->st_Subtitle_Itc_groupindex->func.content_get = NULL; pSubtitle->st_Subtitle_Itc_groupindex->func.state_get = NULL; pSubtitle->st_Subtitle_Itc_groupindex->func.del = NULL; diff --git a/playview/src/include/vp-play-macro-define.h b/playview/src/include/vp-play-macro-define.h index 236caca..06d237f 100755 --- a/playview/src/include/vp-play-macro-define.h +++ b/playview/src/include/vp-play-macro-define.h @@ -51,7 +51,7 @@ do { \ if (!event_info || !obj) { \ return; \ } \ - elm_object_item_signal_emit(elm_genlist_last_item_get(obj), "elm,state,bottomline,hide", ""); \ + elm_object_item_signal_emit(elm_genlist_last_item_get(obj), "elm,state,bottomline,hide", "elm"); \ } while (0); diff --git a/playview/src/view/vp-play-normal-view.c b/playview/src/view/vp-play-normal-view.c index e46cf12..af95744 100755 --- a/playview/src/view/vp-play-normal-view.c +++ b/playview/src/view/vp-play-normal-view.c @@ -1649,6 +1649,7 @@ static void __vp_normal_subtitle_select_popup_done_cb(char *szFilePath, SELECT_DONE: VP_FREE(szSubtitle); + VP_FREE(szFilePath); } @@ -5503,9 +5504,9 @@ static void __vp_normal_ctx_popup_delete_cb(void *pUserData, pNormalView->pPopup = vp_two_button_popup_create(pPlayView->pWin, VP_PLAY_STRING_POPUP_DELETE, VP_PLAY_STRING_POPUP_DELETE_CONTENT, - VP_PLAY_STRING_CANCEL, + VP_PLAY_STRING_CANCEL, NULL, __vp_normal_del_popup_cancel_cb, - VP_PLAY_STRING_POPUP_DELETE, + VP_PLAY_STRING_POPUP_DELETE, NULL, __vp_normal_del_popup_delete_cb, (const void *) pNormalView); @@ -10347,6 +10348,7 @@ static void _vp_play_normal_view_on_subtitle_select_popup(NormalView * return; } char *szSubtitle = NULL; + char *fileName = NULL; GList *pItemList = NULL; char *szDir = NULL; szDir = vp_play_util_get_folder_from_path(pNormalView->szMediaURL); @@ -10393,13 +10395,16 @@ static void _vp_play_normal_view_on_subtitle_select_popup(NormalView * #endif VP_FREE(szDir); vp_mm_player_get_subtitle_url(pNormalView->pPlayerHandle, &szSubtitle); + fileName = vp_play_util_get_title_from_path(pNormalView->szMediaURL); + pNormalView->pSubtitleSelectPopup = vp_subtitle_select_create(pPlayView->pWin, __vp_normal_subtitle_select_popup_done_cb, __vp_normal_subtitle_select_button_popup_done_cb, - pItemList, szSubtitle, + pItemList, szSubtitle, fileName, !(pNormalView->bIsExistSubtitle)); VP_FREE(szSubtitle); + VP_FREE(fileName); if (pItemList) { int nCount = 0; diff --git a/playview/src/widget/include/vp-play-popup.h b/playview/src/widget/include/vp-play-popup.h index 87ec4f7..bb12522 100755 --- a/playview/src/widget/include/vp-play-popup.h +++ b/playview/src/widget/include/vp-play-popup.h @@ -61,8 +61,10 @@ Evas_Object *vp_popup_create(Evas_Object * pParent, Evas_Object *vp_two_button_popup_create(Evas_Object * pParent, char *szTitle, char *szContent, char *pLeftButtonText, + const char *pLeftStyle, Evas_Smart_Cb leftButtonCb, char *pRightButtonText, + const char *pRightStyle, Evas_Smart_Cb rightButtonCb, const void *pUserData); #ifdef _SUBTITLE_MULTI_LANGUAGE diff --git a/playview/src/widget/vp-play-popup.c b/playview/src/widget/vp-play-popup.c index 8946786..a797cde 100755 --- a/playview/src/widget/vp-play-popup.c +++ b/playview/src/widget/vp-play-popup.c @@ -121,8 +121,10 @@ Evas_Object *vp_two_button_popup_create(Evas_Object * pParent, char *szTitle, char *szContent, char *pLeftButtonText, + const char *pLeftStyle, Evas_Smart_Cb leftButtonCb, char *pRightButtonText, + const char *pRightStyle, Evas_Smart_Cb rightButtonCb, const void *pUserData) { @@ -153,7 +155,9 @@ Evas_Object *vp_two_button_popup_create(Evas_Object * pParent, } pBtn1 = elm_button_add(pPopup); - elm_object_style_set(pBtn1, "popup"); + if(pLeftStyle) { + elm_object_style_set(pBtn1, pLeftStyle); + } elm_object_text_set(pBtn1, pLeftButtonText); elm_object_part_content_set(pPopup, "button1", pBtn1); if (leftButtonCb) @@ -161,7 +165,9 @@ Evas_Object *vp_two_button_popup_create(Evas_Object * pParent, (const void *) pUserData); pBtn2 = elm_button_add(pPopup); - elm_object_style_set(pBtn2, "popup"); + if(pRightStyle){ + elm_object_style_set(pBtn2, pRightStyle); + } elm_object_text_set(pBtn2, pRightButtonText); elm_object_part_content_set(pPopup, "button2", pBtn2); @@ -199,8 +205,8 @@ Evas_Object *vp_title_two_button_popup_create(Evas_Object * pParent, Evas_Object *pPopup = NULL; pPopup = vp_two_button_popup_create(pParent, NULL, szContent, - pLeftButtonText, leftButtonCb, - pRightButtonText, rightButtonCb, + pLeftButtonText, NULL, leftButtonCb, + pRightButtonText, NULL, rightButtonCb, pUserData); if (szTitle && pPopup) { elm_object_part_text_set(pPopup, "title,text", szTitle); diff --git a/res/images/default_folder_thumbnail.png b/res/images/default_folder_thumbnail.png Binary files differnew file mode 100755 index 0000000..eeeb2b1 --- /dev/null +++ b/res/images/default_folder_thumbnail.png diff --git a/src/view/mp-video-list-remove-view.c b/src/view/mp-video-list-remove-view.c index 3f64a09..f4eb6bb 100755 --- a/src/view/mp-video-list-remove-view.c +++ b/src/view/mp-video-list-remove-view.c @@ -846,7 +846,7 @@ static Evas_Object *__mp_remove_folder_view_get_grid_icon_cb(void *pUserData, Ev { char edj_path[1024] = {0, }; char *path = app_get_resource_path(); - snprintf(edj_path, 1024, "%s%s/%s", path, "images", "default_thumbnail.png"); + snprintf(edj_path, 1024, "%s%s/%s", path, "images", "default_folder_thumbnail.png"); free(path); elm_image_aspect_fixed_set(img, EINA_TRUE); elm_image_file_set(img, edj_path, NULL); diff --git a/src/view/mp-video-list-view-folder.c b/src/view/mp-video-list-view-folder.c index 70de54c..4582296 100755 --- a/src/view/mp-video-list-view-folder.c +++ b/src/view/mp-video-list-view-folder.c @@ -275,7 +275,7 @@ static Evas_Object *mp_folder_view_get_icon_of_folder_cb(void *pUserData,Evas_Ob { char edj_path[1024] = {0, }; char *path = app_get_resource_path(); - snprintf(edj_path, 1024, "%s%s/%s", path, "images", "default_thumbnail.png"); + snprintf(edj_path, 1024, "%s%s/%s", path, "images", "default_folder_thumbnail.png"); free(path); elm_image_aspect_fixed_set(img, EINA_TRUE); elm_image_file_set(img, edj_path, NULL); diff --git a/vp-main/res/edje/pv-normal-main.edc b/vp-main/res/edje/pv-normal-main.edc index 79267cc..4ab6311 100755 --- a/vp-main/res/edje/pv-normal-main.edc +++ b/vp-main/res/edje/pv-normal-main.edc @@ -927,6 +927,30 @@ collections { } /*subtitle area*/ + part { name: "pv.normal.subtitle.left.padding"; + type: SPACER; + scale: 1; + description {state: "default" 0.0; + min: 76 0; + max: 76 -1; + align: 0.0 0.0; + fixed: 1 0; + rel1 { relative: 0.0 0.0; } + rel2 { to_y: "pv.normal.main.control"; relative: 0.0 0.0; } + } + } + part { name: "pv.normal.subtitle.right.padding"; + type: SPACER; + scale: 1; + description { state: "default" 0.0; + min: 76 0; + max: 76 -1; + fixed: 1 0; + align: 1.0 0.0; + rel1 { relative: 1.0 0.0; } + rel2 { to_y: "pv.normal.main.control"; relative: 1.0 0.0; } + } + } part { name: "pv.normal.main.subtitle"; type: SWALLOW; @@ -935,22 +959,22 @@ collections { state: "default" 0.0; visible: 0; align: 0.5 1.0; - fixed: 1 1; - rel1 { relative: 0.1 0.0; } - rel2 { relative: 0.9 0.0; to_y: "pv.normal.main.control";} + fixed: 1 0; + rel1 { relative: 1.0 0.0; to_x: "pv.normal.subtitle.left.padding"; } + rel2 { relative: 0.0 0.0; to_x: "pv.normal.subtitle.right.padding"; to_y: "pv.normal.main.control";} } description { state: "portrait.show" 0.0; inherit: "default" 0.0; - rel1 { relative: 0.1 0.0; } - rel2 { relative: 0.9 0.0; to_y: "pv.normal.main.volume.icon";} + rel1 { relative: 1.0 0.0; to_x: "pv.normal.subtitle.left.padding"; } + rel2 { relative: 0.0 0.0; to_x: "pv.normal.subtitle.right.padding"; to_y: "pv.normal.main.control";} visible: 1; } description { state: "landscape.show" 0.0; inherit: "default" 0.0; - rel1 { relative: 0.1 0.0; } - rel2 { relative: 0.9 0.0; to_y: "pv.normal.main.volume.icon";} + rel1 { relative: 1.0 0.0; to_x: "pv.normal.subtitle.left.padding"; } + rel2 { relative: 0.0 0.0; to_x: "pv.normal.subtitle.right.padding"; to_y: "pv.normal.main.control";} visible: 1; } } diff --git a/vp-main/res/edje/pv-subtitle.edc b/vp-main/res/edje/pv-subtitle.edc index 4b31adc..84a7e3b 100755 --- a/vp-main/res/edje/pv-subtitle.edc +++ b/vp-main/res/edje/pv-subtitle.edc @@ -15,6 +15,7 @@ */ #include "pv-image.edc" +#include "custom/pv-custom-define.edc" #define FONT_COLOR 255 255 255 255 #define _SCREEN_SIZE_PROTRAIT_ 480 750 @@ -22,11 +23,11 @@ #define SUBTITLE_K_FEATURE collections { - base_scale: 1.8; + base_scale: CURRENT_BASE_SCALE; styles { style { name: "textblock_style_small"; - base: "font=Tizen:style=Roman font_size=28 color=#fff align=center wrap=word"; + base: "font=font=Tizen:weight=Regular:width=BreezeSans font_size=28 color=#fff align=center wrap=word"; tag: "br" "\n"; tag: "ps" "ps"; tag: "hilight" "+ font=Tizen:style=Roman"; @@ -35,7 +36,7 @@ collections { } style { name: "textblock_style_medium"; - base: "font=Tizen:style=Roman font_size=42 color=#fff align=center wrap=word"; + base: "font=font=Tizen:weight=Regular:width=BreezeSans font_size=42 color=#fff align=center wrap=word"; tag: "br" "\n"; tag: "ps" "ps"; tag: "hilight" "+ font=Tizen:style=Roman"; @@ -45,7 +46,7 @@ collections { style { name: "textblock_style_large"; - base: "font=Tizen:style=Roman font_size=54 color=#fff align=center wrap=word"; + base: "font=font=Tizen:weight=Regular:width=BreezeSans font_size=54 color=#fff align=center wrap=word"; tag: "br" "\n"; tag: "ps" "ps"; tag: "hilight" "+ font=Tizen:style=Roman"; @@ -54,10 +55,10 @@ collections { } style { name: "textblock_style_default"; - base: "font=Tizen:style=Roman align=center wrap=word"; + base: "font=font=Tizen:weight=Regular:width=BreezeSans align=center wrap=word"; tag: "br" "\n"; tag: "ps" "ps"; - tag: "hilight" "+ font=Tizen:style=Roman"; + tag: "hilight" "+ font=Tizen:weight=Regular:width=BreezeSans"; tag: "b" "+ font=Tizen:style=Roman"; tag: "tab" "\t"; } @@ -264,7 +265,7 @@ collections { scale: 1; description { state: "default" 0.0; - min: 0 25; + min: 0 12; fixed: 0 1; align: 0.5 1.0; rel1 { relative: 0.0 1.0;} diff --git a/vp-main/res/po/en.po b/vp-main/res/po/en.po index 624d60d..44ab31f 100755 --- a/vp-main/res/po/en.po +++ b/vp-main/res/po/en.po @@ -242,7 +242,7 @@ msgid "IDS_VPL_BODY_PD_SECS" msgstr "%d secs" msgid "IDS_VPL_BODY_OFF" -msgstr "Off" +msgstr "None" msgid "IDS_VPL_BODY_NO_TITLE" msgstr "No title" diff --git a/vp-main/res/po/en_PH.po b/vp-main/res/po/en_PH.po index 1983217..9c916c8 100755 --- a/vp-main/res/po/en_PH.po +++ b/vp-main/res/po/en_PH.po @@ -242,7 +242,7 @@ msgid "IDS_VPL_BODY_PD_SECS" msgstr "%d secs" msgid "IDS_VPL_BODY_OFF" -msgstr "Off" +msgstr "None" msgid "IDS_VPL_BODY_NO_TITLE" msgstr "No title" diff --git a/vp-main/res/po/en_US.po b/vp-main/res/po/en_US.po index 06aec16..953bd87 100755 --- a/vp-main/res/po/en_US.po +++ b/vp-main/res/po/en_US.po @@ -242,7 +242,7 @@ msgid "IDS_VPL_BODY_PD_SECS" msgstr "%d sec" msgid "IDS_VPL_BODY_OFF" -msgstr "Off" +msgstr "None" msgid "IDS_VPL_BODY_NO_TITLE" msgstr "No title" diff --git a/vp-main/src/vp-main.c b/vp-main/src/vp-main.c index dbd65f3..efe5d1c 100755 --- a/vp-main/src/vp-main.c +++ b/vp-main/src/vp-main.c @@ -57,6 +57,8 @@ static bool __appCreate(void *pUserData) { VideoLogWarning("== APP CREATE =="); + elm_app_base_scale_set(1.8); + if (pUserData == NULL) { VideoLogError("[ERR] No exist pUserData."); return FALSE; |