Select tool prop to dix prop group and UI change

This commit is contained in:
Pullusb
2021-06-24 16:40:22 +02:00
parent 0740e835d8
commit 15aec65b19
3 changed files with 28 additions and 37 deletions
+7 -8
View File
@@ -78,14 +78,13 @@ class GPTB_OT_file_checker(bpy.types.Operator):
if hasattr(area.spaces[0], 'show_locked_time'):
setattr(area.spaces[0], 'show_locked_time', True)
## set cursor type (according to prefs ?)
if fix.set_cursor_type:
if context.mode in ("EDIT_GPENCIL", "SCULPT_GPENCIL"):
tool = prefs.select_active_tool
if tool != 'none':
if bpy.context.workspace.tools.from_space_view3d_mode(bpy.context.mode, create=False).idname != tool:
bpy.ops.wm.tool_set_by_id(name=tool)# Tweaktoolcode
problems.append(f'tool changed to {tool.split(".")[1]}')
## set cursor type
if context.mode in ("EDIT_GPENCIL", "SCULPT_GPENCIL"):
tool = fix.select_active_tool
if tool != 'none':
if bpy.context.workspace.tools.from_space_view3d_mode(bpy.context.mode, create=False).idname != tool:
bpy.ops.wm.tool_set_by_id(name=tool)# Tweaktoolcode
problems.append(f'tool changed to {tool.split(".")[1]}')
# ## GP use additive drawing (else creating a frame in dopesheet makes it blank...)
# if not context.scene.tool_settings.use_gpencil_draw_additive: