GPv3: "Set Active Layer" operator and menu
Resolves #113915 . Ports the `layer_active` operator to set the active layer from an index. Adds the menu to set the active layer from a list. Pull Request: https://projects.blender.org/blender/blender/pulls/115606
This commit is contained in:
committed by
Falk David
parent
6023a6a423
commit
671f428ead
@@ -4575,6 +4575,9 @@ def km_grease_pencil_paint(_params):
|
||||
{"properties": [("mode", 'INVERT')]}),
|
||||
("grease_pencil.brush_stroke", {"type": 'LEFTMOUSE', "value": 'PRESS', "shift": True},
|
||||
{"properties": [("mode", 'SMOOTH')]}),
|
||||
|
||||
# Active layer
|
||||
op_menu("GREASE_PENCIL_MT_layer_active", {"type": 'Y', "value": 'PRESS'}),
|
||||
])
|
||||
|
||||
return keymap
|
||||
@@ -4623,6 +4626,9 @@ def km_grease_pencil_edit(params):
|
||||
("grease_pencil.cyclical_set", {"type": 'C', "value": 'PRESS',
|
||||
"alt": True}, {"properties": [("type", "TOGGLE")]}),
|
||||
|
||||
# Active layer
|
||||
op_menu("GREASE_PENCIL_MT_layer_active", {"type": 'Y', "value": 'PRESS'}),
|
||||
|
||||
# Context menu
|
||||
*_template_items_context_menu("VIEW3D_MT_greasepencil_edit_context_menu", params.context_menu_event),
|
||||
])
|
||||
|
||||
Reference in New Issue
Block a user