From 49d48d91bbde23596f2016d3a6cac6e330243e0e Mon Sep 17 00:00:00 2001 From: Jisung Ahn Date: Mon, 10 Dec 2012 10:23:30 +0900 Subject: [PATCH] remove 3d dali Change-Id: Iddfe6bac5063ee374a8d639d0573c3d8d3a1b1d4 --- CMakeLists.txt | 0 common/include/ivug-config.h | 6 - common/src/ivug-config.c | 24 --- main/src/view/ivug-main-view.cpp | 32 +-- packaging/ug-image-viewer-efl.spec | 3 - slideshow/CMakeLists.txt | 16 -- slideshow/include/ivug-slideshow.h | 3 - slideshow/src/control/ivug-dali-util.cpp | 314 ---------------------------- slideshow/src/control/ivug-dali-util.h | 24 --- slideshow/src/control/ivug-slideshow.cpp | 118 ++++------- slideshow/src/effect/include/ivug-effect.h | 6 - slideshow/src/include/ivug-slideshow-priv.h | 16 +- widget/CMakeLists.txt | 0 13 files changed, 50 insertions(+), 512 deletions(-) mode change 100755 => 100644 CMakeLists.txt mode change 100755 => 100644 widget/CMakeLists.txt diff --git a/CMakeLists.txt b/CMakeLists.txt old mode 100755 new mode 100644 diff --git a/common/include/ivug-config.h b/common/include/ivug-config.h index 210e3b4..b6b978d 100644 --- a/common/include/ivug-config.h +++ b/common/include/ivug-config.h @@ -34,14 +34,8 @@ typedef enum { IVUG_EFFECT_TYPE_IRIS= 0x00, IVUG_EFFECT_TYPE_DISSOLVE, IVUG_EFFECT_TYPE_SLIDE, - IVUG_EFFECT_TYPE_RIPPLE_FADE, IVUG_EFFECT_TYPE_DISSOLVE_FADE, - IVUG_EFFECT_TYPE_SWIRL, - IVUG_EFFECT_TYPE_WATER_RIPPLE, - IVUG_EFFECT_TYPE_ZOOM, IVUG_EFFECT_TYPE_SPLIT, - IVUG_EFFECT_TYPE_3D_RAND, - IVUG_EFFECT_TYPE_FACE, IVUG_EFFECT_TYPE_MAX, } ivug_effect_type; diff --git a/common/src/ivug-config.c b/common/src/ivug-config.c index 9482a7a..eaa4645 100644 --- a/common/src/ivug-config.c +++ b/common/src/ivug-config.c @@ -190,38 +190,14 @@ _ivug_config_get_effect_type_by_string(char *effect_str) { type = IVUG_EFFECT_TYPE_DISSOLVE; } - else if(!strncmp(effect_str, "RippleFade", strlen(effect_str))) - { - type = IVUG_EFFECT_TYPE_RIPPLE_FADE; - } else if(!strncmp(effect_str, "DissolveFade", strlen(effect_str))) { type = IVUG_EFFECT_TYPE_DISSOLVE_FADE; } - else if(!strncmp(effect_str, "Swirl", strlen(effect_str))) - { - type = IVUG_EFFECT_TYPE_SWIRL; - } - else if(!strncmp(effect_str, "WaterRipple", strlen(effect_str))) - { - type = IVUG_EFFECT_TYPE_WATER_RIPPLE; - } - else if(!strncmp(effect_str, "Zoom", strlen(effect_str))) - { - type = IVUG_EFFECT_TYPE_ZOOM; - } else if(!strncmp(effect_str, "Split", strlen(effect_str))) { type = IVUG_EFFECT_TYPE_SPLIT; } - else if(!strncmp(effect_str, "3DRand", strlen(effect_str))) - { - type = IVUG_EFFECT_TYPE_3D_RAND; - } - else if(!strncmp(effect_str, "Face slide show", strlen(effect_str))) - { - type = IVUG_EFFECT_TYPE_FACE; - } else //Set all other cases as default NONE { MSG_SLIDER_WARN("Invalid type : %s", effect_str); diff --git a/main/src/view/ivug-main-view.cpp b/main/src/view/ivug-main-view.cpp index cec5301..b523831 100644 --- a/main/src/view/ivug-main-view.cpp +++ b/main/src/view/ivug-main-view.cpp @@ -1052,11 +1052,9 @@ _on_slideshow_finished(void *data, Evas_Object *obj, void *event_info) } Media_Item * item = NULL; - bool bDali_slideshow = false; if(pMainView->ssHandle) { - bDali_slideshow = ivug_ss_is_dali(pMainView->ssHandle); item = ivug_ss_item_get(pMainView->ssHandle); ivug_ss_delete(pMainView->ssHandle); @@ -1068,24 +1066,7 @@ _on_slideshow_finished(void *data, Evas_Object *obj, void *event_info) ivug_slider_load(pMainView->slider); - - if (bDali_slideshow) // Why?? - { -#ifdef HIDE_INDICATOR - elm_win_indicator_mode_set(ug_get_window(), ELM_WIN_INDICATOR_HIDE); -#else - if(gIsDesktopMode() == false) - { - elm_win_indicator_mode_set((Evas_Object *)ug_get_window(), ELM_WIN_INDICATOR_SHOW); - } -#endif - ivug_main_view_set_hide_timer(pMainView); - _update_main_view(pMainView); - } - else - { - ivug_main_view_show_menu_bar(pMainView); - } + ivug_main_view_show_menu_bar(pMainView); } Ivug_MainView * @@ -1312,15 +1293,8 @@ void ivug_main_view_start_slideshow(Ivug_MainView *pMainView, Eina_Bool bSlideFi // Register callback evas_object_smart_callback_add(ivug_ss_object_get(pMainView->ssHandle), "slideshow,finished", _on_slideshow_finished, pMainView); - if (ivug_ss_is_dali(pMainView->ssHandle) == true ) - { - ivug_main_view_del_hide_timer(pMainView); - elm_win_indicator_mode_set((Evas_Object *)ug_get_window(), ELM_WIN_INDICATOR_HIDE); - } - else - { - ivug_main_view_hide_menu_bar(pMainView); - } + ivug_main_view_hide_menu_bar(pMainView); + ivug_ss_start(pMainView->ssHandle, current, pMainView->mList, bSlideFirst); } diff --git a/packaging/ug-image-viewer-efl.spec b/packaging/ug-image-viewer-efl.spec index ba6e34a..1b40e5a 100644 --- a/packaging/ug-image-viewer-efl.spec +++ b/packaging/ug-image-viewer-efl.spec @@ -37,9 +37,6 @@ BuildRequires: pkgconfig(dlog) BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(xext) BuildRequires: pkgconfig(xcomposite) -BuildRequires: pkgconfig(dali) -BuildRequires: pkgconfig(dali-core) -BuildRequires: pkgconfig(dali-toolkit) BuildRequires: pkgconfig(liballshare) BuildRequires: pkgconfig(liballshare-core) BuildRequires: pkgconfig(shortcut) diff --git a/slideshow/CMakeLists.txt b/slideshow/CMakeLists.txt index e98bae4..57e3037 100644 --- a/slideshow/CMakeLists.txt +++ b/slideshow/CMakeLists.txt @@ -17,18 +17,6 @@ SET(SRCS src/effect/ivug-effect.c src/effect/ivug-slide.c src/effect/ivug-anim.c - - src/dali_effect/src/ivug-includes.cpp - src/dali_effect/src/ivug-app-navigation.cpp - src/dali_effect/src/ivug-dali-imageview.cpp - src/dali_effect/src/ivug-image-view.cpp - src/dali_effect/src/ivug-dali.cpp - src/dali_effect/src/ivug-slideshow-control.cpp - src/dali_effect/src/ivug-slideshow-effect.cpp - src/dali_effect/src/ivug-dali-slideshow-view.cpp - src/dali_effect/src/ivug-view-stack-info.cpp - src/dali_effect/src/ivug-slideshow-face.cpp - src/dali_effect/src/ivug-water-ripple-effect.cpp ) @@ -42,7 +30,6 @@ INCLUDE_DIRECTORIES( src/include src/control src/effect/include - src/dali_effect/include ) INCLUDE(FindPkgConfig) @@ -60,9 +47,6 @@ pkg_check_modules(${PROJECT_NAME}_pkgs REQUIRED libweb-media vconf ui-gadget-1 - dali - dali-core - dali-toolkit liballshare liballshare-core libface-svc diff --git a/slideshow/include/ivug-slideshow.h b/slideshow/include/ivug-slideshow.h index aba6b81..85e735e 100644 --- a/slideshow/include/ivug-slideshow.h +++ b/slideshow/include/ivug-slideshow.h @@ -79,9 +79,6 @@ ivug_ss_get_next_item(Media_List *mList, Media_Item *current, slide_show_mode mode); - -bool ivug_ss_is_dali(SlideShow *pSlideShow); - void ivug_ss_set_stop(SlideShow *pSlideShow); // Remove this!!! diff --git a/slideshow/src/control/ivug-dali-util.cpp b/slideshow/src/control/ivug-dali-util.cpp index e8d3bfb..78e5e0f 100644 --- a/slideshow/src/control/ivug-dali-util.cpp +++ b/slideshow/src/control/ivug-dali-util.cpp @@ -19,273 +19,11 @@ #include #include #include -#include "ivug-dali.h" #include "ivug-dali-util.h" #include "ivug-debug.h" #include "ivug-file-info.h" -#include "ivug-slideshow-control.h" #include "ivug-slideshow-priv.h" -using namespace Imageview3D; - -typedef struct -{ - int face_rect_x; - int face_rect_y; - int face_rect_w; - int face_rect_h; - char *media_id; -} face_data_s; -#if 0 -static void resume_view_transition_Timer(SlideShow *ss_handle) -{ - IVUG_FUNC_ENTER(); - if (NULL == ss_handle) { - return; - } - if(ss_handle->dali_viewer_handle) { - Imageviewer *iv_handle = (Imageviewer *)ss_handle->dali_viewer_handle; - iv_handle->ResumeViewAndTransitionTimer(); - } - IVUG_FUNC_LEAVE(); -} -#endif -static void _ivug_free_face_records_list(GList *pFaceList) -{ - int i = 0; - ivug_ret_if(NULL == pFaceList); - int length = g_list_length(pFaceList); - for (i = 0; i < length; i++) { - face_data_s *item = (face_data_s *)g_list_nth_data(pFaceList, i); - if (item && item->media_id) { - free(item->media_id); - item->media_id = NULL; - } - if (item) { - free(item); - item = NULL; - } - } - if (pFaceList) { - g_list_free(pFaceList); - pFaceList = NULL; - } -} - -void ivug_dali_destroy_dali_data(SlideShow *ss_handle) -{ - ivug_ret_if(NULL == ss_handle); - SlideShow *slide_show = ss_handle; - - MSG_IVUG_HIGH("start"); - - if (ss_handle->adaptor) { - if (ss_handle->xwin) { - ecore_x_window_lower(ss_handle->xwin); - ecore_x_window_free(ss_handle->xwin); - } - ss_handle->adaptor->Stop(); - } - - //elm_win_indicator_mode_set((Evas_Object *)ug_get_window(), ELM_WIN_INDICATOR_SHOW); - - if(slide_show->dali_viewer_handle) { - Imageviewer *iv_handle = (Imageviewer *)ss_handle->dali_viewer_handle; - //slide show don't remove again,stage auto remove it. - //iv_handle->RemoveFromLayerMain(); - //viewerHandle->GetAppNavigation().NavigateBack(); - if (iv_handle) { - delete iv_handle; - iv_handle = NULL; - } - slide_show->dali_viewer_handle = NULL; - } - if (slide_show->face_record_list) { - _ivug_free_face_records_list(slide_show->face_record_list); - slide_show->face_record_list = NULL; - } - if (slide_show->adaptor) { - delete slide_show->adaptor; - slide_show->adaptor = NULL; - MSG_IVUG_HIGH("adaptor have been release!"); - } - slide_show->cur_item = NULL; - MSG_IVUG_HIGH("end"); -} - -static bool _ivug_append_face_records(face_svc_h handle, void *user_data) -{ - char *media_id = NULL; - int field_val = -1; - - ivug_retv_if(NULL == user_data, false); - SlideShow* ss_handle = (SlideShow*)user_data; - - //GList *face_record_glist = *((GList **)(user_data)); - face_data_s *face_data = (face_data_s *)calloc(1, sizeof(face_data_s)); - - face_svc_get_media_id(handle, &media_id); - //MSG_NOTI_HIGH("[media_id : %s]\n", media_id); - face_data->media_id = g_strdup(media_id); - face_svc_get_face_rect_x(handle, &field_val); - //MSG_NOTI_HIGH("[rect_x : %d]\n", field_val); - face_data->face_rect_x = field_val; - face_svc_get_face_rect_y(handle, &field_val); - //MSG_NOTI_HIGH("[rect_y : %d]\n", field_val); - face_data->face_rect_y = field_val; - face_svc_get_face_rect_w(handle, &field_val); - //MSG_NOTI_HIGH("[rect_w : %d]\n", field_val); - face_data->face_rect_w = field_val; - face_svc_get_face_rect_h(handle, &field_val); - //MSG_NOTI_HIGH("[rect_h : %d]\n", field_val); - face_data->face_rect_h = field_val; - - /* append to list */ - ss_handle->face_record_list = g_list_append(ss_handle->face_record_list, face_data); - int face_cnt = g_list_length(ss_handle->face_record_list); - MSG_IVUG_HIGH("face_cnt is %d\n", face_cnt); - return true; -} - -int ivug_get_face_cnt(const char *media_id, SlideShow* ss_handle) -{ - IVUG_FUNC_ENTER(); - - if (NULL == ss_handle) { - return 0; - } - if (NULL != ss_handle->face_record_list) { - _ivug_free_face_records_list(ss_handle->face_record_list); - ss_handle->face_record_list = NULL; - } - face_svc_foreach_face_list_by_media_id(_ivug_append_face_records, media_id, - (void *)ss_handle); - int face_cnt = g_list_length(ss_handle->face_record_list); - if(face_cnt <= 0) { - face_cnt = 0; - } - MSG_IVUG_HIGH("ivug_get_face_cnt is %d\n", face_cnt); - IVUG_FUNC_LEAVE(); - return face_cnt; -} - -bool ivug_get_nth_face_data(SlideShow* ss_handle, - int record_index, - int *rect_pos_x, - int *rect_pos_y, - int *rect_w, - int *rect_h) -{ - ivug_retv_if(NULL == ss_handle, false); - ivug_retv_if(NULL == ss_handle->face_record_list, false); - face_data_s *record = (face_data_s *)g_list_nth_data(ss_handle->face_record_list, - record_index); - if(record) { - *rect_pos_x = record->face_rect_x; - //MSG_NOTI_HIGH("[rect_x : %d]\n", *rect_pos_x); - *rect_pos_y = record->face_rect_y; - //MSG_NOTI_HIGH("[rect_y : %d]\n", *rect_pos_y); - *rect_w = record->face_rect_w; - //MSG_NOTI_HIGH("[rect_y : %d]\n", *rect_pos_y); - *rect_h = record->face_rect_h; - //MSG_NOTI_HIGH("[rect_y : %d]\n", *rect_pos_y); - return true; - } else { - return false; - } -} - -void ivug_get_image_resolution(const char *file_path, - int *pwidth, - int *pheight) -{ - int width = 0; - int height = 0; - if (NULL != file_path) { - ivug_fileinfo_get_image_resolution(file_path, &width, &height); - } - *pwidth = width; - *pheight = height; -} - -void ivug_get_screen_size(int *width, int *height) -{ - int rotation = elm_win_rotation_get((Evas_Object *)ug_get_window()); - - int screen_w = 0; - int screen_h = 0; - ecore_x_window_size_get(ecore_x_window_root_first_get(), &screen_w, &screen_h); - if(rotation == 0 || rotation == 180) - { - *width = screen_w; - *height = screen_h; - } - else if(rotation == 90 || rotation == 270) - { - *width = screen_h; - *height = screen_w; - } - -} - -int ivug_get_win_rotation() -{ - int rotation = elm_win_rotation_get((Evas_Object *)ug_get_window()); - return rotation; -} - -void ivug_ss_set_mouse_tag(bool tag, SlideShow* ss_handle) -{ - if (NULL != ss_handle){ - ss_handle->bMouse_event = tag; - } -} - -bool ivug_ss_get_mouse_tag(SlideShow* ss_handle) -{ - bool tag = false; - if (NULL != ss_handle){ - tag = ss_handle->bMouse_event; - } - return tag; -} - -Media_Item *ivug_ss_dali_get_next_item(Media_Item *current, - SlideShow *ss_handle) -{ - if ((!ss_handle) || (!ss_handle->media_list)){ - return NULL; - } - Media_Item *next = NULL; - if (NULL == current) { - next = ss_handle->ss_Header; - - } else { - next = ivug_ss_get_next_item(ss_handle->media_list, - ss_handle->ss_Header, - current, - ss_handle->ss_mode); - } - return next; -} - -void ivug_ss_dali_set_current_item(Media_Item *current, - SlideShow *ss_handle) -{ - if (!ss_handle){ - return; - } - ss_handle->cur_item = current; -} - -Media_Item *ivug_ss_dali_get_current_item(SlideShow *ss_handle) -{ - if (!ss_handle){ - return NULL; - } - return ss_handle->cur_item; -} - bool ivug_ss_create_player_handle(SlideShow *ss_handle) { MSG_IVUG_HIGH(""); @@ -361,28 +99,6 @@ bool ivug_ss_init_player(const char *path, SlideShow *ss_handle, bool bVideo) MSG_IVUG_HIGH ("player_set_looping error"); } } - if (bVideo) { - player_display_mode_e mode = PLAYER_DISPLAY_MODE_FULL_SCREEN; - result = player_set_display_mode(ss_handle->vmpHandle, mode); - if (result != PLAYER_ERROR_NONE) { - MSG_IVUG_HIGH ("player_set_display_mode error"); - } - result = player_set_display(ss_handle->vmpHandle, PLAYER_DISPLAY_TYPE_X11, - (void*)ss_handle->xPixmapId); - if(result != PLAYER_ERROR_NONE) - { - MSG_IVUG_HIGH("player_set_display error"); - return false; - } - result = player_enable_evas_display_scaling(ss_handle->vmpHandle, true); - if (result != PLAYER_ERROR_NONE) { - MSG_IVUG_HIGH ("player_enable_evas_display_scaling error"); - } - result = player_set_x11_display_visible(ss_handle->vmpHandle, true); - if (result != PLAYER_ERROR_NONE) { - MSG_IVUG_HIGH ("player_set_x11_display_visible error"); - } - } if (player_prepare(ss_handle->vmpHandle) != PLAYER_ERROR_NONE) { MSG_IVUG_HIGH ("realize is failed"); return false; @@ -458,33 +174,3 @@ bool ivug_ss_get_player_attribute(SlideShow *ss_handle, return true; } -static void _video_msg_callback(void *pUserData) -{ - if(pUserData) - { - SlideshowControl* ssc = (SlideshowControl *)pUserData; - ssc->EndVideoPlay(); - MSG_IVUG_HIGH ("********end video stream*******"); - - } -} - -bool ivug_ss_player_message_callback(SlideShow *ss_handle, - void *data) -{ - bool bSucess = true; - int result = PLAYER_ERROR_NONE; - MSG_IVUG_HIGH ("******ivug_ss_player_message_callback******"); - if (ss_handle && ss_handle->vmpHandle) { - result = player_set_completed_cb( - ss_handle->vmpHandle, _video_msg_callback, (void*)data); - if (result != PLAYER_ERROR_NONE) { - bSucess = false; - } - } else { - bSucess = false; - } - return bSucess; -} - - diff --git a/slideshow/src/control/ivug-dali-util.h b/slideshow/src/control/ivug-dali-util.h index 6c8ec87..e40a74b 100644 --- a/slideshow/src/control/ivug-dali-util.h +++ b/slideshow/src/control/ivug-dali-util.h @@ -33,28 +33,6 @@ typedef enum _ivug_dali_changeview_id { GL_DALI_CHANGE_SLIDESHOW_TO_SLIDE, } ivug_dali_changeview_id; -int ivug_get_face_cnt(const char *media_id, SlideShow *ss_handle); -/* get pos and size of nth face rect from GList */ -bool ivug_get_nth_face_data(SlideShow *ss_handle, - int record_index, - int *rect_pos_x, - int *rect_pos_y, - int *rect_w, - int *rect_h); -void ivug_get_image_resolution(const char *file_path, - int *pwidth, - int *pheight); -void ivug_dali_destroy_dali_data(SlideShow *ss_handle); - -void ivug_get_screen_size(int *screen_w, int *screen_h); -/* get windown rotation degree */ -int ivug_get_win_rotation(); -void ivug_ss_set_mouse_tag(bool tag, SlideShow *ss_handle); -bool ivug_ss_get_mouse_tag(SlideShow *ss_handle); -Media_Item *ivug_ss_dali_get_next_item(Media_Item *current, - SlideShow *ss_handle); -void ivug_ss_dali_set_current_item(Media_Item *current, SlideShow *ss_handle); - bool ivug_ss_create_player_handle(SlideShow *ss_handle); bool ivug_ss_destory_player_handle(SlideShow *ss_handle); bool ivug_ss_init_player(const char *path, SlideShow *ss_handle, bool bVideo); @@ -63,8 +41,6 @@ bool ivug_ss_stop_player(SlideShow *ss_handle); bool ivug_ss_pause_player(SlideShow* ss_handle); bool ivug_ss_get_player_attribute(SlideShow *ss_handle, int *width, int *height); -bool ivug_ss_player_message_callback(SlideShow *ss_handle, - void *data); #endif diff --git a/slideshow/src/control/ivug-slideshow.cpp b/slideshow/src/control/ivug-slideshow.cpp index 279cdd8..dffb4d1 100644 --- a/slideshow/src/control/ivug-slideshow.cpp +++ b/slideshow/src/control/ivug-slideshow.cpp @@ -18,7 +18,6 @@ #include #include "ivug-anim.h" #include "ivug-slideshow.h" -#include "ivug-dali.h" #include "ivug-slideshow-priv.h" #include "ivug-dali-util.h" @@ -33,7 +32,6 @@ #include "ivug-image.h" - #include #include @@ -43,6 +41,8 @@ #undef USE_IVUG_IMAGE +#define USE_IVUG_PHOTO + #undef LOG_LVL #define LOG_LVL DBG_MSG_LVL_MED @@ -196,7 +196,6 @@ _hidden1(void *data, Evas *evas, Evas_Object *obj, void *event_info) MSG_HIGH("%s is Hidden", evas_object_name_get(obj)); } - static bool _ivug_ss_set_content(Slide_Layout *pSlide, Media_Item *item) { Media_Data *mdata; @@ -226,7 +225,13 @@ static bool _ivug_ss_set_content(Slide_Layout *pSlide, Media_Item *item) #ifdef USE_IVUG_IMAGE ret = ivug_image_file_set(pSlide->photocam, mdata->thumbnail_path, NULL); #else - ret = elm_photocam_file_set(pSlide->photocam, mdata->thumbnail_path); + #ifdef USE_IVUG_PHOTO + ret = elm_photo_file_set(pSlide->photocam, mdata->thumbnail_path); + + #else + ret = elm_photocam_file_set(pSlide->photocam, mdata->thumbnail_path); + #endif + #endif if(EVAS_LOAD_ERROR_NONE != ret) { MSG_HIGH("elm_photocam_file_set failed"); @@ -242,7 +247,12 @@ static bool _ivug_ss_set_content(Slide_Layout *pSlide, Media_Item *item) #ifdef USE_IVUG_IMAGE ret = ivug_image_file_set(pSlide->photocam, mdata->filepath, NULL); #else + #ifdef USE_IVUG_PHOTO + ret = elm_photo_file_set(pSlide->photocam, mdata->filepath); + + #else ret = elm_photocam_file_set(pSlide->photocam, mdata->filepath); + #endif #endif if(EVAS_LOAD_ERROR_NONE != ret) { MSG_HIGH("elm_photocam_file_set failed"); @@ -263,7 +273,14 @@ static bool _ivug_ss_set_content(Slide_Layout *pSlide, Media_Item *item) elm_photocam_paused_set(pSlide->photocam, true); evas_object_size_hint_weight_set(pSlide->photocam, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); - + /* use for test + int w_p = 0; + int h_p = 0; + float ff = elm_photocam_zoom_get(pSlide->photocam); + char * cc = (char *)elm_photocam_file_get(pSlide->photocam); + elm_photocam_image_size_get(pSlide->photocam, &w_p, &h_p); + MSG_IVUG_HIGH("photocam_zoom:%f, %s ,%d,%d", ff,cc, w_p, h_p); + */ return true; } @@ -460,24 +477,13 @@ static Effect_Type _ivug_ss_get_trans_effect(ivug_effect_type type) return EFFECT_IRIS; case IVUG_EFFECT_TYPE_DISSOLVE: return EFFECT_DISSOLVE; - case IVUG_EFFECT_TYPE_RIPPLE_FADE: - return EFFECT_RIPPLE_FADE; case IVUG_EFFECT_TYPE_DISSOLVE_FADE: return EFFECT_DISSOLVE_FADE; - case IVUG_EFFECT_TYPE_SWIRL: - return EFFECT_SWIRL; - case IVUG_EFFECT_TYPE_WATER_RIPPLE: - return EFFECT_WATER_RIPPLE; - case IVUG_EFFECT_TYPE_ZOOM: - return EFFECT_ZOOM; case IVUG_EFFECT_TYPE_SPLIT: return EFFECT_SPLIT; - case IVUG_EFFECT_TYPE_3D_RAND: - return EFFECT_3D_RAND; - case IVUG_EFFECT_TYPE_FACE: - return EFFECT_FACE; default: - break; + return EFFECT_SLIDE; + //break; } return EFFECT_NONE; } @@ -624,10 +630,17 @@ static bool _ivug_ss_create_image_layout(Evas_Object *parent, Slide_Layout *sLay MSG_ERROR("Cannot create current layout"); return false; } + #ifdef USE_IVUG_IMAGE sLayout->photocam = ivug_image_create(sLayout->layout); #else + + #ifdef USE_IVUG_PHOTO + sLayout->photocam = elm_photo_add(sLayout->layout); + #else sLayout->photocam = elm_photocam_add(sLayout->layout); + #endif + #endif evas_object_size_hint_expand_set(sLayout->photocam, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); evas_object_size_hint_align_set(sLayout->photocam, EVAS_HINT_FILL, EVAS_HINT_FILL); @@ -638,11 +651,15 @@ static bool _ivug_ss_create_image_layout(Evas_Object *parent, Slide_Layout *sLay evas_object_name_set(sLayout->thumbnail, "Thumbnail"); elm_object_part_content_set(sLayout->layout, "thumbnail", sLayout->thumbnail); - #ifdef USE_IVUG_IMAGE #else + #ifdef USE_IVUG_PHOTO + elm_object_style_set(sLayout->photocam, "shadow"); + elm_photo_fill_inside_set(sLayout->photocam, EINA_TRUE); + #else elm_photocam_zoom_mode_set(sLayout->photocam, ELM_PHOTOCAM_ZOOM_MODE_AUTO_FIT); elm_photocam_paused_set(sLayout->photocam, EINA_TRUE); + #endif #endif evas_object_smart_callback_add(sLayout->photocam, @@ -685,16 +702,6 @@ SlideShow *ivug_ss_create(Evas_Object *parent) pSlideShow->effect_type = _ivug_ss_get_trans_effect(ivug_effect); -#ifdef TARGET - pSlideShow->bDali_slideshow = true; -#else - pSlideShow->bDali_slideshow = false; -#endif - if(pSlideShow->bDali_slideshow) { - //ivug_ss_create_player_handle(pSlideShow); - return pSlideShow; - } - pSlideShow->obj = _ivug_ss_create_layout(parent, IVUG_SS_LY_EDJ_PATH, "view.slideshow"); MSG_ASSERT(pSlideShow->obj != NULL); evas_object_name_set(pSlideShow->obj, "slideshow"); @@ -789,18 +796,7 @@ bool ivug_ss_start(SlideShow *pSlideShow , Media_Item *current, Media_List *list pSlideShow->bSS_StopFlag = EINA_FALSE; pSlideShow->ss_Header = current; pSlideShow->media_list = list; - pSlideShow->cur_item = current; - if(pSlideShow->bDali_slideshow) { - pSlideShow->state = SLIDE_SHOW_RUNNING; - pSlideShow->evas_plugin_state = EVASPLUGIN_RESUMED; - if (pSlideShow->vmpHandle) - { - ivug_ss_play_player(pSlideShow); - } - ivug_dali_create_xWin(pSlideShow); - return true; - } MSG_ASSERT(pSlideShow->obj != NULL); pSlideShow->bMouse_event = true; evas_object_move(pSlideShow->obj, 0,0); @@ -956,11 +952,6 @@ Media_Item * ivug_ss_item_get(SlideShow *pSlideShow) { MSG_ASSERT(pSlideShow != NULL); - if ( pSlideShow->bDali_slideshow == true) - { - return pSlideShow->cur_item;; - } - return pSlideShow->sLayout[(pSlideShow->sCurrent) % 2].mitem; } @@ -973,15 +964,9 @@ void ivug_ss_delete(SlideShow *pSlideShow) MSG_ERROR("Already deleted!!"); return; } - if (!pSlideShow->bDali_slideshow) { - evas_object_event_callback_del(pSlideShow->event, EVAS_CALLBACK_MOUSE_DOWN, _ivug_ss_on_mouse_down); - evas_object_event_callback_del(pSlideShow->event, EVAS_CALLBACK_MOUSE_MOVE, _ivug_ss_on_mouse_move); - evas_object_event_callback_del(pSlideShow->event, EVAS_CALLBACK_MOUSE_UP, _ivug_ss_on_mouse_up); - } - else - { - ivug_dali_destroy_dali_data(pSlideShow); - } + evas_object_event_callback_del(pSlideShow->event, EVAS_CALLBACK_MOUSE_DOWN, _ivug_ss_on_mouse_down); + evas_object_event_callback_del(pSlideShow->event, EVAS_CALLBACK_MOUSE_MOVE, _ivug_ss_on_mouse_move); + evas_object_event_callback_del(pSlideShow->event, EVAS_CALLBACK_MOUSE_UP, _ivug_ss_on_mouse_up); if (pSlideShow->vmpHandle) { ivug_ss_destory_player_handle(pSlideShow); @@ -1009,6 +994,9 @@ void ivug_ss_delete(SlideShow *pSlideShow) for ( int i = 0 ; i < 2; i++) { if(pSlideShow->sLayout[i].photocam) { + #ifdef USE_IVUG_IMAGE + ivug_image_unset(pSlideShow->sLayout[i].photocam); + #endif evas_object_del(pSlideShow->sLayout[i].photocam); pSlideShow->sLayout[i].photocam = NULL; } @@ -1030,6 +1018,7 @@ void ivug_ss_delete(SlideShow *pSlideShow) evas_object_del(pSlideShow->sLayout[i].layout); pSlideShow->sLayout[i].layout = NULL; } + } if ( pSlideShow->event ) @@ -1062,9 +1051,7 @@ void ivug_ss_resize(SlideShow *pSlideShow) if (!pSlideShow) { return; } - if (pSlideShow->bDali_slideshow) { - ivug_imageviewer_init_xWin(pSlideShow, EVASPLUGIN_RESIZED); - } else if((pSlideShow->obj) && (pSlideShow->event)) { + if((pSlideShow->obj) && (pSlideShow->event)) { ivug_ss_get_screen_size(&pSlideShow->screen_w, &pSlideShow->screen_h); evas_object_resize(pSlideShow->obj, pSlideShow->screen_w, pSlideShow->screen_h); Evas_Coord ox, oy, ow, oh; @@ -1086,6 +1073,7 @@ void ivug_ss_resize(SlideShow *pSlideShow) } //MSG_HIGH("_ivug_ss_resize_obj, Moved (%d,%d,%d,%d)", ox, oy, ow, oh); } + IVUG_FUNC_LEAVE(); } @@ -1095,12 +1083,7 @@ Evas_Object *ivug_ss_object_get(SlideShow *pSlideShow) { MSG_ASSERT(pSlideShow != NULL); - if(pSlideShow->bDali_slideshow) { - Evas_Object * main_win = (Evas_Object *)ug_get_window(); - return main_win; - } else { - return pSlideShow->obj; - } + return pSlideShow->obj; } bool ivug_ss_set_music(SlideShow *pSlideShow, const char *path) @@ -1121,14 +1104,6 @@ bool ivug_ss_set_music(SlideShow *pSlideShow, const char *path) return true; } -bool ivug_ss_is_dali(SlideShow *pSlideShow) -{ - MSG_ASSERT(pSlideShow != NULL); - - return pSlideShow->bDali_slideshow; - -} - void ivug_ss_set_stop(SlideShow *pSlideShow) { @@ -1137,4 +1112,3 @@ ivug_ss_set_stop(SlideShow *pSlideShow) pSlideShow->state = SLIDE_SHOW_STOPPED; } - diff --git a/slideshow/src/effect/include/ivug-effect.h b/slideshow/src/effect/include/ivug-effect.h index ad47de8..ef7601e 100644 --- a/slideshow/src/effect/include/ivug-effect.h +++ b/slideshow/src/effect/include/ivug-effect.h @@ -61,14 +61,8 @@ typedef enum _Effect_Type { EFFECT_IRIS, EFFECT_DISSOLVE, EFFECT_SLIDE, - EFFECT_RIPPLE_FADE, EFFECT_DISSOLVE_FADE, - EFFECT_SWIRL, - EFFECT_WATER_RIPPLE, - EFFECT_ZOOM, EFFECT_SPLIT, - EFFECT_3D_RAND, - EFFECT_FACE, EFFECT_MAX } Effect_Type; diff --git a/slideshow/src/include/ivug-slideshow-priv.h b/slideshow/src/include/ivug-slideshow-priv.h index bfd5fca..cd6f270 100644 --- a/slideshow/src/include/ivug-slideshow-priv.h +++ b/slideshow/src/include/ivug-slideshow-priv.h @@ -27,17 +27,12 @@ #include #include #include -#include -#include "ivug-define.h" #include "ivug-medialist.h" #include "ivug-config.h" #include "ivug-effect.h" -#include "ivug-includes.h" - -using namespace Imageview3D; -using namespace std; +//#include "ivug-player.h" #define DATA_PATH DATADIR"/"PACKAGE @@ -82,14 +77,6 @@ typedef struct _SlideShow int screen_h; Ecore_Idler *load_idler; - Ecore_X_Window xwin; - Dali::Window winHandle; /* Handle to window */ - Dali::Adaptor* adaptor; /* DaliAdaptor */ - //RenderSurface* renderSurface; /* RenderSurface */ - Media_Item *cur_item; - GList *face_record_list; - void *dali_viewer_handle; /*3D slidehshow image view handle*/ - int xPixmapId; player_h vmpHandle; /*Used for video and music*/ Slide_Layout sLayout[2]; @@ -100,7 +87,6 @@ typedef struct _SlideShow slideshow_state_t state; Eina_Bool bSS_StopFlag; /* request slide show stop flag */ bool bMouse_event; - bool bDali_slideshow; bool bMusicState; }SlideShow; diff --git a/widget/CMakeLists.txt b/widget/CMakeLists.txt old mode 100755 new mode 100644 -- 2.7.4