#include <unistd.h>
#include <appcore-efl.h>
#include <vconf.h>
+#if HAVE_X
#include <utilX.h>
+#endif
#include <aul.h>
#include <Ecore_X.h>
#include <Eina.h>
selected = 0;
} else {
+#if HAVE_X
_unset_notification_level(info->ad->win);
+#endif
if (!strcmp(info->pkg_name, "org.tizen.phone")) {
/* exception : Because dialer doesn't need bundle
_vconf_noti_cb, NULL);
}
+/* X specific */
+#if HAVE_X
/* this func is to exit taskmanager after launching application */
static Eina_Bool __climsg_cb(void *data, int type, void *event)
{
return ECORE_CALLBACK_CANCEL;
}
+#endif
static Eina_Bool _ask_kill_process(void *data)
{
evas_object_show(ad->win);
+#if HAVE_X
_key_grab(ad);
+#endif
_init_pthread();
_get_win_geometry(ad);
_set_vconf_noti(ad);
+#if HAVE_X
ecore_event_handler_add(ECORE_X_EVENT_CLIENT_MESSAGE, __climsg_cb, ad);
+#endif
return ECORE_CALLBACK_CANCEL;
}
#include <appcore-efl.h>
#include <Elementary.h>
#include <Ecore_X.h>
+#if HAVE_X
#include <utilX.h>
+#endif
#include <vconf.h>
#include <aul.h>
#include <sysman.h>
return ECORE_CALLBACK_CANCEL;
}
+/* X Specific */
+#if HAVE_X
void _key_grab(struct appdata *ad)
{
int ret = 0;
ret = utilx_grab_key(disp, xwin, KEY_SELECT, SHARED_GRAB);
retm_if(ret < 0, "Failed to grab home key\n");
}
+#endif
+/* X Specific */
+#if HAVE_X
int _set_launch_effect(Evas_Object *win)
{
Ecore_X_Window xwin = 0;
ecore_x_icccm_name_class_set(xwin, "TASK_MANAGER", "TASK_MANAGER");
return 0;
}
+#endif
+/* X Specific */
+#if HAVE_X
int _unset_notification_level(Evas_Object *win)
{
Ecore_X_Window xwin;
ecore_x_netwm_window_type_set(xwin, ECORE_X_WINDOW_TYPE_NORMAL);
return 0;
}
+#endif
+/* X Specific */
+#if HAVE_X
int _set_notification_level(Evas_Object *win, Utilx_Notification_Level level)
{
Ecore_X_Window xwin = 0;
utilx_set_system_notification_level(ecore_x_display_get(), xwin, level);
return 0;
}
+#endif
int app_create(void *data)
{
elm_win_indicator_mode_set(win, ELM_WIN_INDICATOR_SHOW);
ad->win = win;
+#if HAVE_X
_set_launch_effect(win);
// _set_notification_level(win, UTILX_NOTIFICATION_LEVEL_NORMAL);
+#endif
elm_theme_extension_add(NULL, EDJ_THEME);
+/* Set to run in wayland only */
+#define HAVE_X 0
#ifndef __TASKMANAGER_H__
#define __TASKMANAGER_H__
#include <Elementary.h>
#include <Ecore_X.h>
+#if HAVE_X
#include <utilX.h>
+#endif
#include <bundle.h>
#if !defined(PACKAGE)
};
Evas_Object *load_edj(Evas_Object *parent, const char *file, const char *group);
+#if HAVE_X
int _unset_notification_level(Evas_Object *win);
int _set_notification_level(Evas_Object *win, Utilx_Notification_Level level);
+#endif
Eina_Bool _exit_cb(void *data);
#endif