diff options
author | Campbell Barton <ideasman42@gmail.com> | 2016-01-31 16:47:10 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2016-01-31 16:47:10 +0300 |
commit | d924998d3e65334c5db2257c5dc4335261adc288 (patch) | |
tree | 2b46006f90936cd859972c0dc4174a3deab21bcf /release/scripts/modules/bpy_extras | |
parent | 0f3f117311d25805fa1591aa2eed3240e50c4a6f (diff) |
Cleanup: pep8
Diffstat (limited to 'release/scripts/modules/bpy_extras')
-rw-r--r-- | release/scripts/modules/bpy_extras/image_utils.py | 8 | ||||
-rw-r--r-- | release/scripts/modules/bpy_extras/io_utils.py | 6 |
2 files changed, 9 insertions, 5 deletions
diff --git a/release/scripts/modules/bpy_extras/image_utils.py b/release/scripts/modules/bpy_extras/image_utils.py index ad774cd1bda..f197596fec0 100644 --- a/release/scripts/modules/bpy_extras/image_utils.py +++ b/release/scripts/modules/bpy_extras/image_utils.py @@ -62,11 +62,13 @@ def load_image(imagepath, :type convert_callback: function :arg relpath: If not None, make the file relative to this path. :type relpath: None or string - :arg check_existing: If true, returns already loaded image datablock if possible + :arg check_existing: If true, + returns already loaded image datablock if possible (based on file path). :type check_existing: bool - :arg force_reload: If true, force reloading of image (only useful when `check_existing` - is also enabled). + :arg force_reload: If true, + force reloading of image (only useful when `check_existing` + is also enabled). :type force_reload: bool :return: an image or None :rtype: :class:`bpy.types.Image` diff --git a/release/scripts/modules/bpy_extras/io_utils.py b/release/scripts/modules/bpy_extras/io_utils.py index 65ccc3f8dc3..a7ecd0b80c0 100644 --- a/release/scripts/modules/bpy_extras/io_utils.py +++ b/release/scripts/modules/bpy_extras/io_utils.py @@ -137,7 +137,8 @@ def orientation_helper_factory(name, axis_forward='Y', axis_up='Z'): def _update_axis_forward(self, context): if self.axis_forward[-1] == self.axis_up[-1]: - self.axis_up = self.axis_up[0:-1] + 'XYZ'[('XYZ'.index(self.axis_up[-1]) + 1) % 3] + self.axis_up = (self.axis_up[0:-1] + + 'XYZ'[('XYZ'.index(self.axis_up[-1]) + 1) % 3]) members['axis_forward'] = EnumProperty( name="Forward", @@ -154,7 +155,8 @@ def orientation_helper_factory(name, axis_forward='Y', axis_up='Z'): def _update_axis_up(self, context): if self.axis_up[-1] == self.axis_forward[-1]: - self.axis_forward = self.axis_forward[0:-1] + 'XYZ'[('XYZ'.index(self.axis_forward[-1]) + 1) % 3] + self.axis_forward = (self.axis_forward[0:-1] + + 'XYZ'[('XYZ'.index(self.axis_forward[-1]) + 1) % 3]) members['axis_up'] = EnumProperty( name="Up", |