diff options
| author | Ignacio Etcheverry | 2017-10-11 13:54:34 +0200 |
|---|---|---|
| committer | GitHub | 2017-10-11 13:54:34 +0200 |
| commit | 740ef3dc9788d62fc07567149a3768e90af781ce (patch) | |
| tree | 6f0964e29cec7baa98932a658e38830472ee0cc0 /core/class_db.cpp | |
| parent | 45c878e3803c06361dfcad9d7a329ba12fc01570 (diff) | |
| parent | 9b6f65af82d02d1ec92de1d2d6250884de20cbf3 (diff) | |
| download | godot-740ef3dc9788d62fc07567149a3768e90af781ce.tar.gz godot-740ef3dc9788d62fc07567149a3768e90af781ce.tar.zst godot-740ef3dc9788d62fc07567149a3768e90af781ce.zip | |
Diffstat (limited to 'core/class_db.cpp')
| -rw-r--r-- | core/class_db.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/core/class_db.cpp b/core/class_db.cpp index f5ddd9c76..12310f615 100644 --- a/core/class_db.cpp +++ b/core/class_db.cpp @@ -205,6 +205,7 @@ ClassDB::ClassInfo::ClassInfo() { creation_func = NULL; inherits_ptr = NULL; disabled = false; + exposed = false; } ClassDB::ClassInfo::~ClassInfo() { } @@ -1284,6 +1285,15 @@ bool ClassDB::is_class_enabled(StringName p_class) { return !ti->disabled; } +bool ClassDB::is_class_exposed(StringName p_class) { + + OBJTYPE_RLOCK; + + ClassInfo *ti = classes.getptr(p_class); + ERR_FAIL_COND_V(!ti, false); + return ti->exposed; +} + StringName ClassDB::get_category(const StringName &p_node) { ERR_FAIL_COND_V(!classes.has(p_node), StringName()); |
