Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set dynamics dialog to correct size after something is made visible … #1104

Merged
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/UI/GlobalToolOptions/DynamicsPanel.gd
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,13 @@ func _ready() -> void:
size_velocity_button.toggled.connect(
_on_dynamics_toggled.bind(size_velocity_button, SIZE, Tools.Dynamics.VELOCITY)
)
for child: Control in $VBoxContainer.get_children():
## Resets the y-size to an appropriate value
child.visibility_changed.connect(func ():
Variable-ind marked this conversation as resolved.
Show resolved Hide resolved
await get_tree().process_frame
set_size(Vector2i(size.x, 0))
set_size(Vector2i(size.x, size.y + 10))
)


func _input(event: InputEvent) -> void:
Expand Down
Loading