Skip to content
Permalink
Browse files

Port to 2.78 - 0.4.1 changes - 3D View - Separated tooltip for Delete…

  • Loading branch information...
ReinerBforartists committed Jan 30, 2017
1 parent 866de11 commit 2937c6f51f2532b94b02517d9c9bc1c2abd95c39
Showing with 12 additions and 0 deletions.
  1. +12 −0 release/scripts/startup/bl_ui/space_view3d.py
@@ -1273,6 +1273,17 @@ def draw(self, context):

# ********** Object menu **********

# Workaround to separate the tooltips
class VIEW3D_MT_object_delete_global(bpy.types.Operator):
"""Delete global\nDeletes the selected object(s) globally in all opened scenes""" # blender will use this as a tooltip for menu items and buttons.
bl_idname = "object.delete_global" # unique identifier for buttons and menu items to reference.
bl_label = "Delete Global" # display name in the interface.
bl_options = {'REGISTER', 'UNDO'} # enable undo for the operator.

def execute(self, context): # execute() is called by blender when running the operator.
bpy.ops.object.delete(use_global = True)
return {'FINISHED'}


class VIEW3D_MT_object(Menu):
bl_context = "objectmode"
@@ -1450,6 +1461,7 @@ def draw(self, context):
layout.operator("view3d.copybuffer", text = "Copy")
layout.operator("object.duplicate_move")
layout.operator("object.duplicate_move_linked")
layout.operator("object.delete_global", text="Delete Global") # bfa - separated tooltip
layout.operator("object.delete", text="Delete...").use_global = False
layout.menu("VIEW3D_MT_make_links", text="Make Links...")
layout.operator("object.make_dupli_face")

0 comments on commit 2937c6f

Please sign in to comment.
You can’t perform that action at this time.