diff options
author | Campbell Barton <campbell@blender.org> | 2022-03-30 03:27:54 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-03-30 03:27:54 +0300 |
commit | be8270bc76ef873adb646b97abcf925beae90137 (patch) | |
tree | bb89ddd11be480880bc417e4df2743dc610b0937 /release/scripts/templates_py | |
parent | 87e5c4230f9a90ffcd86c04479d67ae240da3e9a (diff) |
Cleanup: use equality instead of contains for single-item sets
Diffstat (limited to 'release/scripts/templates_py')
-rw-r--r-- | release/scripts/templates_py/ui_list.py | 2 | ||||
-rw-r--r-- | release/scripts/templates_py/ui_list_simple.py | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/release/scripts/templates_py/ui_list.py b/release/scripts/templates_py/ui_list.py index f6b82356a78..9727a1b3678 100644 --- a/release/scripts/templates_py/ui_list.py +++ b/release/scripts/templates_py/ui_list.py @@ -18,7 +18,7 @@ class MESH_UL_mylist(bpy.types.UIList): if self.layout_type in {'DEFAULT', 'COMPACT'}: pass # 'GRID' layout type should be as compact as possible (typically a single icon!). - elif self.layout_type in {'GRID'}: + elif self.layout_type == 'GRID': pass # Called once to draw filtering/reordering options. diff --git a/release/scripts/templates_py/ui_list_simple.py b/release/scripts/templates_py/ui_list_simple.py index ac3f2b984de..c3efe16058a 100644 --- a/release/scripts/templates_py/ui_list_simple.py +++ b/release/scripts/templates_py/ui_list_simple.py @@ -29,7 +29,7 @@ class MATERIAL_UL_matslots_example(bpy.types.UIList): else: layout.label(text="", translate=False, icon_value=icon) # 'GRID' layout type should be as compact as possible (typically a single icon!). - elif self.layout_type in {'GRID'}: + elif self.layout_type == 'GRID': layout.alignment = 'CENTER' layout.label(text="", icon_value=icon) |