Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntonio Vazquez <blendergit@gmail.com>2019-08-20 19:11:16 +0300
committerAntonio Vazquez <blendergit@gmail.com>2019-08-20 19:11:26 +0300
commita23e1c38f3a3b5c878659102cdf4877125aa9067 (patch)
tree90d0662a61c15be9ca559e49703c39eb890661f5 /release
parent14c4a217ebbe5c88b381a2c9413c52d9ea7655dd (diff)
Fix T68877: GPencil - Missing remove unused slots in menu
The operator was missing in the menu for grease pencil materials.
Diffstat (limited to 'release')
-rw-r--r--release/scripts/startup/bl_ui/properties_material_gpencil.py15
1 files changed, 6 insertions, 9 deletions
diff --git a/release/scripts/startup/bl_ui/properties_material_gpencil.py b/release/scripts/startup/bl_ui/properties_material_gpencil.py
index a9e68ecc502..8b9e01695e5 100644
--- a/release/scripts/startup/bl_ui/properties_material_gpencil.py
+++ b/release/scripts/startup/bl_ui/properties_material_gpencil.py
@@ -44,6 +44,9 @@ class GPENCIL_MT_color_context_menu(Menu):
layout.operator("gpencil.stroke_lock_color", text="Lock Unselected")
layout.operator("gpencil.lock_layer", text="Lock Unused")
+ layout.separator()
+
+ layout.operator("object.material_slot_remove_unused")
class GPENCIL_UL_matslots(UIList):
def draw_item(self, _context, layout, _data, item, icon, _active_data, _active_propname, _index):
@@ -152,11 +155,7 @@ class MATERIAL_PT_gpencil_strokecolor(GPMaterialButtonsPanel, Panel):
if gpcolor.use_stroke_texture_mix is True:
col.prop(gpcolor, "mix_stroke_factor", text="Factor")
- if (
- gpcolor.stroke_style == 'SOLID' or
- gpcolor.use_stroke_pattern or
- gpcolor.use_stroke_texture_mix
- ):
+ if (gpcolor.stroke_style == 'SOLID' or gpcolor.use_stroke_pattern or gpcolor.use_stroke_texture_mix):
col.prop(gpcolor, "color", text="Color")
if gpcolor.mode in {'DOTS', 'BOX'}:
@@ -275,8 +274,7 @@ class MATERIAL_PT_gpencil_material_presets(PresetPanel, Panel):
preset_add_operator = "scene.gpencil_material_preset_add"
-classes = (
- GPENCIL_UL_matslots,
+classes = (GPENCIL_UL_matslots,
GPENCIL_MT_color_context_menu,
MATERIAL_PT_gpencil_slots,
MATERIAL_PT_gpencil_preview,
@@ -285,8 +283,7 @@ classes = (
MATERIAL_PT_gpencil_strokecolor,
MATERIAL_PT_gpencil_fillcolor,
MATERIAL_PT_gpencil_options,
- MATERIAL_PT_gpencil_custom_props,
-)
+ MATERIAL_PT_gpencil_custom_props,)
if __name__ == "__main__": # only for live edit.
from bpy.utils import register_class