[Bf-blender-cvs] [9b7f30d] master: Bring back edit curve add menu

Sergey Sharybin noreply at git.blender.org
Thu Jan 2 20:35:31 CET 2014


Commit: 9b7f30d6b0694e6a5bef34333a27f53fb86e47ea
Author: Sergey Sharybin
Date:   Fri Jan 3 01:34:35 2014 +0600
https://developer.blender.org/rB9b7f30d6b0694e6a5bef34333a27f53fb86e47ea

Bring back edit curve add menu

It was wrongly considered unused in rB5fdfa6d47542db32426ac080f071a1fd751e05a7

===================================================================

M	release/scripts/startup/bl_ui/space_view3d.py

===================================================================

diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py
index 4722146..e0f5342 100644
--- a/release/scripts/startup/bl_ui/space_view3d.py
+++ b/release/scripts/startup/bl_ui/space_view3d.py
@@ -919,6 +919,22 @@ class INFO_MT_metaball_add(Menu):
         layout.operator_enum("object.metaball_add", "type")
 
 
+class INFO_MT_edit_curve_add(Menu):
+    bl_idname = "INFO_MT_edit_curve_add"
+    bl_label = "Add"
+
+    def draw(self, context):
+        is_surf = context.active_object.type == 'SURFACE'
+
+        layout = self.layout
+        layout.operator_context = 'EXEC_REGION_WIN'
+
+        if is_surf:
+            INFO_MT_surface_add.draw(self, context)
+        else:
+            INFO_MT_curve_add.draw(self, context)
+
+
 class INFO_MT_edit_armature_add(Menu):
     bl_idname = "INFO_MT_edit_armature_add"
     bl_label = "Armature"




More information about the Bf-blender-cvs mailing list