[gd_scene load_steps=6 format=3 uid="uid://bbnqcxa20a5a5"]

[ext_resource type="Script" path="res://src/UI/Nodes/Sliders/ValueSlider.gd" id="1"]
[ext_resource type="Script" path="res://src/UI/Nodes/Sliders/ValueSliderV2.gd" id="2"]
[ext_resource type="Texture2D" uid="uid://cancw70yw0pv7" path="res://assets/graphics/misc/lock_aspect_2.png" id="3"]
[ext_resource type="Texture2D" uid="uid://kd10jfc1dxf5" path="res://assets/graphics/misc/lock_aspect_guides.png" id="4"]
[ext_resource type="Texture2D" uid="uid://beqermx8s5q8y" path="res://assets/graphics/misc/lock_aspect.png" id="5"]

[node name="ValueSliderV2" type="HBoxContainer"]
offset_right = 45.0
offset_bottom = 52.0
script = ExtResource("2")

[node name="GridContainer" type="GridContainer" parent="."]
layout_mode = 2
size_flags_horizontal = 3

[node name="X" type="TextureProgressBar" parent="GridContainer"]
custom_minimum_size = Vector2(32, 24)
layout_mode = 2
size_flags_horizontal = 3
focus_mode = 2
mouse_default_cursor_shape = 2
theme_type_variation = &"ValueSlider"
nine_patch_stretch = true
stretch_margin_left = 3
stretch_margin_top = 3
stretch_margin_right = 3
stretch_margin_bottom = 3
script = ExtResource("1")
prefix = "X:"

[node name="Y" type="TextureProgressBar" parent="GridContainer"]
custom_minimum_size = Vector2(32, 24)
layout_mode = 2
size_flags_horizontal = 3
focus_mode = 2
mouse_default_cursor_shape = 2
theme_type_variation = &"ValueSlider"
nine_patch_stretch = true
stretch_margin_left = 3
stretch_margin_top = 3
stretch_margin_right = 3
stretch_margin_bottom = 3
script = ExtResource("1")
prefix = "Y:"

[node name="Ratio" type="Control" parent="."]
visible = false
custom_minimum_size = Vector2(16, 0)
layout_mode = 2

[node name="RatioGuides" type="NinePatchRect" parent="Ratio" groups=["UIButtons"]]
custom_minimum_size = Vector2(9, 0)
layout_mode = 0
anchor_bottom = 1.0
offset_right = 9.0
texture = ExtResource("4")
region_rect = Rect2(0, 0, 9, 44)
patch_margin_top = 15
patch_margin_bottom = 13

[node name="RatioButton" type="TextureButton" parent="Ratio" groups=["UIButtons"]]
unique_name_in_owner = true
layout_mode = 0
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -8.0
offset_top = -8.0
offset_right = 8.0
offset_bottom = 8.0
tooltip_text = "Lock aspect ratio"
mouse_default_cursor_shape = 2
toggle_mode = true
texture_normal = ExtResource("3")
texture_pressed = ExtResource("5")

[connection signal="value_changed" from="GridContainer/X" to="." method="_on_X_value_changed"]
[connection signal="value_changed" from="GridContainer/Y" to="." method="_on_Y_value_changed"]
[connection signal="toggled" from="Ratio/RatioButton" to="." method="_on_RatioButton_toggled"]
