1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-15 13:51:40 +00:00

Add new window setting: always on top

Implemented for Windows and Linux.
This commit is contained in:
Pedro J. Estébanez
2018-01-05 20:19:27 +01:00
parent a84cb60994
commit 554ffdcde7
8 changed files with 108 additions and 3 deletions

View File

@@ -297,6 +297,14 @@ bool _OS::is_window_maximized() const {
return OS::get_singleton()->is_window_maximized();
}
void _OS::set_window_always_on_top(bool p_enabled) {
OS::get_singleton()->set_window_always_on_top(p_enabled);
}
bool _OS::is_window_always_on_top() const {
return OS::get_singleton()->is_window_always_on_top();
}
void _OS::set_borderless_window(bool p_borderless) {
OS::get_singleton()->set_borderless_window(p_borderless);
}
@@ -1031,6 +1039,8 @@ void _OS::_bind_methods() {
ObjectTypeDB::bind_method(_MD("is_window_minimized"), &_OS::is_window_minimized);
ObjectTypeDB::bind_method(_MD("set_window_maximized", "enabled"), &_OS::set_window_maximized);
ObjectTypeDB::bind_method(_MD("is_window_maximized"), &_OS::is_window_maximized);
ObjectTypeDB::bind_method(_MD("set_window_always_on_top", "enabled"), &_OS::set_window_always_on_top);
ObjectTypeDB::bind_method(_MD("is_window_always_on_top"), &_OS::is_window_always_on_top);
ObjectTypeDB::bind_method(_MD("request_attention"), &_OS::request_attention);
ObjectTypeDB::bind_method(_MD("set_borderless_window", "borderless"), &_OS::set_borderless_window);