INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR})
INCLUDE(FindPkgConfig)
- SET(CLIENT_PKGS_CHECK_MODULES "capi-appfw-application capi-system-runtime-info appcore-efl appsvc bundle edje dlog elementary evas")
-PKG_CHECK_MODULES(CLIENT_PKGS REQUIRED
- capi-appfw-application
- appcore-efl
- appsvc
- bundle
- ecore-x
- edje
- dlog
- elementary
- evas
- x11
- vconf)
++SET(CLIENT_PKGS_CHECK_MODULES "capi-appfw-application capi-system-runtime-info appcore-efl appsvc bundle edje dlog elementary evas vconf")
+
+IF (with_x)
+ PKG_CHECK_MODULES(CLIENT_PKGS REQUIRED ${CLIENT_PKGS_CHECK_MODULES} ecore-x x11)
+ENDIF(with_x)
+
+IF (with_wayland)
+ PKG_CHECK_MODULES(CLIENT_PKGS REQUIRED ${CLIENT_PKGS_CHECK_MODULES})
+ENDIF(with_wayland)
FOREACH(flag ${CLIENT_PKGS_CFLAGS})
SET(CLIENT_CFLAGS "${CLIENT_CFLAGS} ${flag}")
#include <stdio.h>
#include <appcore-efl.h>
#include <ui-gadget.h>
+
+#ifndef WAYLAND
#include <Ecore_X.h>
+#endif
+
#include <dlog.h>
#include <aul.h>
- #include <appsvc.h>
#include <app.h>
- #include <runtime_info.h>
+ #include <vconf.h>
#include "ug-client.h"
win_del, NULL);
/* disable destktop mode
evas_object_smart_callback_add(eo, "profile,changed", profile_changed_cb, NULL); */
- ecore_x_window_size_get(ecore_x_window_root_first_get(),
- &w, &h);
+ ee = ecore_evas_ecore_evas_get(evas_object_evas_get(eo));
+ evas_output_size_get(ee, &w, &h);
evas_object_resize(eo, w, h);
+
+ elm_win_indicator_mode_set(eo,ELM_WIN_INDICATOR_SHOW);
}
return eo;
Ecore_X_Window id2 = elm_win_xwindow_get(ad->win);
ret = appsvc_request_transient_app(b, id2, svc_cb, "svc test");
- if (ret)
+
+ if (ret) {
LOGD("fail to request transient app: return value(%d)", ret);
- else
+ if(vconf_notify_key_changed(VCONFKEY_IDLE_SCREEN_TOP, _home_screen_top_cb, ad) != 0) {
+ LOGW("home screen vconf key changed cb error");
+ }
+ } else {
+ /* check home screen raise */
ad->is_transient = 1;
+ }
if (ad->win) {
elm_win_activate(ad->win);
BuildRequires: pkgconfig(appcore-efl)
BuildRequires: pkgconfig(bundle)
BuildRequires: pkgconfig(dlog)
+%if %{with x}
+BuildRequires: pkgconfig(utilX)
BuildRequires: pkgconfig(x11)
+%endif
BuildRequires: pkgconfig(appsvc)
BuildRequires: pkgconfig(capi-appfw-application)
- BuildRequires: pkgconfig(capi-system-runtime-info)
BuildRequires: pkgconfig(capi-appfw-app-manager)
+ BuildRequires: pkgconfig(vconf)
BuildRequires: cmake
BuildRequires: edje-bin
+BuildRequires: pkgconfig(libtzplatform-config)
%description
UI gadget library (development headers)
%install
rm -rf %{buildroot}
%make_install
+ mkdir -p %{buildroot}/usr/share/license
+ install LICENSE %{buildroot}/usr/share/license/%{name}
--%post
++%post
/sbin/ldconfig
+ln -sf %{TZ_SYS_BIN}/ug-client %{TZ_SYS_BIN}/ug-launcher
%postun -p /sbin/ldconfig
/usr/share/edje/ug_effect.edj
%{_bindir}/ug-client
/usr/share/edje/ug-client/*.edj
-/opt/etc/smack/accesses.d/ui-gadget-1.rule
+%{TZ_SYS_ETC}/smack/accesses.d/ui-gadget-1.rule
+ /usr/share/license/%{name}
%files devel
+%manifest %{name}.manifest
%defattr(-,root,root,-)
%{_includedir}/ug-1/*.h
%{_libdir}/libui-gadget-1.so
_DBG("indicator update opt(%d) cur_state(%d)", opt, cur_state);
+ #ifndef ENABLE_UG_HANDLE_INDICATOR_HIDE
+ enable = 1;
+ #else
switch (GET_OPT_INDICATOR_VAL(opt)) {
- case UG_OPT_INDICATOR_ENABLE:
- if (event == UG_EVENT_NONE)
- enable = 1;
- else
- enable = cur_state ? 1 : 0;
- break;
- case UG_OPT_INDICATOR_PORTRAIT_ONLY:
- enable = ug_man.is_landscape ? 0 : 1;
- break;
- case UG_OPT_INDICATOR_LANDSCAPE_ONLY:
- enable = ug_man.is_landscape ? 1 : 0;
- break;
- case UG_OPT_INDICATOR_DISABLE:
- enable = 0;
- break;
- case UG_OPT_INDICATOR_MANUAL:
- return 0;
- default:
- _ERR("update failed: Invalid opt(%d)", opt);
- return -1;
+ case UG_OPT_INDICATOR_ENABLE:
+ if (event == UG_EVENT_NONE)
+ enable = 1;
+ else
+ enable = cur_state ? 1 : 0;
+ break;
+ case UG_OPT_INDICATOR_PORTRAIT_ONLY:
+ enable = ug_man.is_landscape ? 0 : 1;
+ break;
+ case UG_OPT_INDICATOR_LANDSCAPE_ONLY:
+ enable = ug_man.is_landscape ? 1 : 0;
+ break;
+ case UG_OPT_INDICATOR_DISABLE:
+ enable = 0;
+ break;
+ case UG_OPT_INDICATOR_MANUAL:
+ return 0;
+ default:
+ _ERR("update failed: Invalid opt(%d)", opt);
+ return -1;
}
+ #endif
if(cur_state != enable) {
- _DBG("set indicator status as %d", enable);
+ _DBG("set indicator as %d", enable);
-
+#ifndef WAYLAND
utilx_enable_indicator(ug_man.disp, ug_man.win_id, enable);
+#endif
}
+
return 0;
}
return 0;
}
+#ifndef WAYLAND
int ugman_init(Display *disp, Window xid, void *win, enum ug_option opt)
{
- ug_man.is_initted = 1;
ug_man.win = win;
ug_man.disp = disp;
ug_man.win_id = xid;