From 3bd9e6aa3565f86dc1c9f081cd4ecb9eda9da3f8 Mon Sep 17 00:00:00 2001 From: Eunyoung Lee Date: Fri, 26 Jun 2015 10:19:41 +0900 Subject: [PATCH] Modify systemd dependency Change-Id: I404c26a40b2f89db2d2b1ab1c74f9fa603a92a03 --- daemon/main.c | 17 +++++------------ packaging/indicator.path | 6 ++++++ packaging/indicator.service.system | 3 ++- packaging/org.tizen.indicator.spec | 27 ++++++++++++++++----------- 4 files changed, 29 insertions(+), 24 deletions(-) create mode 100644 packaging/indicator.path diff --git a/daemon/main.c b/daemon/main.c index 3846d29..cd0d8db 100644 --- a/daemon/main.c +++ b/daemon/main.c @@ -666,7 +666,7 @@ static void _create_win(void* data) // root = ecore_x_window_root_first_get(); // ecore_x_window_size_get(root, &root_w, &root_h); - +#if 1 if (root_w > qHD_RESOLUTION_WIDTH) { // HD _D("Window w, h (%d,%d)", root_w, root_h); ad->win.port_w = root_w; @@ -683,11 +683,15 @@ static void _create_win(void* data) ad->win.land_w = root_h; ad->win.h = INDICATOR_HEIGHT_qHD; } +#endif /* Create socket window */ ad->win.win = elm_win_add(NULL, "portrait_indicator", ELM_WIN_SOCKET_IMAGE); indi_name = "elm_indicator"; elm_win_title_set(ad->win.win, "win sock test:port"); + + /*FIXME*/ + ad->win.w = root_w; ret_if(!(ad->win.win)); @@ -706,15 +710,6 @@ static void _create_win(void* data) evas_object_size_hint_fill_set(ad->win.win , EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); evas_object_size_hint_align_set(ad->win.win , 1.0, 0.5); - /* make illume2 recognize indicator window */ - xwin = elm_win_xwindow_get(ad->win.win ); -// ecore_x_icccm_hints_set(xwin, 0, 0, 0, 0, 0, 0, 0); -// states[0] = ECORE_X_WINDOW_STATE_SKIP_TASKBAR; -// states[1] = ECORE_X_WINDOW_STATE_SKIP_PAGER; -// ecore_x_netwm_window_state_set(xwin, states, 2); - -// zone = ecore_x_e_illume_zone_get(xwin); -// ecore_x_event_mask_set(zone, ECORE_X_EVENT_MASK_WINDOW_CONFIGURE); ad->win.evas = evas_object_evas_get(ad->win.win); ad->win.layout = _create_layout(ad->win.win, EDJ_FILE0, GRP_MAIN); @@ -1182,9 +1177,7 @@ int main(int argc, char *argv[]) event_callback.resume = app_resume; event_callback.app_control = app_service; - ui_app_add_event_handler(&handlers[APP_EVENT_LOW_MEMORY], APP_EVENT_LOW_MEMORY, NULL, NULL); ui_app_add_event_handler(&handlers[APP_EVENT_LOW_BATTERY], APP_EVENT_LOW_BATTERY, _indicator_low_bat_cb, NULL); - ui_app_add_event_handler(&handlers[APP_EVENT_DEVICE_ORIENTATION_CHANGED], APP_EVENT_DEVICE_ORIENTATION_CHANGED, NULL, NULL); ui_app_add_event_handler(&handlers[APP_EVENT_LANGUAGE_CHANGED], APP_EVENT_LANGUAGE_CHANGED, _indicator_lang_changed_cb, &ad); ui_app_add_event_handler(&handlers[APP_EVENT_REGION_FORMAT_CHANGED], APP_EVENT_REGION_FORMAT_CHANGED, _indicator_region_changed_cb, NULL); diff --git a/packaging/indicator.path b/packaging/indicator.path new file mode 100644 index 0000000..f33cd13 --- /dev/null +++ b/packaging/indicator.path @@ -0,0 +1,6 @@ +[Unit] +Description=This path will tell you that indicator is ready to launch + +[Path] +PathExists=/run/.wm_ready + diff --git a/packaging/indicator.service.system b/packaging/indicator.service.system index 3ca3e50..d85100a 100644 --- a/packaging/indicator.service.system +++ b/packaging/indicator.service.system @@ -3,11 +3,12 @@ Description=Start the indicator After=launchpad-preload.service wm_ready.service [Service] +EnvironmentFile=/run/tizen-system-env ExecStart=/usr/apps/org.tizen.indicator/bin/indicator Restart=always RestartSec=0 OOMScoreAdjust=200 -EnvironmentFile=/run/tizen-mobile-env +#EnvironmentFile=/run/tizen-mobile-env [Install] WantedBy=multi-user.target diff --git a/packaging/org.tizen.indicator.spec b/packaging/org.tizen.indicator.spec index ccc9b1f..14db936 100644 --- a/packaging/org.tizen.indicator.spec +++ b/packaging/org.tizen.indicator.spec @@ -11,7 +11,8 @@ Group: utils License: Apache-2.0 Source0: %{name}-%{version}.tar.gz Source1: indicator.service.system -Source101: indicator.service +Source2: indicator.path +#Source101: indicator.service %if "%{?tizen_profile_name}" == "wearable" ExcludeArch: %{arm} %ix86 x86_64 @@ -102,12 +103,14 @@ cp -f LICENSE %{buildroot}/usr/share/license/%{PKGNAME} %define tizen_author_sign 1 %define tizen_dist_sign 1 -install -d %{buildroot}%{_libdir}/systemd/user/core-efl.target.wants -install -m0644 %{SOURCE101} %{buildroot}%{_libdir}/systemd/user/ -ln -sf ../indicator.service %{buildroot}%{_libdir}/systemd/user/core-efl.target.wants/indicator.service -mkdir -p %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants -install -m 0644 %SOURCE1 %{buildroot}%{_libdir}/systemd/system/indicator.service -ln -s ../indicator.service %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants/indicator.service +#install -d %{buildroot}/usr/lib/systemd/user/core-efl.target.wants +#install -m0644 %{SOURCE101} %{buildroot}/usr/lib/systemd/user/ +#ln -sf ../indicator.service %{buildroot}/usr/lib/systemd/user/core-efl.target.wants/indicator.service +mkdir -p %{buildroot}/usr/lib/systemd/system/multi-user.target.wants +install -m 0644 %SOURCE1 %{buildroot}/usr/lib/systemd/system/indicator.service +ln -s ../indicator.service %{buildroot}/usr/lib/systemd/system/multi-user.target.wants/indicator.service +install -m 0644 %SOURCE2 %{buildroot}/usr/lib/systemd/system/indicator.path +ln -s ../indicator.path %{buildroot}/usr/lib/systemd/system/multi-user.target.wants/ %clean rm -rf %{buildroot} @@ -126,10 +129,12 @@ vconftool set -t int memory/private/%{PKGNAME}/show_more_noti_port 0 -i -g 6518 /usr/share/packages/%{PKGNAME}.xml %attr(775,app,app) %{PREFIXRW}/data %attr(755,-,-) %{_sysconfdir}/init.d/indicator -%{_libdir}/systemd/user/core-efl.target.wants/indicator.service -%{_libdir}/systemd/user/indicator.service -%{_libdir}/systemd/system/multi-user.target.wants/indicator.service -%{_libdir}/systemd/system/indicator.service +#/usr/lib/systemd/user/core-efl.target.wants/indicator.service +#/usr/lib/systemd/user/indicator.service +/usr/lib/systemd/system/multi-user.target.wants/indicator.service +/usr/lib/systemd/system/indicator.service +/usr/lib/systemd/system/multi-user.target.wants/indicator.path +/usr/lib/systemd/system/indicator.path /usr/share/license/%{PKGNAME} /etc/smack/accesses.d/%{PKGNAME}.efl /usr/apps/%{PKGNAME}/author-signature.xml -- 2.7.4