[Bf-extensions-cvs] [63eb280] master: Cleanup and panel displays if the selected object is a mesh or have not.
Germano Cavalcante mano-wii
noreply at git.blender.org
Fri Sep 4 15:23:15 CEST 2015
Commit: 63eb280060dc6758858a7673558136e9036ea64a
Author: Germano Cavalcante (mano-wii)
Date: Fri Sep 4 10:17:53 2015 -0300
Branches: master
https://developer.blender.org/rBAC63eb280060dc6758858a7673558136e9036ea64a
Cleanup and panel displays if the selected object is a mesh or have not.
===================================================================
M mesh_snap_utilities_line.py
===================================================================
diff --git a/mesh_snap_utilities_line.py b/mesh_snap_utilities_line.py
index bc1bc69..e37c6f0 100644
--- a/mesh_snap_utilities_line.py
+++ b/mesh_snap_utilities_line.py
@@ -30,8 +30,7 @@ bl_info = {
"category": "Mesh"}
import bpy, bgl, bmesh, mathutils, math
-#from space_view3d_panel_measure import getUnitsInfo, convertDistance
-from mathutils import Vector#, Matrix
+from mathutils import Vector
from mathutils.geometry import (
intersect_point_line,
intersect_line_line,
@@ -844,12 +843,12 @@ class PanelSnapUtilities(bpy.types.Panel) :
#bl_context = "mesh_edit"
bl_category = "Snap Utilities"
bl_label = "Snap Utilities"
- '''
+
@classmethod
def poll(cls, context):
- return (context.object is not None and
+ return (not context.object or
context.object.type == 'MESH')
- '''
+
def draw(self, context):
layout = self.layout
TheCol = layout.column(align = True)
More information about the Bf-extensions-cvs
mailing list