1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-05 12:10:55 +00:00

Use Ref<T> references as iterators where relevant

And const when possible.
This commit is contained in:
Rémi Verschelde
2021-07-26 17:50:35 +02:00
parent fef27e9b5b
commit 92299989bd
18 changed files with 62 additions and 83 deletions

View File

@@ -365,7 +365,7 @@ void SpriteFramesEditor::_file_load_request(const Vector<String> &p_path, int p_
int count = 0;
for (Ref<Texture2D> &E : resources) {
for (const Ref<Texture2D> &E : resources) {
undo_redo->add_do_method(frames, "add_frame", edited_anim, E, p_at_pos == -1 ? -1 : p_at_pos + count);
undo_redo->add_undo_method(frames, "remove_frame", edited_anim, p_at_pos == -1 ? fc : p_at_pos);
count++;