4 * Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved.
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
10 * http://www.apache.org/licenses/LICENSE-2.0
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
21 #ifndef __POPUP_COMMON_H__
22 #define __POPUP_COMMON_H__
24 #include "popup-common-internal.h"
34 int (*get_content)(const struct popup_ops *ops,
35 char *content, unsigned int len);
38 void (*left)(const struct popup_ops *ops);
41 void (*right)(const struct popup_ops *ops);
47 bool (*skip)(bundle *b, const struct popup_ops *ops);
48 int (*change) (bundle *b, const struct popup_ops *ops);
49 int (*pre) (bundle *b, const struct popup_ops *ops);
50 int (*show) (bundle *b, const struct popup_ops *ops);
51 int (*post) (bundle *b, const struct popup_ops *ops);
52 void (*terminate)(const struct popup_ops *ops);
55 bool (*term_pause)(const struct popup_ops *ops);
56 bool (*term_home)(const struct popup_ops *ops);
59 typedef struct appdata {
63 /* Used by Wearable Profile */
65 Evas_Object *datetime;
68 /* Need updates of efl-ext for Tizen 4.0 */
69 #if !defined PROFILE_MOBILE && !defined PROFILE_IVI && !defined PROFILE_COMMON && !defined PROFILE_TV
70 Eext_Circle_Surface *circle_surface;
75 /* Used by Mobile Profile */
80 void terminate_if_no_popup(void);
83 void register_popup(const struct popup_ops *ops);
84 void update_popup(const struct popup_ops *old_ops, const struct popup_ops *new_ops);
85 void unload_simple_popup(const struct popup_ops *ops);
86 int load_simple_popup(bundle *b, const struct popup_ops *ops);
87 bool get_check_state(const struct popup_ops *ops);
90 int set_dbus_connection(void);
91 void unset_dbus_connection(void);
92 E_DBus_Connection *get_dbus_connection(void);
93 int broadcast_dbus_signal(
95 const char *interface,
99 int popup_dbus_method_sync(
102 const char *interface,
106 int register_dbus_signal_handler(
107 E_DBus_Signal_Handler **handler,
111 void (*signal_cb)(void *data, DBusMessage *msg),
113 void unregister_dbus_signal_handler(E_DBus_Signal_Handler *handler);
116 void play_feedback(int type, int pattern);
117 void init_multi_feedback(void);
118 void play_multi_feedback(int pattern);
119 void stop_multi_feedback(void);
120 void notify_feedback(long pattern); /* using thread */
122 void change_display_state(void); /* using thread */
123 void event_back_key_up(void *data, Evas_Object *obj, void *event_info);
124 #endif /* __POPUP_COMMON_H__ */