468a1ab132cb4a0892e17ce1ad2663a21c66f6f0
[platform/core/appfw/app-core.git] / include / appcore_efl_base.h
1 /*
2  * Copyright (c) 2017 Samsung Electronics Co., Ltd. All rights reserved.
3  *
4  * Licensed under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0
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 #pragma once
18
19 #include <libintl.h>
20 #include <aul.h>
21 #include <bundle.h>
22 #include <appcore_ui_base.h>
23
24 typedef struct _appcore_efl_base_ops {
25         appcore_ui_base_ops ui_base;
26 } appcore_efl_base_ops;
27
28 #ifdef __cplusplus
29 extern "C" {
30 #endif
31
32 enum appcore_efl_base_hint {
33         APPCORE_EFL_BASE_HINT_WINDOW_GROUP_CONTROL = APPCORE_UI_BASE_HINT_WINDOW_GROUP_CONTROL,
34         APPCORE_EFL_BASE_HINT_WINDOW_STACK_CONTROL = APPCORE_UI_BASE_HINT_WINDOW_STACK_CONTROL,
35         APPCORE_EFL_BASE_HINT_BG_LAUNCH_CONTROL = APPCORE_UI_BASE_HINT_BG_LAUNCH_CONTROL,
36         APPCORE_EFL_BASE_HINT_HW_ACC_CONTROL = APPCORE_UI_BASE_HINT_HW_ACC_CONTROL,
37         APPCORE_EFL_BASE_HINT_WINDOW_AUTO_CONTROL = APPCORE_UI_BASE_HINT_WINDOW_AUTO_CONTROL,
38         APPCORE_EFL_BASE_HINT_LEGACY_CONTROL = APPCORE_UI_BASE_HINT_LEGACY_CONTROL,
39 };
40
41 int appcore_efl_base_on_receive(aul_type type, bundle *b);
42 int appcore_efl_base_on_create(void);
43 int appcore_efl_base_on_terminate(void);
44 int appcore_efl_base_on_pause(void);
45 int appcore_efl_base_on_resume(void);
46 int appcore_efl_base_on_control(bundle *b);
47 int appcore_efl_base_on_trim_memory(void);
48 void appcore_efl_base_window_on_show(int type, void *event);
49 void appcore_efl_base_window_on_hide(int type, void *event);
50 void appcore_efl_base_window_on_lower(int type, void *event);
51 void appcore_efl_base_window_on_visibility(int type, void *event);
52 void appcore_efl_base_window_on_pre_visibility(int type, void *event);
53 void appcore_efl_base_window_on_aux_message(int type, void *event);
54 int appcore_efl_base_init(appcore_efl_base_ops ops, int argc, char **argv,
55                 void *data, unsigned int hint);
56 void appcore_efl_base_fini(void);
57 appcore_efl_base_ops appcore_efl_base_get_default_ops(void);
58 void appcore_efl_base_pause(void);
59 void appcore_efl_base_resume(void);
60 bool appcore_efl_base_is_resumed(void);
61 void appcore_efl_base_exit(void);
62 void appcore_efl_base_group_add();
63 void appcore_efl_base_group_remove();
64 unsigned int appcore_efl_base_get_main_window(void);
65 unsigned int appcore_efl_base_get_main_surface(void);
66 int appcore_efl_base_get_hint(void);
67 bool appcore_efl_base_get_bg_state(void);
68 void appcore_efl_base_set_bg_state(bool bg_state);
69 void appcore_efl_base_set_system_resource_reclaiming(bool enable);
70
71 #ifdef __cplusplus
72 }
73 #endif
74
75