Merge pull request #46991 from madmiraal/rename-invert-reverse
Rename Array.invert() to Array.reverse()
This commit is contained in:
commit
4b6e9f3157
35 changed files with 57 additions and 57 deletions
|
|
@ -86,11 +86,11 @@ void DependencyEditor::_fix_and_find(EditorFileSystemDirectory *efsd, Map<String
|
|||
String lost = E->key().replace_first("res://", "");
|
||||
|
||||
Vector<String> existingv = existing.split("/");
|
||||
existingv.invert();
|
||||
existingv.reverse();
|
||||
Vector<String> currentv = current.split("/");
|
||||
currentv.invert();
|
||||
currentv.reverse();
|
||||
Vector<String> lostv = lost.split("/");
|
||||
lostv.invert();
|
||||
lostv.reverse();
|
||||
|
||||
int existing_score = 0;
|
||||
int current_score = 0;
|
||||
|
|
|
|||
|
|
@ -680,17 +680,17 @@ void FileSystemDock::_sort_file_info_list(List<FileSystemDock::FileInfo> &r_file
|
|||
break;
|
||||
case FILE_SORT_TYPE_REVERSE:
|
||||
r_file_list.sort_custom<FileInfoTypeComparator>();
|
||||
r_file_list.invert();
|
||||
r_file_list.reverse();
|
||||
break;
|
||||
case FILE_SORT_MODIFIED_TIME:
|
||||
r_file_list.sort_custom<FileInfoModifiedTimeComparator>();
|
||||
break;
|
||||
case FILE_SORT_MODIFIED_TIME_REVERSE:
|
||||
r_file_list.sort_custom<FileInfoModifiedTimeComparator>();
|
||||
r_file_list.invert();
|
||||
r_file_list.reverse();
|
||||
break;
|
||||
case FILE_SORT_NAME_REVERSE:
|
||||
r_file_list.invert();
|
||||
r_file_list.reverse();
|
||||
break;
|
||||
default: // FILE_SORT_NAME
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -2928,7 +2928,7 @@ void TileSetEditor::close_shape(const Vector2 &shape_anchor) {
|
|||
}
|
||||
|
||||
if (p_total < 0) {
|
||||
points.invert();
|
||||
points.reverse();
|
||||
}
|
||||
|
||||
shape->set_points(points);
|
||||
|
|
|
|||
|
|
@ -608,7 +608,7 @@ void SceneTreeDock::_tool_selected(int p_tool, bool p_confirm_override) {
|
|||
List<Node *> selection = editor_selection->get_selected_node_list();
|
||||
selection.sort_custom<Node::Comparator>(); // sort by index
|
||||
if (MOVING_DOWN) {
|
||||
selection.invert();
|
||||
selection.reverse();
|
||||
}
|
||||
|
||||
int lowest_id = common_parent->get_child_count() - 1;
|
||||
|
|
@ -1384,7 +1384,7 @@ void SceneTreeDock::fill_path_renames(Node *p_node, Node *p_new_parent, List<Pai
|
|||
base_path.push_back(n->get_name());
|
||||
n = n->get_parent();
|
||||
}
|
||||
base_path.invert();
|
||||
base_path.reverse();
|
||||
|
||||
Vector<StringName> new_base_path;
|
||||
if (p_new_parent) {
|
||||
|
|
@ -1394,7 +1394,7 @@ void SceneTreeDock::fill_path_renames(Node *p_node, Node *p_new_parent, List<Pai
|
|||
n = n->get_parent();
|
||||
}
|
||||
|
||||
new_base_path.invert();
|
||||
new_base_path.reverse();
|
||||
}
|
||||
|
||||
_fill_path_renames(base_path, new_base_path, p_node, p_renames);
|
||||
|
|
@ -1580,7 +1580,7 @@ void SceneTreeDock::_node_prerenamed(Node *p_node, const String &p_new_name) {
|
|||
base_path.push_back(n->get_name());
|
||||
n = n->get_parent();
|
||||
}
|
||||
base_path.invert();
|
||||
base_path.reverse();
|
||||
|
||||
Vector<StringName> new_base_path = base_path;
|
||||
base_path.push_back(p_node->get_name());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue