summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiwoong Im <jiwoong.im@samsung.com>2015-05-11 06:53:13 (GMT)
committerJiwoong Im <jiwoong.im@samsung.com>2015-05-11 06:56:02 (GMT)
commit56b6988a26a031e594e36dceb3b33ccbe761f8be (patch)
tree9c8f6f53ae44c39382e112e746ffecc226d54b27
parent7314bcb19f465f1d4ce015bdb1baccb455c0b9df (diff)
downloadui-gadget-1-accepted/tizen/mobile/20150512.024300.zip
ui-gadget-1-accepted/tizen/mobile/20150512.024300.tar.gz
ui-gadget-1-accepted/tizen/mobile/20150512.024300.tar.bz2
Add ugman_init and ug_init for wayland profile to failure in UG_INIT_EFL Jira ticket : TC-2507 Change-Id: I0f787e50ac25fb18cb2bb38880fd12bf7ca5f8b8 Signed-off-by: Jiwoong Im <jiwoong.im@samsung.com>
-rw-r--r--client/ug-client.c4
-rw-r--r--include/ug-manager.h2
-rw-r--r--include/ui-gadget.h2
-rw-r--r--src/manager.c17
-rw-r--r--src/ug.c10
5 files changed, 31 insertions, 4 deletions
diff --git a/client/ug-client.c b/client/ug-client.c
index e91c916..9215e24 100644
--- a/client/ug-client.c
+++ b/client/ug-client.c
@@ -23,10 +23,6 @@
#include <appcore-efl.h>
#include <ui-gadget.h>
-#ifndef WAYLAND
-#include <Ecore_X.h>
-#endif
-
#include <dlog.h>
#include <aul.h>
#include <app.h>
diff --git a/include/ug-manager.h b/include/ug-manager.h
index 87de678..5ce61f0 100644
--- a/include/ug-manager.h
+++ b/include/ug-manager.h
@@ -36,6 +36,8 @@ int ugman_ug_del_all(void);
#ifndef WAYLAND
int ugman_init(Display *disp, Window xid, void *win, enum ug_option opt);
+#else
+int ugman_init(void *win, enum ug_option opt);
#endif
int ugman_init_efl(Evas_Object *win, enum ug_option opt);
diff --git a/include/ui-gadget.h b/include/ui-gadget.h
index bc4a1e8..73a7510 100644
--- a/include/ui-gadget.h
+++ b/include/ui-gadget.h
@@ -219,6 +219,8 @@ struct ug_cbs {
*/
#ifndef WAYLAND
int ug_init(Display *disp, Window xid, void *win, enum ug_option opt);
+#else
+int ug_init(void *win, enum ug_option opt);
#endif
/**
diff --git a/src/manager.c b/src/manager.c
index 093b465..65fdff2 100644
--- a/src/manager.c
+++ b/src/manager.c
@@ -865,6 +865,21 @@ int ugman_init(Display *disp, Window xid, void *win, enum ug_option opt)
return 0;
}
+#else
+int ugman_init(void *win, enum ug_option opt)
+{
+ ug_man.win = win;
+ ug_man.base_opt = opt;
+ ug_man.last_rotate_evt = UG_EVENT_NONE;
+
+ if (!ug_man.is_initted) {
+ ug_man.engine = ug_engine_load();
+ }
+
+ ug_man.is_initted = 1;
+
+ return 0;
+}
#endif
int ugman_init_efl(Evas_Object *win, enum ug_option opt)
@@ -873,6 +888,8 @@ int ugman_init_efl(Evas_Object *win, enum ug_option opt)
Ecore_X_Window xwin = elm_win_xwindow_get(win);
if (xwin)
return ugman_init((Display *)ecore_x_display_get(), xwin, win, opt);
+#else
+ return ugman_init(win, opt);
#endif
return -1;
}
diff --git a/src/ug.c b/src/ug.c
index 60719bc..219c69f 100644
--- a/src/ug.c
+++ b/src/ug.c
@@ -109,6 +109,16 @@ UG_API int ug_init(Display *disp, Window xid, void *win, enum ug_option opt)
return ugman_init(disp, xid, win, opt);
}
+#else
+UG_API int ug_init(void *win, enum ug_option opt)
+{
+ if (opt < UG_OPT_INDICATOR_ENABLE || opt >= UG_OPT_MAX) {
+ _ERR("ug_init() failed: Invalid option");
+ return -1;
+ }
+
+ return ugman_init(win, opt);
+}
#endif
UG_API int ug_init_efl(Evas_Object *win, enum ug_option opt)