diff options
author | Sehong Na <sehong.na@samsung.com> | 2014-05-31 13:00:43 +0900 |
---|---|---|
committer | Sehong Na <sehong.na@samsung.com> | 2014-05-31 13:00:43 +0900 |
commit | 49b40a5d9545c0847889292acf5a8da545e970eb (patch) | |
tree | f524af009437a07e766f9bdba1c48a5aa2a58ec0 /mobile/include | |
download | starter-49b40a5d9545c0847889292acf5a8da545e970eb.tar.gz starter-49b40a5d9545c0847889292acf5a8da545e970eb.tar.bz2 starter-49b40a5d9545c0847889292acf5a8da545e970eb.zip |
Initialize Tizen 2.3submit/tizen_2.3/20140531.1119222.3a_release
Diffstat (limited to 'mobile/include')
-rwxr-xr-x | mobile/include/hw_key.h | 22 | ||||
-rwxr-xr-x | mobile/include/lock-daemon.h | 24 | ||||
-rwxr-xr-x | mobile/include/lockd-debug.h | 64 | ||||
-rwxr-xr-x | mobile/include/lockd-process-mgr.h | 38 | ||||
-rwxr-xr-x | mobile/include/lockd-window-mgr.h | 42 | ||||
-rwxr-xr-x | mobile/include/menu_daemon.h | 36 | ||||
-rwxr-xr-x | mobile/include/pkg_event.h | 46 | ||||
-rwxr-xr-x | mobile/include/starter-util.h | 35 | ||||
-rwxr-xr-x | mobile/include/starter-vconf.h | 24 | ||||
-rwxr-xr-x | mobile/include/starter.h | 28 | ||||
-rwxr-xr-x | mobile/include/util.h | 97 | ||||
-rwxr-xr-x | mobile/include/x11.h | 26 | ||||
-rwxr-xr-x | mobile/include/xmonitor.h | 25 |
13 files changed, 507 insertions, 0 deletions
diff --git a/mobile/include/hw_key.h b/mobile/include/hw_key.h new file mode 100755 index 0000000..42d891d --- /dev/null +++ b/mobile/include/hw_key.h @@ -0,0 +1,22 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +extern void destroy_key_window(void); +extern void create_key_window(void); + +// End of a file diff --git a/mobile/include/lock-daemon.h b/mobile/include/lock-daemon.h new file mode 100755 index 0000000..268d945 --- /dev/null +++ b/mobile/include/lock-daemon.h @@ -0,0 +1,24 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __LOCK_DAEMON_H__ +#define __LOCK_DAEMON_H__ + +int start_lock_daemon(int launch_lock); + +#endif diff --git a/mobile/include/lockd-debug.h b/mobile/include/lockd-debug.h new file mode 100755 index 0000000..07a3835 --- /dev/null +++ b/mobile/include/lockd-debug.h @@ -0,0 +1,64 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __LOCKD_DEBUG_H__ +#define __LOCKD_DEBUG_H__ + +#include <stdio.h> +#include <dlog.h> + +#ifdef LOG_TAG +#undef LOG_TAG +#endif + +#define LOG_TAG "starter" + +#define ENABLE_LOG_SYSTEM + +void lockd_log_t(char *fmt, ...); + +#ifdef ENABLE_LOG_SYSTEM +#define STARTER_ERR(fmt, arg...) LOGE("["LOG_TAG"%s:%d:E] "fmt, __FILE__, __LINE__, ##arg) +#define STARTER_DBG(fmt, arg...) LOGD("["LOG_TAG"%s:%d:D] "fmt, __FILE__, __LINE__, ##arg) +#else +#define STARTER_ERR(fmt, arg...) +#define STARTER_DBG(fmt, arg...) +#endif + +#ifdef ENABLE_LOG_SYSTEM +#define _ERR(fmt, arg...) do { STARTER_ERR(fmt, ##arg); lockd_log_t("["LOG_TAG":%d:E] "fmt, __LINE__, ##arg); } while (0) +#define _DBG(fmt, arg...) do { STARTER_DBG(fmt, ##arg); lockd_log_t("["LOG_TAG":%d:D] "fmt, __LINE__, ##arg); } while (0) + +#define LOCKD_ERR(fmt, arg...) _ERR(fmt, ##arg) +#define LOCKD_DBG(fmt, arg...) _DBG(fmt, ##arg) +#else +#define _ERR(...) +#define _DBG(...) + +#define LOCKD_ERR(...) +#define LOCKD_ERR(...) +#endif + +#ifndef TRUE +#define TRUE 1 +#endif +#ifndef FALSE +#define FALSE 0 +#endif + +#endif diff --git a/mobile/include/lockd-process-mgr.h b/mobile/include/lockd-process-mgr.h new file mode 100755 index 0000000..195f73f --- /dev/null +++ b/mobile/include/lockd-process-mgr.h @@ -0,0 +1,38 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __LOCKD_PROCESS_MGR_H__ +#define __LOCKD_PROCESS_MGR_H__ + +int lockd_process_mgr_start_lock(void *data, int (*dead_cb) (int, void *), + int phone_lock_state); + +int lockd_process_mgr_restart_lock(int phone_lock_state); + +int lockd_process_mgr_start_phone_lock(void); + +int lockd_process_mgr_start_normal_lock(void *data, int (*dead_cb) (int, void *)); + +void lockd_process_mgr_terminate_lock_app(int lock_app_pid, + int state); + +void lockd_process_mgr_terminate_phone_lock(int phone_lock_pid); + +int lockd_process_mgr_check_lock(int pid); + +#endif diff --git a/mobile/include/lockd-window-mgr.h b/mobile/include/lockd-window-mgr.h new file mode 100755 index 0000000..d30ab31 --- /dev/null +++ b/mobile/include/lockd-window-mgr.h @@ -0,0 +1,42 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __LOCKD_WINDOW_MGR_H__ +#define __LOCKD_WINDOW_MGR_H__ + +typedef struct _lockw_data lockw_data; + +Eina_Bool +lockd_window_set_window_property(lockw_data * data, int lock_app_pid, + void *event); + +Eina_Bool +lockd_window_set_window_effect(lockw_data * data, int lock_app_pid, + void *event); + +void lockd_window_set_phonelock_pid(lockw_data * data, int phone_lock_pid); + +void +lockd_window_mgr_ready_lock(void *data, lockw_data * lockw, + Eina_Bool(*create_cb) (void *, int, void *), + Eina_Bool(*show_cb) (void *, int, void *)); + +void lockd_window_mgr_finish_lock(lockw_data * lockw); + +lockw_data *lockd_window_init(void); +#endif diff --git a/mobile/include/menu_daemon.h b/mobile/include/menu_daemon.h new file mode 100755 index 0000000..de3e843 --- /dev/null +++ b/mobile/include/menu_daemon.h @@ -0,0 +1,36 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#include <bundle.h> +#include <sys/types.h> +#include <stdbool.h> + +extern void menu_daemon_init(void *data); +extern void menu_daemon_fini(void); + +extern int menu_daemon_open_app(const char *pkgname); +extern int menu_daemon_launch_app(const char *pkgname, bundle *b); + +extern bool menu_daemon_is_homescreen(pid_t pid); + +extern int menu_daemon_check_dead_signal(int pid); + +extern char *menu_daemon_get_selected_pkgname(void); +extern void menu_daemon_open_homescreen(const char *pkgname); + +// End of a file diff --git a/mobile/include/pkg_event.h b/mobile/include/pkg_event.h new file mode 100755 index 0000000..a9fb2cd --- /dev/null +++ b/mobile/include/pkg_event.h @@ -0,0 +1,46 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __NOTIFIER_H__ +#define __NOTIFIER_H__ +#include <stdbool.h> + +#if !defined(PUBLIC) +#define PUBLIC __attribute__((visibility("default"))) +#endif + +#if !defined(PROTECTED) +#define PROTECTED __attribute__((visibility("hidden"))) +#endif + +#if !defined(PRIVATE) +#define PRIVATE __attribute__((visibility("internal"))) +#endif + + +struct desktop_notifier { + int number; + int ifd; + Ecore_Fd_Handler *handler; +}; + + +PRIVATE void pkg_event_init(void); +PRIVATE void pkg_event_fini(void); + +#endif diff --git a/mobile/include/starter-util.h b/mobile/include/starter-util.h new file mode 100755 index 0000000..117c9a4 --- /dev/null +++ b/mobile/include/starter-util.h @@ -0,0 +1,35 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __STARTER_UTIL_H__ +#define __STARTER_UTIL_H__ + +#include <stdio.h> +#include <sys/time.h> + +#define WRITE_FILE_LOG(fmt, arg...) do { \ + FILE *fp;\ + struct timeval tv; \ + gettimeofday(&tv, NULL); \ + fp = fopen("/var/log/boottime", "a+");\ + if (NULL == fp) break;\ + fprintf(fp, "%u%09u : "fmt"\n", (int) tv.tv_sec, (int) tv.tv_usec, ##arg); \ + fclose(fp);\ +} while (0) + +#endif diff --git a/mobile/include/starter-vconf.h b/mobile/include/starter-vconf.h new file mode 100755 index 0000000..f75bb77 --- /dev/null +++ b/mobile/include/starter-vconf.h @@ -0,0 +1,24 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __STARTER_VCONF_H__ +#define __STARTER_VCONF_H__ + +#define VCONF_PRIVATE_LOCKSCREEN_PKGNAME "file/private/lockscreen/pkgname" + +#endif diff --git a/mobile/include/starter.h b/mobile/include/starter.h new file mode 100755 index 0000000..00ee1e6 --- /dev/null +++ b/mobile/include/starter.h @@ -0,0 +1,28 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __STARTER_H__ +#define __STARTER_H__ + +#include <sys/time.h> + +struct appdata { + struct timeval tv_start; +}; + +#endif diff --git a/mobile/include/util.h b/mobile/include/util.h new file mode 100755 index 0000000..b59d2dc --- /dev/null +++ b/mobile/include/util.h @@ -0,0 +1,97 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __MENU_DAEMON_UTIL_H__ +#define __MENU_DAEMON_UTIL_H__ +#include <dlog.h> +#include <stdio.h> +#include <sys/time.h> + +#define HOME_SCREEN_PKG_NAME "org.tizen.menu-screen" +#define CONF_PATH_NUMBER 1024 + +#ifdef LOG_TAG +#undef LOG_TAG +#define LOG_TAG "starter" +#endif + +/* Log */ +#if !defined(_W) +#define _W(fmt, arg...) LOGW("[%s:%d] "fmt"\n", __func__, __LINE__, ##arg) +#endif + +#if !defined(_D) +#define _D(fmt, arg...) LOGD("[%s:%d] "fmt"\n", __func__, __LINE__, ##arg) +#endif + +#if !defined(_E) +#define _E(fmt, arg...) LOGE("[%s:%d] "fmt"\n", __func__, __LINE__, ##arg) +#endif + +#define retv_if(expr, val) do { \ + if(expr) { \ + _E("(%s) -> %s() return", #expr, __FUNCTION__); \ + return (val); \ + } \ +} while (0) + +#define ret_if(expr) do { \ + if(expr) { \ + _E("(%s) -> %s() return", #expr, __FUNCTION__); \ + return; \ + } \ +} while (0) + +#define goto_if(expr, val) do { \ + if(expr) { \ + _E("(%s) -> goto", #expr); \ + goto val; \ + } \ +} while (0) + +#define break_if(expr) { \ + if(expr) { \ + _E("(%s) -> break", #expr); \ + break; \ + } \ +} + +#define continue_if(expr) { \ + if(expr) { \ + _E("(%s) -> continue", #expr); \ + continue; \ + } \ +} + +#define PRINT_TIME(str) do { \ + struct timeval tv; \ + gettimeofday(&tv, NULL); \ + _D("[%s:%d] %s TIME=%u.%u", __func__, __LINE__, str, (int)tv.tv_sec, (int)tv.tv_usec); \ +} while (0) + +#define _F(fmt, arg...) do { \ + FILE *fp;\ + fp = fopen("/var/log/starter.log", "a+");\ + if (NULL == fp) break;\ + fprintf(fp, "[%s:%d] "fmt"\n", __func__, __LINE__, ##arg); \ + fclose(fp);\ +} while (0) + + + +#endif /* __MENU_DAEMON_UTIL_H__ */ diff --git a/mobile/include/x11.h b/mobile/include/x11.h new file mode 100755 index 0000000..bad90a4 --- /dev/null +++ b/mobile/include/x11.h @@ -0,0 +1,26 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __STARTER_X11_H__ +#define __STARTER_X11_H__ + +void prop_string_set(const char *name, const char *value); +void prop_int_set(const char *name, unsigned int val); +void set_window_scale(void); + +#endif diff --git a/mobile/include/xmonitor.h b/mobile/include/xmonitor.h new file mode 100755 index 0000000..097e613 --- /dev/null +++ b/mobile/include/xmonitor.h @@ -0,0 +1,25 @@ + /* + * Copyright 2012 Samsung Electronics Co., Ltd + * + * Licensed under the Flora License, Version 1.1 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://floralicense.org/license/ + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +#ifndef __MENU_DAEMON_XMONITOR_H__ +#define __MENU_DAEMON_XMONITOR_H__ + +extern int xmonitor_init(void); +extern void xmonitor_fini(void); + +#endif /* __MENU_DAEMON_XMONITOR_H__ */ |