diff options
Diffstat (limited to 'core/os')
-rw-r--r-- | core/os/main_loop.cpp | 2 | ||||
-rw-r--r-- | core/os/memory.h | 1 | ||||
-rw-r--r-- | core/os/os.h | 2 |
3 files changed, 5 insertions, 0 deletions
diff --git a/core/os/main_loop.cpp b/core/os/main_loop.cpp index 5587e827ba..146a301995 100644 --- a/core/os/main_loop.cpp +++ b/core/os/main_loop.cpp @@ -65,6 +65,8 @@ void MainLoop::_bind_methods() { BIND_CONSTANT(NOTIFICATION_OS_IME_UPDATE); BIND_CONSTANT(NOTIFICATION_APP_RESUMED); BIND_CONSTANT(NOTIFICATION_APP_PAUSED); + + ADD_SIGNAL(MethodInfo("on_request_permissions_result", PropertyInfo(Variant::STRING, "permission"), PropertyInfo(Variant::BOOL, "granted"))); }; void MainLoop::set_init_script(const Ref<Script> &p_init_script) { diff --git a/core/os/memory.h b/core/os/memory.h index 8778cb63ad..a68a359546 100644 --- a/core/os/memory.h +++ b/core/os/memory.h @@ -31,6 +31,7 @@ #ifndef MEMORY_H #define MEMORY_H +#include "core/error_macros.h" #include "core/safe_refcount.h" #include <stddef.h> diff --git a/core/os/os.h b/core/os/os.h index 9b46b43081..b5224c4f63 100644 --- a/core/os/os.h +++ b/core/os/os.h @@ -530,6 +530,8 @@ public: List<String> get_restart_on_exit_arguments() const; virtual bool request_permission(const String &p_name) { return true; } + virtual bool request_permissions() { return true; } + virtual Vector<String> get_granted_permissions() const { return Vector<String>(); } virtual void process_and_drop_events() {} OS(); |