[gd_scene load_steps=3 format=3 uid="uid://c6je8lgr850wf"]

[ext_resource type="Script" path="res://src/UI/Timeline/FrameTagDialog.gd" id="1"]
[ext_resource type="Texture2D" uid="uid://d1urikaf1lxwl" path="res://assets/graphics/timeline/new_frame.png" id="2"]

[node name="FrameTagDialog" type="AcceptDialog"]
title = "Frame Tag Properties"
size = Vector2i(413, 300)
exclusive = false
popup_window = true
script = ExtResource("1")

[node name="VBoxContainer" type="VBoxContainer" parent="."]
custom_minimum_size = Vector2(0, 100)
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
offset_left = 8.0
offset_top = 8.0
offset_right = -8.0
offset_bottom = -49.0

[node name="ScrollContainer" type="ScrollContainer" parent="VBoxContainer"]
layout_mode = 2
size_flags_horizontal = 3
size_flags_vertical = 3

[node name="VBoxTagContainer" type="VBoxContainer" parent="VBoxContainer/ScrollContainer"]
layout_mode = 2
size_flags_horizontal = 3

[node name="HSeparator" type="HSeparator" parent="VBoxContainer/ScrollContainer/VBoxTagContainer"]
layout_mode = 2
size_flags_horizontal = 3

[node name="AddTag" type="Button" parent="VBoxContainer/ScrollContainer/VBoxTagContainer" groups=["UIButtons"]]
custom_minimum_size = Vector2(20, 20)
layout_mode = 2
size_flags_horizontal = 0
size_flags_vertical = 0
tooltip_text = "Add a new frame tag"
mouse_default_cursor_shape = 2

[node name="TextureRect" type="TextureRect" parent="VBoxContainer/ScrollContainer/VBoxTagContainer/AddTag"]
layout_mode = 0
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -6.0
offset_top = -6.0
offset_right = 6.0
offset_bottom = 6.0
texture = ExtResource("2")

[node name="PlayOnlyTags" type="CheckBox" parent="VBoxContainer"]
layout_mode = 2
size_flags_horizontal = 0
tooltip_text = "If it's selected, the animation plays only on the frames that have the same tag.
If it's not, the animation will play for all frames, ignoring tags."
mouse_default_cursor_shape = 2
button_pressed = true
text = "Animation plays only on frames of the same tag"

[node name="TagOptions" type="ConfirmationDialog" parent="."]
size = Vector2i(303, 127)
exclusive = false
popup_window = true

[node name="GridContainer" type="GridContainer" parent="TagOptions"]
offset_left = 8.0
offset_top = 8.0
offset_right = 295.0
offset_bottom = 78.0
theme_override_constants/h_separation = 8
theme_override_constants/v_separation = 8
columns = 4

[node name="NameLabel" type="Label" parent="TagOptions/GridContainer"]
layout_mode = 2
text = "Name:"

[node name="NameLineEdit" type="LineEdit" parent="TagOptions/GridContainer"]
layout_mode = 2
caret_blink = true
caret_blink_interval = 0.5

[node name="ColorLabel" type="Label" parent="TagOptions/GridContainer"]
layout_mode = 2
text = "Color:"

[node name="ColorPickerButton" type="ColorPickerButton" parent="TagOptions/GridContainer"]
layout_mode = 2
mouse_default_cursor_shape = 2
color = Color(1, 0, 0, 1)

[node name="FromLabel" type="Label" parent="TagOptions/GridContainer"]
layout_mode = 2
text = "From:"

[node name="FromSpinBox" type="SpinBox" parent="TagOptions/GridContainer"]
layout_mode = 2
mouse_default_cursor_shape = 2
min_value = 1.0
value = 1.0
allow_greater = true

[node name="ToLabel" type="Label" parent="TagOptions/GridContainer"]
layout_mode = 2
text = "To:"

[node name="ToSpinBox" type="SpinBox" parent="TagOptions/GridContainer"]
layout_mode = 2
mouse_default_cursor_shape = 2
min_value = 1.0
value = 1.0
allow_greater = true

[connection signal="about_to_popup" from="." to="." method="_on_FrameTagDialog_about_to_show"]
[connection signal="visibility_changed" from="." to="." method="_on_FrameTagDialog_visibility_changed"]
[connection signal="pressed" from="VBoxContainer/ScrollContainer/VBoxTagContainer/AddTag" to="." method="_on_AddTag_pressed"]
[connection signal="toggled" from="VBoxContainer/PlayOnlyTags" to="." method="_on_PlayOnlyTags_toggled"]
[connection signal="confirmed" from="TagOptions" to="." method="_on_TagOptions_confirmed"]
[connection signal="custom_action" from="TagOptions" to="." method="_on_TagOptions_custom_action"]
[connection signal="visibility_changed" from="TagOptions" to="." method="_on_TagOptions_visibility_changed"]
