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

Ignore property groups and categories in GDScript code completion

This commit is contained in:
Yuri Sizov
2021-10-26 19:48:47 +03:00
parent fa3fc6ff0d
commit b3fc278dcf
2 changed files with 7 additions and 1 deletions

View File

@@ -1511,6 +1511,12 @@ static bool _guess_identifier_type_from_base(GDScriptCompletionContext &p_contex
ClassDB::get_property_list(class_name, &props);
for (const List<PropertyInfo>::Element *E = props.front(); E; E = E->next()) {
const PropertyInfo &prop = E->get();
// Ignore groups and categories in code completion.
if (prop.usage & (PROPERTY_USAGE_GROUP | PROPERTY_USAGE_CATEGORY)) {
continue;
}
if (prop.name == p_identifier) {
StringName getter = ClassDB::get_property_getter(class_name, p_identifier);
if (getter != StringName()) {