Cleanup: use static set instead of list

This commit is contained in:
Campbell Barton 2019-08-27 19:17:28 +10:00
parent 90751d1835
commit ebe7a407d7
3 changed files with 4 additions and 4 deletions

@ -178,7 +178,7 @@ def complete(line):
words = line.split(' ')
if len(words) == 3 and words[0] == 'from':
return ['import ']
if len(words) < 3 and (words[0] in ['import', 'from']):
if len(words) < 3 and (words[0] in {'import', 'from'}):
if len(words) == 1:
return get_root_modules()
mod = words[1].split('.')

@ -1880,7 +1880,7 @@ class SEQUENCER_PT_preview(SequencerButtonsPanel_Output, Panel):
col = layout.column()
col.prop(render, "sequencer_gl_preview", text="Preview Shading")
if render.sequencer_gl_preview in ['SOLID', 'WIREFRAME']:
if render.sequencer_gl_preview in {'SOLID', 'WIREFRAME'}:
col.prop(render, "use_sequencer_override_scene_strip")

@ -5253,7 +5253,7 @@ class VIEW3D_PT_shading_options(Panel):
if shading.type == 'SOLID':
col = layout.column()
if (shading.light in ['STUDIO', 'MATCAP']):
if shading.light in {'STUDIO', 'MATCAP'}:
col.active = shading.selected_studio_light.has_specular_highlight_pass
col.prop(shading, "show_specular_highlight", text="Specular Lighting")
@ -6389,7 +6389,7 @@ class VIEW3D_MT_gpencil_edit_context_menu(Menu):
col.operator("gpencil.stroke_separate", text="Separate").mode = 'STROKE'
col.separator()
col.operator("gpencil.delete", text="Delete Strokes").type = 'STROKES'
col.separator()