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:
authorCampbell Barton <ideasman42@gmail.com>2016-05-01 06:27:59 +0300
committerCampbell Barton <ideasman42@gmail.com>2016-05-01 06:29:57 +0300
commit1b1aaf3e250e61768c8f7e8695392bbd3d86933e (patch)
tree7654b93de543393a79638e5d980410879ce21078
parent59ea4fc9f11f47922aaec7f48ea0f2633ad4dc80 (diff)
Cleanup: tabs to spaces
-rw-r--r--add_mesh_extra_objects/add_mesh_supertoroid.py5
-rw-r--r--io_mesh_pdb/import_pdb.py2
-rw-r--r--netrender/balancing.py15
-rw-r--r--object_fracture/fracture_ops.py60
-rw-r--r--space_view3d_materials_utils.py13
5 files changed, 48 insertions, 47 deletions
diff --git a/add_mesh_extra_objects/add_mesh_supertoroid.py b/add_mesh_extra_objects/add_mesh_supertoroid.py
index 895281e1..4728acec 100644
--- a/add_mesh_extra_objects/add_mesh_supertoroid.py
+++ b/add_mesh_extra_objects/add_mesh_supertoroid.py
@@ -23,7 +23,7 @@ def create_mesh_object(context, verts, edges, faces, name):
from bpy_extras import object_utils
return object_utils.object_data_add(context, mesh, operator=None)
-
+
# A very simple "bridge" tool.
def createFaces(vertIdx1, vertIdx2, closed=False, flipped=False):
@@ -80,7 +80,8 @@ def createFaces(vertIdx1, vertIdx2, closed=False, flipped=False):
faces.append(face)
return faces
-
+
+
def power(a,b):
if a < 0:
return -((-a)**b)
diff --git a/io_mesh_pdb/import_pdb.py b/io_mesh_pdb/import_pdb.py
index 5fb5890a..3ca3b51f 100644
--- a/io_mesh_pdb/import_pdb.py
+++ b/io_mesh_pdb/import_pdb.py
@@ -1036,7 +1036,7 @@ def draw_sticks_normal(all_atoms,
list_group_sub = []
counter = 0
for stick in all_sticks:
-
+
# The vectors of the two atoms
atom1 = all_atoms[stick.atom1-1].location-center
atom2 = all_atoms[stick.atom2-1].location-center
diff --git a/netrender/balancing.py b/netrender/balancing.py
index ee347452..b6531604 100644
--- a/netrender/balancing.py
+++ b/netrender/balancing.py
@@ -125,7 +125,8 @@ class RatingUsage(RatingRule):
"descritpiton":str(self),
"limit":"",
"id":self.id()
- }
+ }
+
class RatingUsageByCategory(RatingRule):
def __init__(self, get_jobs):
@@ -149,7 +150,7 @@ class RatingUsageByCategory(RatingRule):
"descritpiton":str(self),
"limit":"",
"id":self.id()
- }
+ }
class NewJobPriority(PriorityRule):
@@ -176,7 +177,7 @@ class NewJobPriority(PriorityRule):
"limit": self.limit,
"limit_str":self.str_limit(),
"id":self.id()
- }
+ }
class MinimumTimeBetweenDispatchPriority(PriorityRule):
def __init__(self, limit = 10):
@@ -203,8 +204,7 @@ class MinimumTimeBetweenDispatchPriority(PriorityRule):
"limit": self.limit,
"limit_str":self.str_limit(),
"id":self.id()
-
- }
+ }
class ExcludeQueuedEmptyJob(ExclusionRule):
def __init__(self):
@@ -224,7 +224,8 @@ class ExcludeQueuedEmptyJob(ExclusionRule):
"limit": "",
"limit_str":"",
"id":self.id()
- }
+ }
+
class ExcludeSlavesLimit(ExclusionRule):
def __init__(self, count_jobs, count_slaves, limit = 0.75):
@@ -253,4 +254,4 @@ class ExcludeSlavesLimit(ExclusionRule):
"limit": self.limit,
"limit_str":self.str_limit(),
"id":self.id()
- }
+ }
diff --git a/object_fracture/fracture_ops.py b/object_fracture/fracture_ops.py
index 69ec3202..f5687e3a 100644
--- a/object_fracture/fracture_ops.py
+++ b/object_fracture/fracture_ops.py
@@ -437,36 +437,36 @@ class FractureGroup(bpy.types.Operator):
# Import Functions
def import_object(obname):
- opath = "//data.blend\\Object\\" + obname
- s = os.sep
- #dpath = bpy.utils.script_paths()[0] + \
- # '%saddons%sobject_fracture%sdata.blend\\Object\\' % (s, s, s)
- dpath=''
- fpath=''
- for p in bpy.utils.script_paths():
-
- testfname= p + '%saddons%sobject_fracture%sdata.blend' % (s,s,s)
- print(testfname)
- if os.path.isfile(testfname):
- fname=testfname
- dpath = p + \
- '%saddons%sobject_fracture%sdata.blend\\Object\\' % (s, s, s)
- break
- # DEBUG
- #print('import_object: ' + opath)
-
- bpy.ops.wm.append(
- filepath=opath,
- filename=obname,
- directory=dpath,
- filemode=1,
- link=False,
- autoselect=True,
- active_layer=True,
- instance_groups=True)
-
- for ob in bpy.context.selected_objects:
- ob.location = bpy.context.scene.cursor_location
+ opath = "//data.blend\\Object\\" + obname
+ s = os.sep
+ #dpath = bpy.utils.script_paths()[0] + \
+ # '%saddons%sobject_fracture%sdata.blend\\Object\\' % (s, s, s)
+ dpath=''
+ fpath=''
+ for p in bpy.utils.script_paths():
+
+ testfname= p + '%saddons%sobject_fracture%sdata.blend' % (s,s,s)
+ print(testfname)
+ if os.path.isfile(testfname):
+ fname=testfname
+ dpath = p + \
+ '%saddons%sobject_fracture%sdata.blend\\Object\\' % (s, s, s)
+ break
+ # DEBUG
+ #print('import_object: ' + opath)
+
+ bpy.ops.wm.append(
+ filepath=opath,
+ filename=obname,
+ directory=dpath,
+ filemode=1,
+ link=False,
+ autoselect=True,
+ active_layer=True,
+ instance_groups=True)
+
+ for ob in bpy.context.selected_objects:
+ ob.location = bpy.context.scene.cursor_location
class ImportFractureRecorder(bpy.types.Operator):
diff --git a/space_view3d_materials_utils.py b/space_view3d_materials_utils.py
index 06dc6826..0e80e9f9 100644
--- a/space_view3d_materials_utils.py
+++ b/space_view3d_materials_utils.py
@@ -544,14 +544,13 @@ def texface_to_mat():
bpy.ops.object.mode_set(mode='EDIT')
def remove_materials():
+ for ob in bpy.data.objects:
+ try:
+ bpy.ops.object.material_slot_remove()
+ print ("removed material from " + ob.name)
+ except:
+ print (ob.name + " does not have materials.")
- for ob in bpy.data.objects:
- print (ob.name)
- try:
- bpy.ops.object.material_slot_remove()
- print ("removed material from " + ob.name)
- except:
- print (ob.name + " does not have materials.")
# -----------------------------------------------------------------------------
# operator classes: