Merge pull request #19462 from volzhs/fix-autoload-dnd

Fix drag and drop autoload
This commit is contained in:
Max Hilbrunner 2018-06-09 19:21:15 +02:00 committed by GitHub
commit 0c2622a856
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -610,8 +610,8 @@ void EditorAutoloadSettings::drop_data_fw(const Point2 &p_point, const Variant &
i = 0;
for (List<AutoLoadInfo>::Element *E = autoload_cache.front(); E; E = E->next()) {
undo_redo->add_do_method(ProjectSettings::get_singleton(), "set_order", E->get().name, orders[i++]);
undo_redo->add_undo_method(ProjectSettings::get_singleton(), "set_order", E->get().name, E->get().order);
undo_redo->add_do_method(ProjectSettings::get_singleton(), "set_order", "autoload/" + E->get().name, orders[i++]);
undo_redo->add_undo_method(ProjectSettings::get_singleton(), "set_order", "autoload/" + E->get().name, E->get().order);
}
orders.clear();