Updating license in spec file
[apps/core/preloaded/app-selector.git] / app-selector.h
1 /*
2  * Copyright 2012  Samsung Electronics Co., Ltd
3  *
4  * Licensed under the Flora License, Version 1.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7
8  *     http://www.tizenopensource.org/license
9
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17
18
19
20 #ifndef __APP_COMMON_H__
21 #define __APP_COMMON_H__
22
23 #include <Elementary.h>
24 #include <bundle.h>
25 #include <dlog.h>
26 #include <X11/Xatom.h>
27 #include <X11/Xutil.h>
28
29
30 #undef LOG_TAG
31 #define LOG_TAG "app-selector"
32
33 #define _E(fmt, arg...) LOGE("[%s,%d] "fmt,__FUNCTION__,__LINE__,##arg)
34 #define _D(fmt, arg...) LOGD("[%s,%d] "fmt,__FUNCTION__,__LINE__,##arg)
35
36
37 #if !defined(PACKAGE)
38 #  define PACKAGE "app-selector"
39 #endif
40
41 #if !defined(LOCALEDIR)
42 #  define LOCALEDIR "/usr/share/locale"
43 #endif
44
45 #define ICON_PATH PREFIX"/share/icon"
46
47 #define NAME_BUF_LEN (128)
48 #define _EDJ(x) elm_layout_edje_get(x)
49
50 #define _(msgid) gettext(msgid)
51 #define N_(msgid) gettext_noop(msgid)
52
53 struct appdata {
54         Evas_Object *win;
55         Evas_Object *ly_main;
56
57         Ecore_Event_Handler *key_up;
58         Ecore_Event_Handler *rotate;
59
60         Evas_Object *popup;
61         Evas_Object *def_set_popup;
62
63         Eina_List *app_list;
64         Evas_Object *app_genlist;
65
66         Display *dpy;
67         Ecore_X_Window xwin;
68
69         bundle *kb;
70         int parent_pid;
71
72         char *mime_type;
73
74         char *control_op;
75         char *control_mime;
76         char *control_uri;
77
78         /* add more variables here */
79 };
80
81 struct _select_app_info {
82         char *pkg_name;
83         char *app_name;
84         char *app_path;
85         char *app_icon_path;
86         struct appdata *ad;
87         Elm_Object_Item *it;
88 };
89
90 #endif                          /* __APP_COMMON_H__ */