pedantic enum string consistancy
authorCampbell Barton <ideasman42@gmail.com>
Sat, 7 Nov 2009 22:12:03 +0000 (22:12 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Sat, 7 Nov 2009 22:12:03 +0000 (22:12 +0000)
release/scripts/op/vertexpaint_dirt.py
release/scripts/ui/properties_object_constraint.py
release/scripts/ui/properties_physics_field.py
release/scripts/ui/properties_render.py
release/scripts/ui/space_userpref.py
release/scripts/ui/space_view3d.py

index 7d32c153d0461c55e2d83408ee856d2fe95734d5..04398dfa8cec2a9bd45b310e366fb260b4c9e1cc 100644 (file)
@@ -117,7 +117,7 @@ def applyVertexDirt(me, blur_iterations, blur_strength, clamp_dirt, clamp_clean,
         active_col_layer = me.vertex_colors[0].data
 
     if not active_col_layer:
-        return("CANCELLED", )
+        return('CANCELLED', )
 
     for i, f in enumerate(me.faces):
         if not me.use_paint_mask or f.selected:
index 550b202f588716e1770dd40c287b6b8af672caf9..c662706743c65c926ed768d9e3a3ae77b2708be1 100644 (file)
@@ -133,7 +133,7 @@ class ConstraintButtonsPanel(bpy.types.Panel):
     def IK(self, context, layout, con):
         if context.object.pose.ik_solver == "ITASC":
             layout.itemR(con, "ik_type")
-            getattr(self, "IK_" + con.ik_type)(context, layout, con)
+            getattr(self, 'IK_' + con.ik_type)(context, layout, con)
         else:
             # Legacy IK constraint
             self.target_template(layout, con)
@@ -702,7 +702,7 @@ class BONE_PT_inverse_kinematics(ConstraintButtonsPanel):
         split.itemR(pchan, "ik_stretch", text="Stretch", slider=True)
         split.itemL()
 
-        if ob.pose.ik_solver == "ITASC":
+        if ob.pose.ik_solver == 'ITASC':
             row = layout.row()
             row.itemR(pchan, "ik_rot_control", text="Control Rotation")
             row.itemR(pchan, "ik_rot_weight", text="Weight", slider=True)
@@ -723,7 +723,7 @@ class BONE_PT_iksolver_itasc(ConstraintButtonsPanel):
 
         if ob and bone:
             pchan = ob.pose.pose_channels[bone.name]
-            return pchan.has_ik and ob.pose.ik_solver == "ITASC" and ob.pose.ik_param
+            return pchan.has_ik and ob.pose.ik_solver == 'ITASC' and ob.pose.ik_param
 
         return False
 
@@ -734,7 +734,7 @@ class BONE_PT_iksolver_itasc(ConstraintButtonsPanel):
         itasc = ob.pose.ik_param
 
         layout.itemR(itasc, "mode", expand=True)
-        simulation = itasc.mode == "SIMULATION"
+        simulation = itasc.mode == 'SIMULATION'
         if simulation:
             layout.itemL(text="Reiteration:")
             layout.itemR(itasc, "reiteration", expand=True)
@@ -742,7 +742,7 @@ class BONE_PT_iksolver_itasc(ConstraintButtonsPanel):
         flow = layout.column_flow()
         flow.itemR(itasc, "precision", text="Prec")
         flow.itemR(itasc, "num_iter", text="Iter")
-        flow.active = not simulation or itasc.reiteration != "NEVER"
+        flow.active = not simulation or itasc.reiteration != 'NEVER'
 
         if simulation:
             layout.itemR(itasc, "auto_step")
@@ -757,7 +757,7 @@ class BONE_PT_iksolver_itasc(ConstraintButtonsPanel):
         if simulation:
             layout.itemR(itasc, "feedback")
             layout.itemR(itasc, "max_velocity")
-        if itasc.solver == "DLS":
+        if itasc.solver == 'DLS':
             row = layout.row()
             row.itemR(itasc, "dampmax", text="Damp", slider=True)
             row.itemR(itasc, "dampeps", text="Eps", slider=True)
index b61f2172d94b1a6daa2fce5cc9c80692af228c3c..3e2630e38f53b4c02141689d744472023c1712fd 100644 (file)
@@ -77,7 +77,7 @@ class PHYSICS_PT_field(PhysicButtonsPanel):
             layout.itemS()
 
             layout.itemR(field, "guide_kink_type")
-            if (field.guide_kink_type != "NONE"):
+            if (field.guide_kink_type != 'NONE'):
                 layout.itemR(field, "guide_kink_axis")
 
                 flow = layout.column_flow()
index 6aafc8085023bde16f3767acbc698c601b1a6766..d1d512e189935cf59742fdb67771ef43c12611b6 100644 (file)
@@ -199,7 +199,7 @@ class RENDER_PT_performance(RenderButtonsPanel):
         sub.active = rd.render_raytracing
         sub.itemL(text="Acceleration structure:")
         sub.itemR(rd, "raytrace_structure", text="")
-        if rd.raytrace_structure == "OCTREE":
+        if rd.raytrace_structure == 'OCTREE':
             sub.itemR(rd, "octree_resolution", text="Resolution")
         else:
             sub.itemR(rd, "use_instances", text="Instances")
index 935e3b4087489a19f6e9a0d3f51a30533e514625..75fbfd7e8b9f129e8293c5a144ba947945d9b157 100644 (file)
@@ -1224,16 +1224,16 @@ class USERPREF_PT_input(bpy.types.Panel):
             row = subcol.row()
 
             if kmi.expanded:
-                row.itemR(kmi, "expanded", text="", icon="ICON_TRIA_DOWN")
+                row.itemR(kmi, "expanded", text="", icon='ICON_TRIA_DOWN')
             else:
-                row.itemR(kmi, "expanded", text="", icon="ICON_TRIA_RIGHT")
+                row.itemR(kmi, "expanded", text="", icon='ICON_TRIA_RIGHT')
 
             itemrow = row.row()
             itemrow.enabled = km.user_defined
             if kmi.active:
-                itemrow.itemR(kmi, "active", text="", icon="ICON_CHECKBOX_HLT")
+                itemrow.itemR(kmi, "active", text="", icon='ICON_CHECKBOX_HLT')
             else:
-                itemrow.itemR(kmi, "active", text="", icon="ICON_CHECKBOX_DEHLT")
+                itemrow.itemR(kmi, "active", text="", icon='ICON_CHECKBOX_DEHLT')
 
             itemcol = itemrow.column()
             itemcol.active = kmi.active
@@ -1290,11 +1290,11 @@ class USERPREF_PT_input(bpy.types.Panel):
 
                 itemcol.itemS()
 
-            itemrow.itemO("wm.keyitem_remove", text="", icon="ICON_ZOOMOUT")
+            itemrow.itemO("wm.keyitem_remove", text="", icon='ICON_ZOOMOUT')
 
         itemrow = col.row()
         itemrow.itemL()
-        itemrow.itemO("wm.keyitem_add", text="", icon="ICON_ZOOMIN")
+        itemrow.itemO("wm.keyitem_add", text="", icon='ICON_ZOOMIN')
         itemrow.enabled = km.user_defined
 
 bpy.types.register(USERPREF_HT_header)
@@ -1439,7 +1439,7 @@ class WM_OT_keyitem_add(bpy.types.Operator):
     def execute(self, context):
         wm = context.manager
         km = wm.active_keymap
-        kmi = km.add_item("", "A", "PRESS")
+        kmi = km.add_item("", 'A', 'PRESS')
         return ('FINISHED',)
 
 
index 2cb9864af12f2d300609d2d4491e1d425c5ea301..a3c2166d506419fd5ec28a33af71a4a34ee331ea 100644 (file)
@@ -1592,13 +1592,13 @@ class VIEW3D_PT_etch_a_ton(bpy.types.Panel):
 
         col.itemR(toolsettings, "etch_convert_mode")
 
-        if toolsettings.etch_convert_mode == "LENGTH":
+        if toolsettings.etch_convert_mode == 'LENGTH':
             col.itemR(toolsettings, "etch_length_limit")
-        elif toolsettings.etch_convert_mode == "ADAPTIVE":
+        elif toolsettings.etch_convert_mode == 'ADAPTIVE':
             col.itemR(toolsettings, "etch_adaptive_limit")
-        elif toolsettings.etch_convert_mode == "FIXED":
+        elif toolsettings.etch_convert_mode == 'FIXED':
             col.itemR(toolsettings, "etch_subdivision_number")
-        elif toolsettings.etch_convert_mode == "RETARGET":
+        elif toolsettings.etch_convert_mode == 'RETARGET':
             col.itemR(toolsettings, "etch_template")
             col.itemR(toolsettings, "etch_roll_mode")
             col.itemR(toolsettings, "etch_autoname")