summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rwxr-xr-xinclude/sg-debug.h212
-rwxr-xr-xinclude/sg-keys.h145
-rwxr-xr-xinclude/ug-setting-gallery.h227
3 files changed, 289 insertions, 295 deletions
diff --git a/include/sg-debug.h b/include/sg-debug.h
index c00d329..a71e708 100755
--- a/include/sg-debug.h
+++ b/include/sg-debug.h
@@ -1,106 +1,106 @@
-/*
- * Copyright 2012 Samsung Electronics Co., Ltd
- *
- * Licensed under the Flora License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.tizenopensource.org/license
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __gallery_debug_H__
-#define __gallery_debug_H__
-
-#define ENABLE_LOG_SYSTEM
-
-#ifdef ENABLE_LOG_SYSTEM
-#define USE_DLOG_SYSTEM
-
-#ifdef USE_DLOG_SYSTEM
-#include <dlog.h>
-
-#ifdef LOG_TAG
-#undef LOG_TAG
-#endif
-
-#define LOG_TAG "gallery-setting"
-
-#define gallery_debug(fmt, arg...) do{ \
- LOGD("[%s :%05d] "fmt "\n",__FUNCTION__, __LINE__,##arg); \
- } while (0)
-#define gallery_info(fmt, arg...) do{ \
- LOGI("[%s :%05d] "fmt "\n",__FUNCTION__, __LINE__,##arg); \
- } while (0)
-#define gallery_warn(fmt, arg...) do{ \
- LOGW("[%s :%05d] "fmt "\n",__FUNCTION__, __LINE__,##arg); \
- } while (0)
-#define gallery_error(fmt, arg...) do{ \
- LOGE("[%s :%05d] "fmt "\n",__FUNCTION__, __LINE__,##arg); \
- } while (0)
-
-#define gallery_func_enter() LOGD( "[%s: %05d] <<<< enter \n", __func__, __LINE__)
-#define gallery_func_leave() LOGD( "[%s: %05d] >>>> leave \n", __func__, __LINE__ )
-
-#else //USE_DLOG_SYSTEM
-#define gallery_debug(fmt, arg...) do { \
- fprintf(stderr,"[%s:%05d] " fmt "\n",__func__, __LINE__, ##arg); \
-} while(0)
-
-#define gallery_info(fmt, arg...) do { \
- fprintf(stderr,"[%s:%05d] " fmt "\n",__func__, __LINE__, ##arg); \
-} while(0)
-
-#define gallery_warn(fmt, arg...) do { \
- fprintf(stderr,"[%s:%05d] " fmt "\n",__func__, __LINE__, ##arg); \
-} while(0)
-
-#define gallery_error(fmt, arg...) do { \
- fprintf(stderr,"[%s:%05d] " fmt "\n",__func__, __LINE__, ##arg); \
-} while(0)
-#define gallery_func_enter() fprintf(stdout, "[%s : %05d] <<< enter \n", __func__, __LINE__ , ##arg)
-#define gallery_func_leave() fprintf(stdout, "[%s : %05d] >>> leave \n", __func__, __LINE__ , ##arg)
-
-#endif // #ifdef USE_DLOG_SYSTEM
-
-#else //ENABLE_LOG_SYSTEM
-#define gallery_debug(fmt, arg...)
-#define gallery_info(fmt, arg...)
-#define gallery_warn(fmt, arg...)
-#define gallery_error(fmt, arg...)
-#endif //ENABLE_LOG_SYSTEM
-
-
-#define gallery_ret_if(expr) do { \
- if(expr) { \
- return; \
- } \
-} while (0)
-#define gallery_retv_if(expr, val) do { \
- if(expr) { \
- return (val); \
- } \
-} while (0)
-
-#define gallery_retm_if(expr, fmt, arg...) do { \
- if(expr) { \
- gallery_warn(fmt, ##arg); \
- return; \
- } \
-} while (0)
-
-#define gallery_retvm_if(expr, val, fmt, arg...) do { \
- if(expr) { \
- gallery_warn(fmt, ##arg); \
- return (val); \
- } \
-} while (0)
-
-
-#endif //__gallery_debug_H__
-
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.tizenopensource.org/license
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __gallery_debug_H__
+#define __gallery_debug_H__
+
+#define ENABLE_LOG_SYSTEM
+
+#ifdef ENABLE_LOG_SYSTEM
+#define USE_DLOG_SYSTEM
+
+#ifdef USE_DLOG_SYSTEM
+#include <dlog.h>
+
+#ifdef LOG_TAG
+#undef LOG_TAG
+#endif
+
+#define LOG_TAG "gallery-setting"
+
+#define gallery_debug(fmt, arg...) do{ \
+ LOGD("[%s :%05d] "fmt "\n",__FUNCTION__, __LINE__,##arg); \
+ } while (0)
+#define gallery_info(fmt, arg...) do{ \
+ LOGI("[%s :%05d] "fmt "\n",__FUNCTION__, __LINE__,##arg); \
+ } while (0)
+#define gallery_warn(fmt, arg...) do{ \
+ LOGW("[%s :%05d] "fmt "\n",__FUNCTION__, __LINE__,##arg); \
+ } while (0)
+#define gallery_error(fmt, arg...) do{ \
+ LOGE("[%s :%05d] "fmt "\n",__FUNCTION__, __LINE__,##arg); \
+ } while (0)
+
+#define gallery_func_enter() LOGD( "[%s: %05d] <<<< enter \n", __func__, __LINE__)
+#define gallery_func_leave() LOGD( "[%s: %05d] >>>> leave \n", __func__, __LINE__ )
+
+#else //USE_DLOG_SYSTEM
+#define gallery_debug(fmt, arg...) do { \
+ fprintf(stderr,"[%s:%05d] " fmt "\n",__func__, __LINE__, ##arg); \
+} while(0)
+
+#define gallery_info(fmt, arg...) do { \
+ fprintf(stderr,"[%s:%05d] " fmt "\n",__func__, __LINE__, ##arg); \
+} while(0)
+
+#define gallery_warn(fmt, arg...) do { \
+ fprintf(stderr,"[%s:%05d] " fmt "\n",__func__, __LINE__, ##arg); \
+} while(0)
+
+#define gallery_error(fmt, arg...) do { \
+ fprintf(stderr,"[%s:%05d] " fmt "\n",__func__, __LINE__, ##arg); \
+} while(0)
+#define gallery_func_enter() fprintf(stdout, "[%s : %05d] <<< enter \n", __func__, __LINE__ , ##arg)
+#define gallery_func_leave() fprintf(stdout, "[%s : %05d] >>> leave \n", __func__, __LINE__ , ##arg)
+
+#endif // #ifdef USE_DLOG_SYSTEM
+
+#else //ENABLE_LOG_SYSTEM
+#define gallery_debug(fmt, arg...)
+#define gallery_info(fmt, arg...)
+#define gallery_warn(fmt, arg...)
+#define gallery_error(fmt, arg...)
+#endif //ENABLE_LOG_SYSTEM
+
+
+#define gallery_ret_if(expr) do { \
+ if(expr) { \
+ return; \
+ } \
+} while (0)
+#define gallery_retv_if(expr, val) do { \
+ if(expr) { \
+ return (val); \
+ } \
+} while (0)
+
+#define gallery_retm_if(expr, fmt, arg...) do { \
+ if(expr) { \
+ gallery_warn(fmt, ##arg); \
+ return; \
+ } \
+} while (0)
+
+#define gallery_retvm_if(expr, val, fmt, arg...) do { \
+ if(expr) { \
+ gallery_warn(fmt, ##arg); \
+ return (val); \
+ } \
+} while (0)
+
+
+#endif //__gallery_debug_H__
+
diff --git a/include/sg-keys.h b/include/sg-keys.h
index d504ee2..e2c4412 100755
--- a/include/sg-keys.h
+++ b/include/sg-keys.h
@@ -1,81 +1,64 @@
-/*
- * Copyright 2012 Samsung Electronics Co., Ltd
- *
- * Licensed under the Flora License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.tizenopensource.org/license
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __GALLERY_KEY_H__
-#define __GALLERY_KEY_H__
-
-#include <Elementary.h>
-
-#include <vconf-keys.h>
-#include <stdbool.h>
-
-
-#define DEFAULT_TIMER (3.0f)
-#define DEFAULT_REPEAT false
-#define DEFAULT_SHUFFLE false
-#define DEFAULT_SUBTITLE false
-#define DEFAULT_EFFECT "Slide"
-
-
-
-#define VCONFKEY_GALLERY_INTERVAL_TIME "db/setting/gallery/interval_time" //int
-
-#define VCONFKEY_GALLERY_REPEAT_STATE "db/setting/gallery/repeat_state" //boolean
-
-#define VCONFKEY_GALLERY_SHUFFLE_STATE "db/setting/gallery/shuffle_state" //boolean
-
-#define VCONFKEY_GALLERY_SUBTITLE_STATE "db/setting/gallery/subtitle_state" //boolean
-
-#define VCONFKEY_GALLERY_TRANSITION_EFFECT "db/setting/gallery/ss_effect" //char
-
-
-//void _gallery_key_set_time_vconf(void *data, Evas_Object *obj, void *event_info);
-
-
-int
-gallery_key_init_current_time(double *val);
-
-int
-gallery_key_init_repeat_state(int *b_val);
-
-int
-gallery_key_init_shuffle_state(int *b_val);
-
-int
-gallery_key_init_subtitle_state(int *b_val);
-
-void
-gallery_key_text_popup(void *data, char *msg);
-
-int
-gallery_key_init_slideshow_effect(void);
-
-char *
-gallery_key_menu_get(int index);
-
-
-double
-gallery_key_get_time_vconf_value(int index);
-
-int gallery_key_reset_current_time(void);
-int gallery_key_reset_repeat_state(void);
-int gallery_key_reset_shuffle_state(void);
-int gallery_key_reset_subtitle_state(void);
-int gallery_key_reset_slideshow_effect(void);
-
-#endif
-
-
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.tizenopensource.org/license
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __GALLERY_KEY_H__
+#define __GALLERY_KEY_H__
+
+#include <Elementary.h>
+
+#include <vconf-keys.h>
+#include <stdbool.h>
+
+#define VCONFKEY_GALLERY_INTERVAL_TIME "db/setting/gallery/interval_time" //int
+
+#define VCONFKEY_GALLERY_REPEAT_STATE "db/setting/gallery/repeat_state" //boolean
+
+#define VCONFKEY_GALLERY_SHUFFLE_STATE "db/setting/gallery/shuffle_state" //boolean
+
+int
+gallery_key_init_current_time(double *val);
+
+int
+gallery_key_init_repeat_state(int *b_val);
+
+int
+gallery_key_init_shuffle_state(int *b_val);
+
+void
+gallery_key_text_popup(void *data, char *msg);
+
+char *
+gallery_key_time_menu_get(int index);
+
+char *
+gallery_key_size_menu_get(int index);
+
+double
+gallery_key_get_time_vconf_value(int index);
+
+char*
+gallery_key_get_size_vconf_value(int index);
+
+int gallery_key_set_current_time(double value);
+int gallery_key_set_repeat_state(bool value);
+int gallery_key_set_shuffle_state(bool value);
+
+int gallery_key_init_inline_video_state(int *b_val);
+int gallery_key_set_inline_video_state(bool value);
+
+#endif
+
+
diff --git a/include/ug-setting-gallery.h b/include/ug-setting-gallery.h
index b74646d..a333d59 100755
--- a/include/ug-setting-gallery.h
+++ b/include/ug-setting-gallery.h
@@ -1,108 +1,119 @@
-/*
- * Copyright 2012 Samsung Electronics Co., Ltd
- *
- * Licensed under the Flora License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.tizenopensource.org/license
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __GALLERY_UG_EFL_H__
-#define __GALLERY_UG_EFL_H__
-
-
-#include <Elementary.h>
-
-#define PKGNAME "ug-setting-gallery-efl"
-
-#define _EDJ(o) elm_layout_edje_get(o)
-//#define N_(s) dgettext_noop(s)
-
-
-/* Original code is in appcore-common.h */
-#define _(str) gettext(str) /**< gettext alias */
-#define gettext_noop(str) (str) /**< keyword for xgettext to extract translatable strings */
-#define N_(str) gettext_noop(str) /**< gettext_noop alias */
-
-#define _SG_GETSYSTEMSTR(ID) dgettext("sys_string", (ID))
-#define _SG_GETLOCALSTR(ID) dgettext("ug-setting-gallery-efl", (ID))
-
-
-#define GALLERY_SUB_TIME_COUNT 5
-#define GALLERY_SUB_EFFECT_COUNT 5
-
-#define SGUG_TR_GALLERY _SG_GETSYSTEMSTR("IDS_COM_BODY_GALLERY")
-
-#define SGUG_TR_SLIDESHOW _SG_GETLOCALSTR("IDS_MEDIABR_OPT_SLIDE_SHOW")
-#define SGUG_TR_PESF _SG_GETLOCALSTR("IDS_MEDIABR_BODY_SLIDESHOW_INTERVAL")
-#define SGUG_TR_REPEAT _SG_GETLOCALSTR("IDS_MEDIABR_BODY_REPEAT")
-#define SGUG_TR_SHUFFLE _SG_GETLOCALSTR("IDS_MEDIABR_BODY_SHUFFLE")
-#define SGUG_TR_SUBTITLE_TITLE _SG_GETSYSTEMSTR("IDS_COM_BODY_VIDEO")
-#define SGUG_TR_SUBTITLE _SG_GETLOCALSTR("IDS_MEDIABR_BODY_SUBTITLES")
-
-#define SGUG_TR_2s _SG_GETLOCALSTR("IDS_MEDIABR_OPT_2_SECONDS")
-#define SGUG_TR_3s _SG_GETLOCALSTR("IDS_MEDIABR_OPT_3_SECONDS")
-#define SGUG_TR_5s _SG_GETLOCALSTR("IDS_MEDIABR_BODY_5_SECONDS")
-#define SGUG_TR_10s _SG_GETLOCALSTR("IDS_MEDIABR_BODY_10_SECONDS")
-#define SGUG_TR_20s _SG_GETLOCALSTR("IDS_MEDIABR_BODY_20_SECONDS")
-#define SGUG_TR_FAILED _("Setting failed, please try again..")
-
-#define VCONFKEY_GALLERY_ITV_TIME_2S (2.0f)
-#define VCONFKEY_GALLERY_ITV_TIME_3S (3.0f)
-#define VCONFKEY_GALLERY_ITV_TIME_5S (5.0f)
-#define VCONFKEY_GALLERY_ITV_TIME_10S (10.0f)
-#define VCONFKEY_GALLERY_ITV_TIME_20S (20.0f)
-
-typedef enum
-{
- GALLERY_MAIN_MENU_TITLE = 0,
- GALLERY_MAIN_MENU_TIME,
- GALLERY_MAIN_MENU_REPEAT,
- GALLERY_MAIN_MENU_SHUFFLE,
- GALLERY_MAIN_MENU_SUBTITLE_TITLE,
- GALLERY_MAIN_MENU_SUBTITLE_ON_OFF,
- GALLERY_MAIN_MENU_ITEM_MAX,
-}gallery_main_menu_item_t;
-
-
-struct ug_data
-{
- Evas_Object *main_layout;
- Evas_Object *bg;
- Evas_Object *naviframe;
- Evas_Object *time_layout;
- Evas_Object *genlist;
- Evas_Object *backbtn;
-
- Evas_Object *repeat_btn;
- Evas_Object *shuffle_btn;
- Evas_Object *subtitle_btn;
- int repeat_state;
- int shuffle_state;
- int subtitle_state;
- Evas_Object *radio_group;
- Evas_Object *effect_radio_group;
- Evas_Object *popup;
- Elm_Object_Item *gl_it[GALLERY_MAIN_MENU_ITEM_MAX];
-
- Elm_Genlist_Item_Class check_time_itc;
- Elm_Genlist_Item_Class expandable_itc;
-
- Elm_Genlist_Item_Class txt_icon_itc;
-
- Elm_Genlist_Item_Class title_itc;
- Elm_Genlist_Item_Class effect_itc;
-
- struct ui_gadget *ug;
-};
-
-
-#endif
-
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.tizenopensource.org/license
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __GALLERY_UG_EFL_H__
+#define __GALLERY_UG_EFL_H__
+
+
+#include <Elementary.h>
+#include <ui-gadget-module.h>
+
+
+#define PKGNAME "ug-setting-gallery-efl"
+
+#define _EDJ(o) elm_layout_edje_get(o)
+
+/* Original code is in appcore-common.h */
+#define _(str) gettext(str) /**< gettext alias */
+#define gettext_noop(str) (str) /**< keyword for xgettext to extract translatable strings */
+#define N_(str) gettext_noop(str) /**< gettext_noop alias */
+
+#define _SG_GETSYSTEMSTR(ID) dgettext("sys_string", (ID))
+#define _SG_GETLOCALSTR(ID) dgettext("ug-setting-gallery-efl", (ID))
+
+#define GALLERY_SUB_TIME_COUNT 5
+#define GALLERY_SUB_EFFECT_COUNT 10//5
+
+#define SGUG_TR_GALLERY _SG_GETSYSTEMSTR("IDS_COM_BODY_GALLERY")
+
+#define SGUG_TR_SLIDESHOW _SG_GETLOCALSTR("IDS_MEDIABR_OPT_SLIDE_SHOW")
+
+#define SGUG_TR_PESF _SG_GETLOCALSTR("IDS_MEDIABR_BODY_SLIDESHOW_INTERVAL")
+#define SGUG_TR_REPEAT _SG_GETLOCALSTR("IDS_MEDIABR_BODY_REPEAT")
+#define SGUG_TR_SHUFFLE _SG_GETLOCALSTR("IDS_MEDIABR_BODY_SHUFFLE")
+
+#define SGUG_TR_2s _SG_GETLOCALSTR("IDS_MEDIABR_OPT_2_SECONDS")
+#define SGUG_TR_3s _SG_GETLOCALSTR("IDS_MEDIABR_OPT_3_SECONDS")
+#define SGUG_TR_5s _SG_GETLOCALSTR("IDS_MEDIABR_BODY_5_SECONDS")
+#define SGUG_TR_10s _SG_GETLOCALSTR("IDS_MEDIABR_BODY_10_SECONDS")
+#define SGUG_TR_20s _SG_GETLOCALSTR("IDS_MEDIABR_BODY_20_SECONDS")
+#define SGUG_TR_FAILED _("Setting failed, please try again..")
+
+#define VCONFKEY_GALLERY_ITV_TIME_2S (2.0f)
+#define VCONFKEY_GALLERY_ITV_TIME_3S (3.0f)
+#define VCONFKEY_GALLERY_ITV_TIME_5S (5.0f)
+#define VCONFKEY_GALLERY_ITV_TIME_10S (10.0f)
+#define VCONFKEY_GALLERY_ITV_TIME_20S (20.0f)
+
+#define DEFAULT_TIMER VCONFKEY_GALLERY_ITV_TIME_3S
+#define DEFAULT_REPEAT false
+#define DEFAULT_SHUFFLE false
+
+#ifdef TARGET
+typedef enum
+{
+ GALLERY_MAIN_MENU_TITLE = 0,
+ GALLERY_MAIN_MENU_TIME,
+ GALLERY_MAIN_MENU_REPEAT,
+ GALLERY_MAIN_MENU_SHUFFLE,
+ GALLERY_MAIN_MENU_ITEM_MAX,
+}gallery_main_menu_item_t;
+#else
+typedef enum
+{
+ GALLERY_MAIN_MENU_TITLE = 0,
+ GALLERY_MAIN_MENU_TIME,
+ GALLERY_MAIN_MENU_REPEAT,
+ GALLERY_MAIN_MENU_SHUFFLE,
+ GALLERY_MAIN_MENU_ITEM_MAX,
+}gallery_main_menu_item_t;
+#endif
+
+struct ug_data
+{
+ Evas_Object *main_layout;
+ Evas_Object *bg;
+ Evas_Object *naviframe;
+ Evas_Object *time_layout;
+ Evas_Object *genlist;
+ Evas_Object *backbtn;
+
+ Evas_Object *repeat_btn;
+ Evas_Object *shuffle_btn;
+ Evas_Object *inline_video_btn;
+ int repeat_state;
+ int shuffle_state;
+ int inline_video_state;
+ Evas_Object *radio_group;
+ Evas_Object *popup;
+ Elm_Object_Item *gl_it[GALLERY_MAIN_MENU_ITEM_MAX];
+
+ Elm_Genlist_Item_Class check_time_itc;
+ Elm_Genlist_Item_Class expandable_itc;
+
+ Elm_Genlist_Item_Class txt_icon_itc;
+
+ Elm_Genlist_Item_Class title_itc;
+
+ Elm_Genlist_Item_Class seperator_itc;
+ Elm_Genlist_Item_Class seperator_end_itc;
+
+ struct ui_gadget *ug;
+};
+
+
+#endif
+