diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-04-25 00:02:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-25 00:02:29 +0200 |
commit | 10e5427cc272a53ec01743cc9a78393613d0af3f (patch) | |
tree | 1a3ab1c27e473c0389e61d0fe358db316fabbe83 /editor/animation_track_editor.cpp | |
parent | 1cf82f6f90e86791437a67be26f0f5a9a5823ce9 (diff) | |
parent | b081e954cc70ef08f3ea833bfe4698b0e80a0f5b (diff) |
Merge pull request #38165 from YeldhamDev/multitrack_time_fix
Fix crash when changing time value of multiple animation keys at once via inspector
Diffstat (limited to 'editor/animation_track_editor.cpp')
-rw-r--r-- | editor/animation_track_editor.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/editor/animation_track_editor.cpp b/editor/animation_track_editor.cpp index f10e439f10..b7c8769f64 100644 --- a/editor/animation_track_editor.cpp +++ b/editor/animation_track_editor.cpp @@ -754,14 +754,17 @@ public: for (Map<int, List<float>>::Element *E = key_ofs_map.front(); E; E = E->next()) { + int key = 0; for (List<float>::Element *F = E->value().front(); F; F = F->next()) { float key_ofs = F->get(); - if (from != key_ofs) + if (from != key_ofs) { + key++; continue; + } int track = E->key(); - key_ofs_map[track][key_ofs] = to; + key_ofs_map[track][key] = to; if (setting) return; |