summaryrefslogtreecommitdiffstats
path: root/editor/animation_track_editor.cpp
diff options
context:
space:
mode:
authorSamuele Panzeri <samuele.panzeri@gmail.com>2023-04-16 11:08:53 +0200
committerSamuele Panzeri <samuele.panzeri@gmail.com>2023-04-22 18:34:36 +0200
commitb6abb347595faa7bad57afff1f10e8c7b8528e5d (patch)
tree6c204922047b068d24a1bcb35405f40dec02453e /editor/animation_track_editor.cpp
parentafca0b8fdd07ff2e50f421a0e5424897cff1eb77 (diff)
downloadredot-engine-b6abb347595faa7bad57afff1f10e8c7b8528e5d.tar.gz
Fix editor spin slider remaining editable if set read_only during an edit and fix related animation player crash
Diffstat (limited to 'editor/animation_track_editor.cpp')
-rw-r--r--editor/animation_track_editor.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/editor/animation_track_editor.cpp b/editor/animation_track_editor.cpp
index 1ca161bd43..c6acf99872 100644
--- a/editor/animation_track_editor.cpp
+++ b/editor/animation_track_editor.cpp
@@ -4639,6 +4639,10 @@ void AnimationTrackEditor::_update_scroll(double) {
}
void AnimationTrackEditor::_update_step(double p_new_step) {
+ if (animation.is_null()) {
+ return;
+ }
+
EditorUndoRedoManager *undo_redo = EditorUndoRedoManager::get_singleton();
undo_redo->create_action(TTR("Change Animation Step"));
float step_value = p_new_step;