Fix #119396: Add toggle for texture paint mask icon #119399
|
@ -995,7 +995,7 @@ class VIEW3D_HT_header(Header):
|
|||
row = layout.row()
|
||||
row.ui_units_x = 9
|
||||
row.popover(panel="VIEW3D_PT_slots_projectpaint", icon=icon)
|
||||
row.popover(panel="VIEW3D_PT_mask", icon='MOD_MASK', text="")
|
||||
row.popover(panel="VIEW3D_PT_mask", icon=VIEW3D_HT_header._texture_mask_icon(tool_settings.image_paint), text="")
|
||||
else:
|
||||
# Transform settings depending on tool header visibility
|
||||
VIEW3D_HT_header.draw_xform_template(layout, context)
|
||||
|
@ -1103,6 +1103,11 @@ class VIEW3D_HT_header(Header):
|
|||
|
||||
return "CLIPUV_DEHLT" if automask_enabled else "CLIPUV_HLT"
|
||||
|
||||
@staticmethod
|
||||
def _texture_mask_icon(ipaint):
|
||||
mask_enabled = ipaint.use_stencil_layer or ipaint.use_cavity
|
||||
return "CLIPUV_DEHLT" if mask_enabled else "CLIPUV_HLT"
|
||||
|
||||
|
||||
class VIEW3D_MT_editor_menus(Menu):
|
||||
bl_label = ""
|
||||
|
|
Loading…
Reference in New Issue