[Bf-blender-cvs] [e6825946d05] blender2.8: Cleanup: style, pep8

Campbell Barton noreply at git.blender.org
Tue Jun 26 08:45:56 CEST 2018


Commit: e6825946d057f077f5473366b4fa4d383484a81c
Author: Campbell Barton
Date:   Tue Jun 26 08:45:13 2018 +0200
Branches: blender2.8
https://developer.blender.org/rBe6825946d057f077f5473366b4fa4d383484a81c

Cleanup: style, pep8

===================================================================

M	release/scripts/startup/bl_ui/properties_data_lightprobe.py
M	release/scripts/startup/bl_ui/properties_material.py
M	release/scripts/startup/bl_ui/properties_particle.py
M	release/scripts/startup/bl_ui/properties_physics_common.py
M	release/scripts/startup/bl_ui/space_outliner.py
M	release/scripts/startup/bl_ui/space_view3d.py

===================================================================

diff --git a/release/scripts/startup/bl_ui/properties_data_lightprobe.py b/release/scripts/startup/bl_ui/properties_data_lightprobe.py
index f3ccc9f3176..10b66dd0033 100644
--- a/release/scripts/startup/bl_ui/properties_data_lightprobe.py
+++ b/release/scripts/startup/bl_ui/properties_data_lightprobe.py
@@ -155,7 +155,7 @@ class DATA_PT_lightprobe_display(DataButtonsPanel, Panel):
 
         col = layout.column()
 
-        if probe.type != "PLANAR":
+        if probe.type != 'PLANAR':
             col.prop(probe, "data_draw_size", text="Size")
         else:
             col.prop(ob, "empty_draw_size", text="Arrow Size")
diff --git a/release/scripts/startup/bl_ui/properties_material.py b/release/scripts/startup/bl_ui/properties_material.py
index 2b298c560c7..fdbf0b240c4 100644
--- a/release/scripts/startup/bl_ui/properties_material.py
+++ b/release/scripts/startup/bl_ui/properties_material.py
@@ -198,14 +198,14 @@ class EEVEE_MATERIAL_PT_options(MaterialButtonsPanel, Panel):
 
         layout.prop(mat, "blend_method")
 
-        if mat.blend_method != "OPAQUE":
+        if mat.blend_method != 'OPAQUE':
             layout.prop(mat, "transparent_shadow_method")
 
             row = layout.row()
-            row.active = ((mat.blend_method == "CLIP") or (mat.transparent_shadow_method == "CLIP"))
+            row.active = ((mat.blend_method == 'CLIP') or (mat.transparent_shadow_method == 'CLIP'))
             row.prop(mat, "alpha_threshold")
 
-        if mat.blend_method not in {"OPAQUE", "CLIP", "HASHED"}:
+        if mat.blend_method not in {'OPAQUE', 'CLIP', 'HASHED'}:
             layout.prop(mat, "show_transparent_backside")
 
         layout.prop(mat, "use_screen_refraction")
diff --git a/release/scripts/startup/bl_ui/properties_particle.py b/release/scripts/startup/bl_ui/properties_particle.py
index c521c59a79d..fbc053a565f 100644
--- a/release/scripts/startup/bl_ui/properties_particle.py
+++ b/release/scripts/startup/bl_ui/properties_particle.py
@@ -1738,7 +1738,6 @@ class PARTICLE_PT_force_fields_type1(ParticleButtonsPanel, Panel):
         basic_force_field_settings_ui(self, context, part.force_field_1)
 
 
-
 class PARTICLE_PT_force_fields_type2(ParticleButtonsPanel, Panel):
     bl_label = "Type 2"
     bl_parent_id = "PARTICLE_PT_force_fields"
@@ -1770,14 +1769,12 @@ class PARTICLE_PT_force_fields_type1_falloff(ParticleButtonsPanel, Panel):
         basic_force_field_falloff_ui(self, context, part.force_field_1)
 
 
-
 class PARTICLE_PT_force_fields_type2_falloff(ParticleButtonsPanel, Panel):
     bl_label = "Falloff"
     bl_options = {'DEFAULT_CLOSED'}
     bl_parent_id = "PARTICLE_PT_force_fields_type2"
     COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE'}
 
-
     def draw(self, context):
         layout = self.layout
         layout.use_property_split = True
