Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Gavrilov <angavrilov@gmail.com>2019-05-28 22:57:36 +0300
committerAlexander Gavrilov <angavrilov@gmail.com>2019-05-29 10:37:28 +0300
commit011f7afde41efc6fa16084e0f406f5287dc3c481 (patch)
tree3151da38ff4fffcd11483186af24cbcc400be4a1 /rigify/utils/__init__.py
parent68bb42ef065c5c95a21493ebd5469b8a21af75ae (diff)
Rigify: refactor feature sets to avoid modifying global path.
Instead of adding the feature set installation directory to the global path, and thus inserting the modules into the top level namespace, add an empty rigify.feature_sets package and use __path__ to redirect the module loader to read its sub-modules from the feature set directory. Now feature set modules are effectively installed into that package and loaded as 'rigify.feature_sets.foo'. As an aside, clean up loading code to avoid weird path manipulations, add more safety checks when installing sets, and add a way for sets to expose a user-friendly name.
Diffstat (limited to 'rigify/utils/__init__.py')
-rw-r--r--rigify/utils/__init__.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/rigify/utils/__init__.py b/rigify/utils/__init__.py
index da4689a9..9fa6a3d2 100644
--- a/rigify/utils/__init__.py
+++ b/rigify/utils/__init__.py
@@ -24,8 +24,8 @@ from .widgets_special import create_neck_bend_widget, create_neck_tweak_widget
from .animation import get_keyed_frames, bones_in_frame, overwrite_prop_animation
-from .rig import RIG_DIR, METARIG_DIR, MODULE_NAME, TEMPLATE_DIR, outdated_types, upgradeMetarigTypes
-from .rig import get_rig_type, get_metarig_module, write_metarig, get_resource
+from .rig import RIG_DIR, METARIG_DIR, TEMPLATE_DIR, outdated_types, upgradeMetarigTypes
+from .rig import write_metarig, get_resource
from .rig import connected_children_names, has_connected_children
from .layers import get_layers, ControlLayersOption