745e26f213108b7b4893a93fe5a15368e499ad66
[platform/framework/web/chromium-efl.git] / tizen_src / ewk / efl_integration / public / ewk_geolocation.h
1 // Copyright 2013 Samsung Electronics. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef ewk_geolocation_h
6 #define ewk_geolocation_h
7
8 #include <Eina.h>
9 #include <tizen.h>
10 #include "ewk_security_origin.h"
11
12 #ifdef __cplusplus
13 extern "C" {
14 #endif
15
16 typedef struct _Ewk_Geolocation_Permission_Request Ewk_Geolocation_Permission_Request;
17
18 /**
19  * Requests for getting origin of geolocation permission request.
20  *
21  * @param request Ewk_Geolocation_Permission_Request object to get origin
22  *
23  * @return security origin of geolocation permission data
24  */
25 EXPORT_API const Ewk_Security_Origin *ewk_geolocation_permission_request_origin_get(const Ewk_Geolocation_Permission_Request *request);
26
27 /**
28  * Deprecated
29  * Request to allow / deny the geolocation permission request
30  *
31  * @param request permission request to allow or deny permission
32  * @param allow allow or deny permission for geolocation
33  *
34  * @return @c EINA_TRUE on success or @c EINA_FALSE otherwise
35  */
36 EXPORT_API Eina_Bool ewk_geolocation_permission_request_set(Ewk_Geolocation_Permission_Request *request, Eina_Bool allow);
37
38 /**
39  * Request to allow / deny the geolocation permission request
40  *
41  * @param request permission request to allow or deny permission
42  * @param allow allow or deny permission for geolocation
43  *
44  * @return @c EINA_TRUE on success or @c EINA_FALSE otherwise
45  */
46 EXPORT_API Eina_Bool ewk_geolocation_permission_reply(Ewk_Geolocation_Permission_Request* permissionRequest, Eina_Bool allow);
47
48 /**
49  * Suspend the operation for permission request.
50  *
51  * This suspends the operation for permission request.
52  * This is very useful to decide the policy from the additional UI operation like the popup.
53  *
54  * @param request Ewk_Geolocation_Permission_Request object to suspend permission request
55  */
56 EXPORT_API void ewk_geolocation_permission_request_suspend(Ewk_Geolocation_Permission_Request *request);
57
58 #ifdef __cplusplus
59 }
60 #endif
61
62 #endif // ewk_geolocation_h