mirror of
https://github.com/godotengine/godot.git
synced 2025-12-08 06:09:55 +00:00
Speed up large selections in the editor
This commit is contained in:
parent
a3b42d85d2
commit
1c8e3f9037
12 changed files with 111 additions and 86 deletions
|
|
@ -148,18 +148,20 @@ void MultiNodeEdit::_get_property_list(List<PropertyInfo> *p_list) const {
|
|||
F.name = F.name.replace_first("metadata/", "Metadata/"); // Trick to not get actual metadata edited from MultiNodeEdit.
|
||||
}
|
||||
|
||||
if (!usage.has(F.name)) {
|
||||
PLData *usage_data = usage.getptr(F.name);
|
||||
if (!usage_data) {
|
||||
PLData pld;
|
||||
pld.uses = 0;
|
||||
pld.info = F;
|
||||
pld.info.name = F.name;
|
||||
usage[F.name] = pld;
|
||||
data_list.push_back(usage.getptr(F.name));
|
||||
HashMap<String, MultiNodeEdit::PLData>::Iterator I = usage.insert(F.name, pld);
|
||||
usage_data = &I->value;
|
||||
data_list.push_back(usage_data);
|
||||
}
|
||||
|
||||
// Make sure only properties with the same exact PropertyInfo data will appear.
|
||||
if (usage[F.name].info == F) {
|
||||
usage[F.name].uses++;
|
||||
if (usage_data->info == F) {
|
||||
usage_data->uses++;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue