[Bf-extensions-cvs] [34b3d79] master: changes to W menu for tinyCAD
zeffii
noreply at git.blender.org
Wed Aug 6 21:34:25 CEST 2014
Commit: 34b3d79e94d81b0a5ef1a43912c13527d81f0f94
Author: zeffii
Date: Wed Aug 6 21:18:12 2014 +0200
Branches: master
https://developer.blender.org/rBAC34b3d79e94d81b0a5ef1a43912c13527d81f0f94
changes to W menu for tinyCAD
===================================================================
M mesh_tinyCAD/EXM.py
M mesh_tinyCAD/__init__.py
===================================================================
diff --git a/mesh_tinyCAD/EXM.py b/mesh_tinyCAD/EXM.py
index 88de749..8d3b945 100644
--- a/mesh_tinyCAD/EXM.py
+++ b/mesh_tinyCAD/EXM.py
@@ -146,7 +146,7 @@ def draw_callback_px(self, context, event):
class ExtendEdgesMulti(bpy.types.Operator):
- bl_idname = "view3d.extend_eges"
+ bl_idname = "mesh.extendmulti"
bl_label = "EXM extend multiple edges"
bl_description = "extend edge towards"
diff --git a/mesh_tinyCAD/__init__.py b/mesh_tinyCAD/__init__.py
index a545ec3..11cab98 100644
--- a/mesh_tinyCAD/__init__.py
+++ b/mesh_tinyCAD/__init__.py
@@ -21,8 +21,8 @@ END GPL LICENCE BLOCK
bl_info = {
"name": "tinyCAD Mesh tools",
"author": "zeffii (aka Dealga McArdle)",
- "version": (1, 0, 5),
- "blender": (2, 7, 0),
+ "version": (1, 0, 6),
+ "blender": (2, 7, 1),
"category": "Mesh",
"location": "View3D > EditMode > (w) Specials",
"wiki_url": "",
@@ -51,22 +51,28 @@ vtx_classes = (
)
+class VIEW3D_MT_edit_mesh_tinycad(bpy.types.Menu):
+ bl_label = "TinyCAD"
+
+ def draw(self, context):
+ for i, text in vtx_classes:
+ self.layout.operator(i.bl_idname, text=text)
+
+
def menu_func(self, context):
- for i, text in vtx_classes:
- self.layout.operator(i.bl_idname, text=text)
+ self.layout.menu("VIEW3D_MT_edit_mesh_tinycad")
+ self.layout.separator()
def register():
for i, _ in vtx_classes:
bpy.utils.register_class(i)
- bpy.types.VIEW3D_MT_edit_mesh_specials.append(menu_func)
+ bpy.utils.register_class(VIEW3D_MT_edit_mesh_tinycad)
+ bpy.types.VIEW3D_MT_edit_mesh_specials.prepend(menu_func)
def unregister():
for i, _ in vtx_classes:
bpy.utils.unregister_class(i)
+ bpy.utils.unregister_class(VIEW3D_MT_edit_mesh_tinycad)
bpy.types.VIEW3D_MT_edit_mesh_specials.remove(menu_func)
-
-
-if __name__ == "__main__":
- register()
More information about the Bf-extensions-cvs
mailing list