Compare commits
No commits in common. "d3e4072564f9c18f1725016170ff6aae409893c8" and "49c70860a6b5c8a6dd2f42bbba35ddedd5874abc" have entirely different histories.
d3e4072564
...
49c70860a6
|
@ -41,7 +41,7 @@ class GPTB_OT_duplicate_send_to_layer(Operator) :
|
|||
@classmethod
|
||||
def poll(cls, context):
|
||||
return context.object and context.object.type == 'GREASEPENCIL'\
|
||||
and context.space_data.bl_rna.identifier == 'SpaceDopeSheetEditor' and context.space_data.ui_mode == 'GPENCIL'
|
||||
and context.space_data.bl_rna.identifier == 'SpaceDopeSheetEditor' and context.space_data.ui_mode == 'GREASEPENCIL'
|
||||
|
||||
# history : bpy.props.StringProperty(default='', options={'SKIP_SAVE'}) # need to have a variable to store (to get it in self)
|
||||
|
||||
|
@ -67,7 +67,6 @@ class GPTB_OT_duplicate_send_to_layer(Operator) :
|
|||
for f in reversed(to_replace):
|
||||
target_layer.frames.remove(f)
|
||||
|
||||
# FIXME : need to createa a dedicated function to copy a frame
|
||||
## Copy original frames
|
||||
for f in selected_frames:
|
||||
target_layer.frames.copy(f)
|
||||
|
@ -132,7 +131,7 @@ def unregister_keymaps():
|
|||
|
||||
|
||||
def menu_duplicate_and_send_to_layer(self, context):
|
||||
if context.space_data.ui_mode == 'GPENCIL':
|
||||
if context.space_data.ui_mode == 'GREASEPENCIL':
|
||||
self.layout.operator_context = 'INVOKE_REGION_WIN'
|
||||
self.layout.operator('gp.duplicate_send_to_layer', text='Move Keys To Layer').delete_source = True
|
||||
self.layout.operator('gp.duplicate_send_to_layer', text='Copy Keys To Layer')
|
||||
|
|
|
@ -165,7 +165,7 @@ class GPTB_OT_move_material_to_layer(Operator) :
|
|||
|
||||
|
||||
# def menu_duplicate_and_send_to_layer(self, context):
|
||||
# if context.space_data.ui_mode == 'GPENCIL':
|
||||
# if context.space_data.ui_mode == 'GREASEPENCIL':
|
||||
# self.layout.operator_context = 'INVOKE_REGION_WIN'
|
||||
# self.layout.operator('gp.duplicate_send_to_layer', text='Move Keys To Layer').delete_source = True
|
||||
# self.layout.operator('gp.duplicate_send_to_layer', text='Copy Keys To Layer')
|
||||
|
|
|
@ -290,8 +290,9 @@ class GP_OT_pick_closest_material(Operator):
|
|||
addon_keymaps = []
|
||||
def register_keymaps():
|
||||
addon = bpy.context.window_manager.keyconfigs.addon
|
||||
# km = addon.keymaps.new(name = "Grease Pencil Stroke Paint (Draw brush)", space_type = "EMPTY", region_type='WINDOW')
|
||||
# km = addon.keymaps.new(name = "Grease Pencil Paint Mode", space_type = "EMPTY", region_type='WINDOW')
|
||||
km = addon.keymaps.new(name = "Grease Pencil Fill Tool", space_type = "EMPTY", region_type='WINDOW')
|
||||
km = addon.keymaps.new(name = "Grease Pencil Stroke Paint (Fill)", space_type = "EMPTY", region_type='WINDOW')
|
||||
kmi = km.keymap_items.new(
|
||||
# name="",
|
||||
idname="gp.pick_closest_material",
|
||||
|
|
Loading…
Reference in New Issue