diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2020-08-18 12:03:29 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2020-08-18 12:03:29 +0300 |
commit | de7470645a30e7bc6db67eff64d11778fb5ee3f2 (patch) | |
tree | 0e63bf0108c952ac7ada93a368cd1291d0555ac3 /release/scripts/modules | |
parent | 3f0e2dba681f04bb70e06328d5c6439ce1290896 (diff) | |
parent | be30023c68d463ec8d12b1b848bebf5fa7a2c288 (diff) |
Merge branch 'master' into greasepencil-edit-curve
Diffstat (limited to 'release/scripts/modules')
-rw-r--r-- | release/scripts/modules/nodeitems_utils.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/release/scripts/modules/nodeitems_utils.py b/release/scripts/modules/nodeitems_utils.py index 595b6c8ee5f..d1e1cc5e346 100644 --- a/release/scripts/modules/nodeitems_utils.py +++ b/release/scripts/modules/nodeitems_utils.py @@ -144,6 +144,14 @@ def node_categories_iter(context): yield cat +def has_node_categories(context): + for cat_type in _node_categories.values(): + for cat in cat_type[0]: + if cat.poll and ((context is None) or cat.poll(context)): + return True + return False + + def node_items_iter(context): for cat in node_categories_iter(context): for item in cat.items(context): |