pep8 edits and remove commented code from last commit.

This commit is contained in:
Campbell Barton 2011-03-14 23:17:52 +00:00
parent f2b1645a75
commit 82783cd0cd
8 changed files with 32 additions and 57 deletions

@ -78,7 +78,7 @@ def is_svn_file(filename):
def is_project_file(filename):
return (is_c_any(filename) or is_cmake(filename)) # and is_svn_file(filename)
return (is_c_any(filename) or is_cmake(filename)) # and is_svn_file(filename)
def cmake_advanced_info():
@ -185,7 +185,6 @@ def main():
includes = list(set(includes) | set(dirname(f) for f in files_rel if is_c_header(f)))
includes.sort()
PROJECT_NAME = "Blender"
f = open(join(base, "%s.files" % PROJECT_NAME), 'w')
f.write("\n".join(files_rel))

@ -28,6 +28,7 @@ StructMetaPropGroup = _bpy.StructMetaPropGroup
bpy_types.BlendDataLibraries.load = _bpy._library_load
class Context(StructRNA):
__slots__ = ()

@ -30,6 +30,7 @@
# but results are far more accurate
#
def applyVertexDirt(me, blur_iterations, blur_strength, clamp_dirt, clamp_clean, dirt_only):
from mathutils import Vector
from math import acos

@ -624,7 +624,6 @@ class MATERIAL_PT_physics(MaterialButtonsPanel, bpy.types.Panel):
row.prop(phys, "friction")
row.prop(phys, "elasticity", slider=True)
row = layout.row()
row.label(text="Force Field:")
@ -775,7 +774,6 @@ class MATERIAL_PT_shadow(MaterialButtonsPanel, bpy.types.Panel):
col.prop(mat, "use_cast_approximate")
class MATERIAL_PT_transp_game(MaterialButtonsPanel, bpy.types.Panel):
bl_label = "Transparency"
bl_options = {'DEFAULT_CLOSED'}

@ -790,4 +790,3 @@ def unregister():
if __name__ == "__main__":
register()

@ -533,7 +533,6 @@ class PARTICLE_PT_physics(ParticleButtonsPanel, bpy.types.Panel):
sub.prop(fluid, "use_initial_rest_length")
sub.prop(fluid, "spring_frames", text="Frames")
elif part.physics_type == 'KEYED':
split = layout.split()
sub = split.column()
@ -915,6 +914,7 @@ class PARTICLE_PT_render(ParticleButtonsPanel, bpy.types.Panel):
row.prop(part, "particle_size")
row.prop(part, "size_random", slider=True)
class PARTICLE_PT_draw(ParticleButtonsPanel, bpy.types.Panel):
bl_label = "Display"
bl_options = {'DEFAULT_CLOSED'}

@ -853,8 +853,6 @@ class USERPREF_PT_addons(bpy.types.Panel):
bl_region_type = 'WINDOW'
bl_options = {'HIDE_HEADER'}
# _addons_cats = None
# _addons_sups = None
_addons_fake_modules = {}
@classmethod
@ -875,27 +873,6 @@ class USERPREF_PT_addons(bpy.types.Panel):
# collect the categories that can be filtered on
addons = [(mod, addon_utils.module_bl_info(mod)) for mod in addon_utils.modules(USERPREF_PT_addons._addons_fake_modules)]
# XXX. we need dynamic enums to properly support this.
"""
cats = {info["category"] for mod, info in addons}
cats.discard("")
if USERPREF_PT_addons._addons_cats != cats:
bpy.types.WindowManager.addon_filter = EnumProperty(items=[(cat, cat, "") for cat in ["All", "Enabled", "Disabled"] + sorted(cats)], name="Category", description="Filter add-ons by category")
bpy.types.WindowManager.addon_search = StringProperty(name="Search", description="Search within the selected filter")
USERPREF_PT_addons._addons_cats = cats
[('All', 'All', ''), ('Enabled', 'Enabled', ''), ('Disabled', 'Disabled', ''), ('3D View', '3D View', ''), ('Add Curve', 'Add Curve', ''), ('Add Mesh', 'Add Mesh', ''), ('Animation', 'Animation', ''), ('Development', 'Development', ''), ('Game Engine', 'Game Engine', ''), ('Import-Export', 'Import-Export', ''), ('Mesh', 'Mesh', ''), ('Object', 'Object', ''), ('Render', 'Render', ''), ('Rigging', 'Rigging', ''), ('System', 'System', '')]
sups_default = {'OFFICIAL', 'COMMUNITY'}
sups = sups_default | {info["support"] for mod, info in addons}
sups.discard("")
if USERPREF_PT_addons._addons_sups != sups:
bpy.types.WindowManager.addon_support = EnumProperty(items=[(sup, sup.title(), "") for sup in reversed(sorted(sups))], name="Support", description="Display support level", default=sups_default, options={'ENUM_FLAG'})
USERPREF_PT_addons._addons_sups = sups
"""
split = layout.split(percentage=0.2)
col = split.column()
col.prop(context.window_manager, "addon_search", text="", icon='VIEWZOOM')