summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiwoong Im <jiwoong.im@samsung.com>2016-06-16 18:43:51 +0900
committerJiwoong Im <jiwoong.im@samsung.com>2016-06-16 19:12:29 +0900
commit64ca55d9ed58e80c353b588ef6ec2c03e56f7d7e (patch)
treefd17475a938127537752f808a0e50ebd2cd42291
parent0c2ea19d230c7e1447ce841b916c2eebaa43ed33 (diff)
downloadui-gadget-1-64ca55d9ed58e80c353b588ef6ec2c03e56f7d7e.tar.gz
ui-gadget-1-64ca55d9ed58e80c353b588ef6ec2c03e56f7d7e.tar.bz2
ui-gadget-1-64ca55d9ed58e80c353b588ef6ec2c03e56f7d7e.zip
fix abi issue
Change-Id: Idc9ca564c61f2f6278c93e950d3163c83391274c Signed-off-by: Jiwoong Im <jiwoong.im@samsung.com>
-rw-r--r--client/ug-client.c2
-rw-r--r--include/ui-gadget.h22
-rw-r--r--src/manager.c19
-rw-r--r--src/ug.c7
4 files changed, 20 insertions, 30 deletions
diff --git a/client/ug-client.c b/client/ug-client.c
index 6b12695..99a5754 100644
--- a/client/ug-client.c
+++ b/client/ug-client.c
@@ -164,7 +164,7 @@ void _ug_client_result_cb(ui_gadget_h ug, app_control_h reply, void *priv)
if (!ug || !priv)
return;
- ret = app_control_get_extra_data(reply, UG_SERVICE_DATA_RESULT, &value);
+ ret = app_control_get_extra_data(reply, UG_APP_CONTROL_DATA_RESULT, &value);
if ((ret == APP_CONTROL_ERROR_NONE) && (value)) {
result = atoi(value);
LOGD("reply result is %d", result);
diff --git a/include/ui-gadget.h b/include/ui-gadget.h
index 9e0f653..6c34b19 100644
--- a/include/ui-gadget.h
+++ b/include/ui-gadget.h
@@ -131,15 +131,17 @@ enum ug_option {
UG_OPT_INDICATOR_MANUAL = 0x04,
/**< Indicator option:
Indicator will be handled manually */
- UG_OPT_OVERLAP_ENABLE = 0x08,
- /**< Overlap option: Enable indicator overlap */
UG_OPT_MAX
};
-#define GET_OPT_INDICATOR_VAL(opt) opt % UG_OPT_OVERLAP_ENABLE
-#define GET_OPT_OVERLAP_VAL(opt) opt & UG_OPT_OVERLAP_ENABLE
-
-#define UG_SERVICE_DATA_RESULT "__UG_SEND_REUSLT__"
+/**
+ * @brief Definition for key string for the extra data of app_control that is used for result state of ui-gadget.
+ * When ug callee (UI gadgets) sends result state using ug_send_result_full(), the ug caller can get the
+ * result state from ug callee in result parameter of the result_cb().
+ *
+ * @since_tizen 2.3
+ */
+#define UG_APP_CONTROL_DATA_RESULT "__UG_SEND_RESULT__"
/**
* UI gadget callback type
@@ -161,11 +163,13 @@ struct ug_cbs {
};
/**
- * Easy-to-use macro of ug_init() for EFL
+ * @brief Definition for easy-to-use api of ug_init() for EFL.
+ *
+ * @since_tizen 2.3
+ *
* @see ug_init()
*/
-#define UG_INIT_EFL(win, opt) \
- ug_init_efl(win, opt)
+int UG_INIT_EFL(void *win, enum ug_option opt);
/**
* Easy-to-use macro of ug_init() for GTK
diff --git a/src/manager.c b/src/manager.c
index 859f360..301f384 100644
--- a/src/manager.c
+++ b/src/manager.c
@@ -390,24 +390,6 @@ static int ugman_ug_resume(void *data)
return 0;
}
-static int ugman_indicator_overlap_update(enum ug_option opt)
-{
- if (!ug_man.win) {
- _ERR("indicator update failed: no window");
- return -1;
- }
-
- if (GET_OPT_OVERLAP_VAL(opt)) {
- _DBG("update overlap indicator / opt(%d)", opt);
- elm_object_signal_emit(ug_man.conform, "elm,state,indicator,overlap", "");
- } else {
- _DBG("update no overlap indicator / opt(%d)", opt);
- elm_object_signal_emit(ug_man.conform, "elm,state,indicator,nooverlap", "");
- }
-
- return 0;
-}
-
static int ugman_indicator_update(enum ug_option opt, enum ug_event event)
{
_ERR("controlling indicator is disabled");
@@ -422,7 +404,6 @@ static int ugman_ug_getopt(ui_gadget_h ug)
/* Indicator Option */
if (ug->mode == UG_MODE_FULLVIEW) {
- ugman_indicator_overlap_update(ug->opt);
ugman_indicator_update(ug->opt, UG_EVENT_NONE);
}
diff --git a/src/ug.c b/src/ug.c
index 2f0c5a6..e35b90b 100644
--- a/src/ug.c
+++ b/src/ug.c
@@ -120,6 +120,11 @@ UG_API int ug_init(void *win, enum ug_option opt)
}
#endif
+UG_API int UG_INIT_EFL(void *win, enum ug_option opt)
+{
+ return ug_init_efl((Evas_Object *)win, opt);
+}
+
UG_API int ug_init_efl(Evas_Object *win, enum ug_option opt)
{
if (!win) {
@@ -324,7 +329,7 @@ UG_API int ug_send_result_full(ui_gadget_h ug, app_control_h send, app_control_r
snprintf(tmp_result, 4, "%d", result);
- app_control_add_extra_data(send_dup, UG_SERVICE_DATA_RESULT, (const char*)tmp_result);
+ app_control_add_extra_data(send_dup, UG_APP_CONTROL_DATA_RESULT, (const char*)tmp_result);
ug->cbs.result_cb(ug, send_dup, ug->cbs.priv);