diff --git a/release/scripts/startup/bl_ui/properties_physics_common.py b/release/scripts/startup/bl_ui/properties_physics_common.py
index 08197293700..e071de0108b 100644
--- a/release/scripts/startup/bl_ui/properties_physics_common.py
+++ b/release/scripts/startup/bl_ui/properties_physics_common.py
@@ -280,7 +280,6 @@ def basic_force_field_settings_ui(self, context, field):
     if field.type == 'FORCE':
         col.prop(field, "use_gravity_falloff", text="Gravitation")
 
-
     col.prop(field, "apply_to_location", text="Affect Location")
     col.prop(field, "apply_to_rotation", text="Affect Rotation")
     col.prop(field, "use_absorption")
diff --git a/release/scripts/startup/bl_ui/space_outliner.py b/release/scripts/startup/bl_ui/space_outliner.py
index df48d17274d..44813b699a2 100644
--- a/release/scripts/startup/bl_ui/space_outliner.py
+++ b/release/scripts/startup/bl_ui/space_outliner.py
@@ -38,7 +38,7 @@ class OUTLINER_HT_header(Header):
         layout.prop(space, "display_mode", icon_only=True)
 
         if display_mode in {'VIEW_LAYER'}:
-            layout.operator("outliner.collection_new", text="", icon="GROUP").nested = True
+            layout.operator("outliner.collection_new", text="", icon='GROUP').nested = True
 
         layout.separator_spacer()
 
diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py
index dda52a98299..0f44eea1629 100644
--- a/release/scripts/startup/bl_ui/space_view3d.py
+++ b/release/scripts/startup/bl_ui/space_view3d.py
@@ -2646,7 +2646,7 @@ class VIEW3D_MT_edit_mesh_specials(Menu):
             layout.operator("mesh.merge", text="Merge Vertices...")
             layout.operator("mesh.remove_doubles", text="Remove Double Vertices")
             layout.operator("mesh.dissolve_verts")
-            layout.operator("mesh.delete", text="Delete Vertices").type = "VERT"
+            layout.operator("mesh.delete", text="Delete Vertices").type = 'VERT'
 
         # Edge Select Commands
         if select_mode[1]:
@@ -2657,7 +2657,7 @@ class VIEW3D_MT_edit_mesh_specials(Menu):
             layout.separator()
 
             layout.operator("mesh.dissolve_edges")
-            layout.operator("mesh.delete", text="Delete Edges").type = "EDGE"
+            layout.operator("mesh.delete", text="Delete Edges").type = 'EDGE'
 
         # Face Select Commands
         if select_mode[2]:
@@ -2687,7 +2687,7 @@ class VIEW3D_MT_edit_mesh_specials(Menu):
             layout.separator()
 
             layout.operator("mesh.dissolve_faces")
-            layout.operator("mesh.delete", text="Delete Faces").type = "FACE"
+            layout.operator("mesh.delete", text="Delete Faces").type = 'FACE'
 
         # General Mesh Commands
 
@@ -3785,7 +3785,7 @@ class VIEW3D_PT_overlay(Panel):
         #sub.prop(overlay, "show_onion_skins")
         sub.prop(overlay, "show_face_orientation")
         sub.prop(overlay, "show_backface_culling")
-        if shading.type == "MATERIAL":
+        if shading.type == 'MATERIAL':
             sub.prop(overlay, "show_look_dev")
 
         row = col.row()
@@ -4030,9 +4030,9 @@ class VIEW3D_PT_overlay_paint(Panel):
     def draw_header(self, context):
         layout = self.layout
         layout.label(text={
-            "PAINT_TEXTURE": "Texture Paint",
-            "PAINT_VERTEX":  "Vertex Paint",
-            "PAINT_WEIGHT":  "Weight Paint",
+            'PAINT_TEXTURE': "Texture Paint",
+            'PAINT_VERTEX': "Vertex Paint",
+            'PAINT_WEIGHT': "Weight Paint",
         }[context.mode])
 
     def draw(self, context):
@@ -4044,11 +4044,10 @@ class VIEW3D_PT_overlay_paint(Panel):
         col = layout.column()
         col.active = display_all
 
-
         col.prop(overlay, {
-            "PAINT_TEXTURE": "texture_paint_mode_opacity",
-            "PAINT_VERTEX":  "vertex_paint_mode_opacity",
-            "PAINT_WEIGHT":  "weight_paint_mode_opacity",
+            'PAINT_TEXTURE': "texture_paint_mode_opacity",
+            'PAINT_VERTEX': "vertex_paint_mode_opacity",
+            'PAINT_WEIGHT': "weight_paint_mode_opacity",
         }[context.mode], text="Opacity")
 
         if context.mode in {'PAINT_WEIGHT', 'PAINT_VERTEX'}:



More information about the Bf-blender-cvs mailing list