GPencil: Rename old color operators to material

The color was used in old version when palettes were used, but now all are materials
This commit is contained in:
Antonio Vazquez
2020-03-17 18:29:18 +01:00
parent bf9c4af9bb
commit f1eb86c458
5 changed files with 66 additions and 66 deletions

View File

@@ -605,7 +605,7 @@ class GreasePencilMaterialsPanel:
col.separator()
col.menu("GPENCIL_MT_color_context_menu", icon='DOWNARROW_HLT', text="")
col.menu("GPENCIL_MT_material_context_menu", icon='DOWNARROW_HLT', text="")
if is_sortable:
col.separator()
@@ -616,8 +616,8 @@ class GreasePencilMaterialsPanel:
col.separator()
sub = col.column(align=True)
sub.operator("gpencil.color_isolate", icon='RESTRICT_VIEW_ON', text="").affect_visibility = True
sub.operator("gpencil.color_isolate", icon='LOCKED', text="").affect_visibility = False
sub.operator("gpencil.material_isolate", icon='RESTRICT_VIEW_ON', text="").affect_visibility = True
sub.operator("gpencil.material_isolate", icon='LOCKED', text="").affect_visibility = False
if show_full_ui:
row = layout.row()

View File

@@ -27,21 +27,21 @@ from bl_ui.properties_grease_pencil_common import (
)
class GPENCIL_MT_color_context_menu(Menu):
class GPENCIL_MT_material_context_menu(Menu):
bl_label = "Material Specials"
def draw(self, _context):
layout = self.layout
layout.operator("gpencil.color_reveal", icon='RESTRICT_VIEW_OFF', text="Show All")
layout.operator("gpencil.color_hide", icon='RESTRICT_VIEW_ON', text="Hide Others").unselected = True
layout.operator("gpencil.material_reveal", icon='RESTRICT_VIEW_OFF', text="Show All")
layout.operator("gpencil.material_hide", icon='RESTRICT_VIEW_ON', text="Hide Others").unselected = True
layout.separator()
layout.operator("gpencil.color_lock_all", icon='LOCKED', text="Lock All")
layout.operator("gpencil.color_unlock_all", icon='UNLOCKED', text="UnLock All")
layout.operator("gpencil.material_lock_all", icon='LOCKED', text="Lock All")
layout.operator("gpencil.material_unlock_all", icon='UNLOCKED', text="UnLock All")
layout.operator("gpencil.stroke_lock_color", text="Lock Unselected")
layout.operator("gpencil.material_lock_unused", text="Lock Unselected")
layout.operator("gpencil.lock_layer", text="Lock Unused")
layout.separator()
@@ -261,7 +261,7 @@ class MATERIAL_PT_gpencil_material_presets(PresetPanel, Panel):
classes = (
GPENCIL_UL_matslots,
GPENCIL_MT_color_context_menu,
GPENCIL_MT_material_context_menu,
MATERIAL_PT_gpencil_slots,
MATERIAL_PT_gpencil_preview,
MATERIAL_PT_gpencil_material_presets,