Commit: 150f42e6d3a1f48c7c9eecabc7b63936c221b352 Author: RedMser Date: Fri Feb 4 16:37:41 2022 +0100 Branches: master https://developer.blender.org/rB150f42e6d3a1f48c7c9eecabc7b63936c221b352
NLA: shortcut to rename active strip Use the global F2 rename panel for the NLA editor to rename NLA strips. Reviewed By: sybren, RiggingDojo Differential Revision: https://developer.blender.org/D12300 =================================================================== M release/scripts/startup/bl_ui/space_nla.py M release/scripts/startup/bl_ui/space_topbar.py =================================================================== diff --git a/release/scripts/startup/bl_ui/space_nla.py b/release/scripts/startup/bl_ui/space_nla.py index 2db2b11a5f9..78c312fd03d 100644 --- a/release/scripts/startup/bl_ui/space_nla.py +++ b/release/scripts/startup/bl_ui/space_nla.py @@ -291,6 +291,9 @@ class NLA_MT_context_menu(Menu): layout.separator() + props = layout.operator("wm.call_panel", text="Rename...") + props.name = "TOPBAR_PT_name" + props.keep_open = False layout.operator("nla.duplicate", text="Duplicate").linked = False layout.operator("nla.duplicate", text="Linked Duplicate").linked = True diff --git a/release/scripts/startup/bl_ui/space_topbar.py b/release/scripts/startup/bl_ui/space_topbar.py index 513c1c2ae2e..ce854155b88 100644 --- a/release/scripts/startup/bl_ui/space_topbar.py +++ b/release/scripts/startup/bl_ui/space_topbar.py @@ -832,6 +832,14 @@ class TOPBAR_PT_name(Panel): row = row_with_icon(layout, 'NODE') row.prop(item, "label", text="") found = True + elif space_type == 'NLA_EDITOR': + layout.label(text="NLA Strip Name") + item = next( + (strip for strip in context.selected_nla_strips if strip.active), None) + if item: + row = row_with_icon(layout, 'NLA') + row.prop(item, "name", text="") + found = True else: if mode == 'POSE' or (mode == 'WEIGHT_PAINT' and context.pose_object): layout.label(text="Bone Name") _______________________________________________ Bf-blender-cvs mailing list [email protected] List details, subscription details or unsubscribe: https://lists.blender.org/mailman/listinfo/bf-blender-cvs
