Changeset View
Changeset View
Standalone View
Standalone View
rigify/ui.py
| Show All 29 Lines | |||||
| from .utils import MetarigError | from .utils import MetarigError | ||||
| from .utils import write_metarig, write_widget | from .utils import write_metarig, write_widget | ||||
| from .utils import unique_name | from .utils import unique_name | ||||
| from .utils import upgradeMetarigTypes, outdated_types | from .utils import upgradeMetarigTypes, outdated_types | ||||
| from .utils import get_keyed_frames, bones_in_frame | from .utils import get_keyed_frames, bones_in_frame | ||||
| from .utils import overwrite_prop_animation | from .utils import overwrite_prop_animation | ||||
| from .rigs.utils import get_limb_generated_names | from .rigs.utils import get_limb_generated_names | ||||
| from . import base_rig | |||||
| from . import rig_lists | from . import rig_lists | ||||
| from . import generate | from . import generate | ||||
| from . import rot_mode | from . import rot_mode | ||||
| from . import feature_sets | from . import feature_sets | ||||
| def build_type_list(context, rigify_types): | def build_type_list(context, rigify_types): | ||||
| rigify_types.clear() | rigify_types.clear() | ||||
| ▲ Show 20 Lines • Show All 562 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| if rig_name != "": | if rig_name != "": | ||||
| try: | try: | ||||
| rig = rig_lists.rigs[rig_name]['module'] | rig = rig_lists.rigs[rig_name]['module'] | ||||
| except (ImportError, AttributeError): | except (ImportError, AttributeError): | ||||
| row = layout.row() | row = layout.row() | ||||
| box = row.box() | box = row.box() | ||||
| box.label(text="ALERT: type \"%s\" does not exist!" % rig_name) | box.label(text="ALERT: type \"%s\" does not exist!" % rig_name) | ||||
| else: | else: | ||||
| if issubclass(rig.Rig, base_rig.BaseRig): | |||||
| rig = rig.Rig | |||||
| try: | try: | ||||
| rig.parameters_ui | rig.parameters_ui | ||||
| except AttributeError: | except AttributeError: | ||||
| col = layout.column() | col = layout.column() | ||||
| col.label(text="No options") | col.label(text="No options") | ||||
| else: | else: | ||||
| col = layout.column() | col = layout.column() | ||||
| col.label(text="Options:") | col.label(text="Options:") | ||||
| ▲ Show 20 Lines • Show All 755 Lines • Show Last 20 Lines | |||||