fix: show Nav UI in accessibility is now accessible again
This commit is contained in:
parent
30a38c9eb2
commit
16414da77e
|
|
@ -1,118 +1,18 @@
|
||||||
[gd_scene load_steps=6 format=3 uid="uid://gldtxysavetf"]
|
[gd_scene load_steps=6 format=3 uid="uid://gldtxysavetf"]
|
||||||
|
|
||||||
[ext_resource type="Texture2D" uid="uid://d0ucjqi8tx6vt" path="res://import/interface-elements/frame.png" id="1_8giso"]
|
[ext_resource type="Texture2D" uid="uid://d0ucjqi8tx6vt" path="res://import/interface-elements/frame.png" id="1_8giso"]
|
||||||
[ext_resource type="PackedScene" uid="uid://b3wlecqvelh22" path="res://ui/menu_main/acessability_settings.tscn" id="3_2p4fc"]
|
[ext_resource type="Script" uid="uid://3mtyfiuxbavf" path="res://logic-scenes/startup/startup_menu.gd" id="1_lw8rc"]
|
||||||
|
[ext_resource type="PackedScene" uid="uid://b3wlecqvelh22" path="res://ui/menu_main/accessibility_settings.tscn" id="3_2p4fc"]
|
||||||
[ext_resource type="PackedScene" uid="uid://chal0ioagspx0" path="res://ui/menu_main/content_settings.tscn" id="3_fso6q"]
|
[ext_resource type="PackedScene" uid="uid://chal0ioagspx0" path="res://ui/menu_main/content_settings.tscn" id="3_fso6q"]
|
||||||
[ext_resource type="Texture2D" uid="uid://bwicl5q0lw06q" path="res://import/interface-elements/bottom.png" id="3_s5ssh"]
|
[ext_resource type="Texture2D" uid="uid://bwicl5q0lw06q" path="res://import/interface-elements/bottom.png" id="3_s5ssh"]
|
||||||
|
|
||||||
[sub_resource type="GDScript" id="GDScript_a78qq"]
|
|
||||||
script/source = "extends Panel
|
|
||||||
|
|
||||||
@export var is_in_startup: bool
|
|
||||||
|
|
||||||
@onready var show_navigation_buttons = $\"SettingsContainer/PanelContainer/VBoxContainer/TabContainer/physical Accessibility/Container2/margin/show nav ui\"
|
|
||||||
|
|
||||||
func _ready():
|
|
||||||
theme = State.current_main_theme
|
|
||||||
State.theme_changed.connect(func change_theme(new_theme): theme = new_theme)
|
|
||||||
TranslationServer.set_locale(\"de\")
|
|
||||||
|
|
||||||
func starting():
|
|
||||||
pass
|
|
||||||
#$\"CenterContainer/PanelContainer/VBoxContainer/TabContainer/physical Accessibility/navbuttons/Next\".grab_focus()
|
|
||||||
|
|
||||||
func _on_reduce_motion_toggled(toggled_on):
|
|
||||||
State.reduce_motion = toggled_on
|
|
||||||
|
|
||||||
# toggle for disable rendering
|
|
||||||
func _on_disable_rendering_toggled(toggled_on):
|
|
||||||
State.disable_rendering = toggled_on
|
|
||||||
|
|
||||||
# toggle for simplified controls
|
|
||||||
func _on_simplified_controls_toggled(toggled_on):
|
|
||||||
State.simplified_navigation = toggled_on # this is how you reach the global state
|
|
||||||
show_navigation_buttons.disabled = not toggled_on # if simpl. controls was toggled - disabled = false
|
|
||||||
|
|
||||||
# toggle for show nav buttons
|
|
||||||
func _on_show_nav_ui_toggled(toggled_on):
|
|
||||||
State.show_navigation_buttons = toggled_on
|
|
||||||
|
|
||||||
# toggle streaming notes
|
|
||||||
func _on_streaming_notes_toggled(toggled_on):
|
|
||||||
State.streaming_content_notes = toggled_on
|
|
||||||
|
|
||||||
|
|
||||||
# select font
|
|
||||||
# still needs handling to change the style
|
|
||||||
func _on_font_style_selected(index):
|
|
||||||
match index:
|
|
||||||
1:
|
|
||||||
State.current_main_theme = preload(\"res://logic-scenes/themes/handwriting.theme\")
|
|
||||||
print_debug(\"easy handwriting selected\")
|
|
||||||
#owner.theme.set_font(\"NanumPenScript.ttf\")
|
|
||||||
return
|
|
||||||
2:
|
|
||||||
State.current_main_theme = preload(\"res://logic-scenes/themes/serif.theme\")
|
|
||||||
#owner.theme.set_font(\"Eczar-VariableFont_wght.ttf\")
|
|
||||||
return
|
|
||||||
3:
|
|
||||||
State.current_main_theme = preload(\"res://logic-scenes/themes/hyperlegible.theme\")
|
|
||||||
#owner.theme.set_font(\"AtkinsonHyperlegible.ttf\")
|
|
||||||
return
|
|
||||||
4:
|
|
||||||
State.current_main_theme = preload(\"res://logic-scenes/themes/system.theme\")
|
|
||||||
#owner.theme.set_font(SystemFont.fallbacks[0])
|
|
||||||
return
|
|
||||||
|
|
||||||
func _on_subtitle_option_selected(index):
|
|
||||||
match index:
|
|
||||||
0:
|
|
||||||
State.enable_subtitles = false
|
|
||||||
State.enable_closed_caption = false
|
|
||||||
1:
|
|
||||||
State.enable_subtitles = true
|
|
||||||
State.enable_closed_caption = false
|
|
||||||
2:
|
|
||||||
State.enable_subtitles = true
|
|
||||||
State.enable_closed_caption = true
|
|
||||||
|
|
||||||
print_debug(State.print_settings())
|
|
||||||
|
|
||||||
|
|
||||||
# Volume Settings
|
|
||||||
|
|
||||||
|
|
||||||
# Final Page
|
|
||||||
|
|
||||||
func _on_content_notes_toggled(button_pressed):
|
|
||||||
State.show_content_notes = button_pressed
|
|
||||||
|
|
||||||
|
|
||||||
func _on_provide_summaries_toggled(button_pressed):
|
|
||||||
State.provide_summaries = button_pressed
|
|
||||||
|
|
||||||
|
|
||||||
func _on_allow_skipping_toggled(button_pressed):
|
|
||||||
State.allow_skipping = button_pressed
|
|
||||||
|
|
||||||
func hide():
|
|
||||||
get_parent().get_child(0).get_ready()
|
|
||||||
var child_tween = create_tween()
|
|
||||||
child_tween.tween_property($CenterContainer, \"modulate\", Color(1, 1, 1, 0), .5)
|
|
||||||
await child_tween.finished
|
|
||||||
var self_tween = create_tween()
|
|
||||||
self_tween.tween_property(self, \"modulate\", Color(1, 1, 1, 0), .5)
|
|
||||||
await self_tween.finished
|
|
||||||
self.visible = false
|
|
||||||
"
|
|
||||||
|
|
||||||
[node name="Startup Menu" type="Panel"]
|
[node name="Startup Menu" type="Panel"]
|
||||||
anchors_preset = 15
|
anchors_preset = 15
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
anchor_bottom = 1.0
|
anchor_bottom = 1.0
|
||||||
grow_horizontal = 2
|
grow_horizontal = 2
|
||||||
grow_vertical = 2
|
grow_vertical = 2
|
||||||
script = SubResource("GDScript_a78qq")
|
script = ExtResource("1_lw8rc")
|
||||||
|
|
||||||
[node name="Label" type="Label" parent="."]
|
[node name="Label" type="Label" parent="."]
|
||||||
visible = false
|
visible = false
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,98 @@
|
||||||
|
extends Panel
|
||||||
|
|
||||||
|
@export var is_in_startup: bool
|
||||||
|
|
||||||
|
@onready var show_navigation_buttons = %Accessibility/Container2/margin/ShowNavUI
|
||||||
|
|
||||||
|
func _ready():
|
||||||
|
theme = State.current_main_theme
|
||||||
|
State.theme_changed.connect(func change_theme(new_theme): theme = new_theme)
|
||||||
|
TranslationServer.set_locale("de")
|
||||||
|
|
||||||
|
func starting():
|
||||||
|
pass
|
||||||
|
#$"CenterContainer/PanelContainer/VBoxContainer/TabContainer/physical Accessibility/navbuttons/Next".grab_focus()
|
||||||
|
|
||||||
|
func _on_reduce_motion_toggled(toggled_on):
|
||||||
|
State.reduce_motion = toggled_on
|
||||||
|
|
||||||
|
# toggle for disable rendering
|
||||||
|
func _on_disable_rendering_toggled(toggled_on):
|
||||||
|
State.disable_rendering = toggled_on
|
||||||
|
|
||||||
|
# toggle for simplified controls
|
||||||
|
func _on_simplified_controls_toggled(toggled_on):
|
||||||
|
State.simplified_navigation = toggled_on # this is how you reach the global state
|
||||||
|
show_navigation_buttons.disabled = not toggled_on # if simpl. controls was toggled - disabled = false
|
||||||
|
|
||||||
|
# toggle for show nav buttons
|
||||||
|
func _on_show_nav_ui_toggled(toggled_on):
|
||||||
|
State.show_navigation_buttons = toggled_on
|
||||||
|
|
||||||
|
# toggle streaming notes
|
||||||
|
func _on_streaming_notes_toggled(toggled_on):
|
||||||
|
State.streaming_content_notes = toggled_on
|
||||||
|
|
||||||
|
|
||||||
|
# select font
|
||||||
|
# still needs handling to change the style
|
||||||
|
func _on_font_style_selected(index):
|
||||||
|
match index:
|
||||||
|
1:
|
||||||
|
State.current_main_theme = preload("res://logic-scenes/themes/handwriting.theme")
|
||||||
|
print_debug("easy handwriting selected")
|
||||||
|
#owner.theme.set_font("NanumPenScript.ttf")
|
||||||
|
return
|
||||||
|
2:
|
||||||
|
State.current_main_theme = preload("res://logic-scenes/themes/serif.theme")
|
||||||
|
#owner.theme.set_font("Eczar-VariableFont_wght.ttf")
|
||||||
|
return
|
||||||
|
3:
|
||||||
|
State.current_main_theme = preload("res://logic-scenes/themes/hyperlegible.theme")
|
||||||
|
#owner.theme.set_font("AtkinsonHyperlegible.ttf")
|
||||||
|
return
|
||||||
|
4:
|
||||||
|
State.current_main_theme = preload("res://logic-scenes/themes/system.theme")
|
||||||
|
#owner.theme.set_font(SystemFont.fallbacks[0])
|
||||||
|
return
|
||||||
|
|
||||||
|
func _on_subtitle_option_selected(index):
|
||||||
|
match index:
|
||||||
|
0:
|
||||||
|
State.enable_subtitles = false
|
||||||
|
State.enable_closed_caption = false
|
||||||
|
1:
|
||||||
|
State.enable_subtitles = true
|
||||||
|
State.enable_closed_caption = false
|
||||||
|
2:
|
||||||
|
State.enable_subtitles = true
|
||||||
|
State.enable_closed_caption = true
|
||||||
|
|
||||||
|
print_debug(State.print_settings())
|
||||||
|
|
||||||
|
|
||||||
|
# Volume Settings
|
||||||
|
|
||||||
|
|
||||||
|
# Final Page
|
||||||
|
|
||||||
|
func _on_content_notes_toggled(button_pressed):
|
||||||
|
State.show_content_notes = button_pressed
|
||||||
|
|
||||||
|
|
||||||
|
func _on_provide_summaries_toggled(button_pressed):
|
||||||
|
State.provide_summaries = button_pressed
|
||||||
|
|
||||||
|
|
||||||
|
func _on_allow_skipping_toggled(button_pressed):
|
||||||
|
State.allow_skipping = button_pressed
|
||||||
|
|
||||||
|
func hide():
|
||||||
|
get_parent().get_child(0).get_ready()
|
||||||
|
var child_tween = create_tween()
|
||||||
|
child_tween.tween_property($CenterContainer, "modulate", Color(1, 1, 1, 0), .5)
|
||||||
|
await child_tween.finished
|
||||||
|
var self_tween = create_tween()
|
||||||
|
self_tween.tween_property(self, "modulate", Color(1, 1, 1, 0), .5)
|
||||||
|
await self_tween.finished
|
||||||
|
self.visible = false
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
uid://3mtyfiuxbavf
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
extends VBoxContainer
|
extends VBoxContainer
|
||||||
|
class AccessibilitySettings
|
||||||
|
|
||||||
signal changed
|
signal changed
|
||||||
signal leave_stage
|
signal leave_stage
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
[gd_scene load_steps=5 format=3 uid="uid://b3wlecqvelh22"]
|
[gd_scene load_steps=5 format=3 uid="uid://b3wlecqvelh22"]
|
||||||
|
|
||||||
[ext_resource type="Script" uid="uid://cbax2lv4pstqk" path="res://ui/menu_main/acessability_settings.gd" id="1_x3lym"]
|
[ext_resource type="Script" uid="uid://cbax2lv4pstqk" path="res://ui/menu_main/accessibility_settings.gd" id="1_x3lym"]
|
||||||
[ext_resource type="PackedScene" uid="uid://dy5rd437h5hsw" path="res://logic-scenes/board/card.tscn" id="2_24dtk"]
|
[ext_resource type="PackedScene" uid="uid://dy5rd437h5hsw" path="res://logic-scenes/board/card.tscn" id="2_24dtk"]
|
||||||
|
|
||||||
[sub_resource type="GDScript" id="GDScript_v567h"]
|
[sub_resource type="GDScript" id="GDScript_v567h"]
|
||||||
|
|
@ -19,6 +19,7 @@ func _ready() -> void:
|
||||||
|
|
||||||
[node name="Accessibility" type="VBoxContainer"]
|
[node name="Accessibility" type="VBoxContainer"]
|
||||||
script = ExtResource("1_x3lym")
|
script = ExtResource("1_x3lym")
|
||||||
|
is_in_beginning = null
|
||||||
metadata/_tab_index = 0
|
metadata/_tab_index = 0
|
||||||
|
|
||||||
[node name="Label" type="Label" parent="."]
|
[node name="Label" type="Label" parent="."]
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
[ext_resource type="PackedScene" uid="uid://dfhkfocy8axb8" path="res://ui/menu_main/audio_settings.tscn" id="4_o07mg"]
|
[ext_resource type="PackedScene" uid="uid://dfhkfocy8axb8" path="res://ui/menu_main/audio_settings.tscn" id="4_o07mg"]
|
||||||
[ext_resource type="Script" uid="uid://dqq0wq3dvbnjs" path="res://dev-util/i18n_texture_rect.gd" id="5_8u0te"]
|
[ext_resource type="Script" uid="uid://dqq0wq3dvbnjs" path="res://dev-util/i18n_texture_rect.gd" id="5_8u0te"]
|
||||||
[ext_resource type="Script" uid="uid://0tb763w0vfv7" path="res://tab_container.gd" id="5_lhfti"]
|
[ext_resource type="Script" uid="uid://0tb763w0vfv7" path="res://tab_container.gd" id="5_lhfti"]
|
||||||
[ext_resource type="PackedScene" uid="uid://b3wlecqvelh22" path="res://ui/menu_main/acessability_settings.tscn" id="6_875a3"]
|
[ext_resource type="PackedScene" uid="uid://b3wlecqvelh22" path="res://ui/menu_main/accessibility_settings.tscn" id="6_875a3"]
|
||||||
[ext_resource type="Texture2D" uid="uid://bv1o2xo71wvp6" path="res://import/interface-elements/gedanken-spiel.png" id="6_g8g3n"]
|
[ext_resource type="Texture2D" uid="uid://bv1o2xo71wvp6" path="res://import/interface-elements/gedanken-spiel.png" id="6_g8g3n"]
|
||||||
[ext_resource type="PackedScene" uid="uid://dxwqkxq6qjk7i" path="res://ui/menu_main/gameplay_settings.tscn" id="6_p7ypt"]
|
[ext_resource type="PackedScene" uid="uid://dxwqkxq6qjk7i" path="res://ui/menu_main/gameplay_settings.tscn" id="6_p7ypt"]
|
||||||
[ext_resource type="PackedScene" uid="uid://chal0ioagspx0" path="res://ui/menu_main/content_settings.tscn" id="7_pnd48"]
|
[ext_resource type="PackedScene" uid="uid://chal0ioagspx0" path="res://ui/menu_main/content_settings.tscn" id="7_pnd48"]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue