From a3a687725ff0ac9a1853db9e8c62eb7075b1e065 Mon Sep 17 00:00:00 2001 From: Relintai Date: Sun, 11 Dec 2022 10:49:48 +0100 Subject: [PATCH] Request permissions on android. --- game/Main.tscn | 30 +++++++++++++++--------------- game/sort/Sort.gd | 2 ++ 2 files changed, 17 insertions(+), 15 deletions(-) diff --git a/game/Main.tscn b/game/Main.tscn index 42eb65d..a6da28f 100644 --- a/game/Main.tscn +++ b/game/Main.tscn @@ -15,27 +15,27 @@ script = ExtResource( 2 ) [node name="Menu" parent="." instance=ExtResource( 1 )] anchor_right = 0.0 anchor_bottom = 0.0 -margin_right = 1024.0 -margin_bottom = 800.0 +margin_right = 900.0 +margin_bottom = 1000.0 [node name="VBoxContainer" parent="Menu" index="0"] -margin_right = 1024.0 -margin_bottom = 800.0 +margin_right = 900.0 +margin_bottom = 1000.0 [node name="Sort" parent="Menu/VBoxContainer" index="0"] -margin_top = 313.0 -margin_right = 1024.0 -margin_bottom = 355.0 +margin_top = 413.0 +margin_right = 900.0 +margin_bottom = 455.0 [node name="Settings" parent="Menu/VBoxContainer" index="1"] -margin_top = 379.0 -margin_right = 1024.0 -margin_bottom = 421.0 +margin_top = 479.0 +margin_right = 900.0 +margin_bottom = 521.0 [node name="Exit" parent="Menu/VBoxContainer" index="2"] -margin_top = 445.0 -margin_right = 1024.0 -margin_bottom = 487.0 +margin_top = 545.0 +margin_right = 900.0 +margin_bottom = 587.0 [node name="Settings" parent="." instance=ExtResource( 3 )] visible = false @@ -52,8 +52,8 @@ margin_right = 1017.0 margin_bottom = 593.0 [node name="Control" type="Control" parent="."] -margin_right = 1024.0 -margin_bottom = 800.0 +margin_right = 900.0 +margin_bottom = 1000.0 mouse_filter = 2 [node name="FolderSetupError" type="AcceptDialog" parent="Control"] diff --git a/game/sort/Sort.gd b/game/sort/Sort.gd index 392815e..30147ff 100644 --- a/game/sort/Sort.gd +++ b/game/sort/Sort.gd @@ -84,6 +84,8 @@ func refresh_sub_categories() -> void: _sub_categories_ob.add_item(folders[i]) func validate_folders() -> bool: + OS.request_permissions() + sort_folder = ProjectSettings.get("application/config/sort_folder") target_folder = ProjectSettings.get("application/config/target_folder")