Fix when there is no object loaded, remove debug print.
This commit is contained in:
parent
183304d975
commit
edba844794
2 changed files with 27 additions and 26 deletions
|
@ -242,7 +242,6 @@ class DimensionSkein:
|
||||||
distance -= 10.0
|
distance -= 10.0
|
||||||
e = self.getExtrusionDistanceString(10.0, splitLine)
|
e = self.getExtrusionDistanceString(10.0, splitLine)
|
||||||
extra += self.distanceFeedRate.getLinearGcodeMovementWithFeedRate(self.feedRateMinute, self.oldLocation.dropAxis(), self.oldLocation.z) + e + '\n'
|
extra += self.distanceFeedRate.getLinearGcodeMovementWithFeedRate(self.feedRateMinute, self.oldLocation.dropAxis(), self.oldLocation.z) + e + '\n'
|
||||||
print extra, line, distance
|
|
||||||
line = extra + line
|
line = extra + line
|
||||||
self.oldLocation = location
|
self.oldLocation = location
|
||||||
else:
|
else:
|
||||||
|
|
|
@ -429,6 +429,7 @@ class PreviewGLCanvas(glcanvas.GLCanvas):
|
||||||
self.objColor[3] = profile.getPreferenceColour('model_colour3')
|
self.objColor[3] = profile.getPreferenceColour('model_colour3')
|
||||||
|
|
||||||
def OnMouseMotion(self,e):
|
def OnMouseMotion(self,e):
|
||||||
|
if self.parent.objectsMaxV != None:
|
||||||
size = (self.parent.objectsMaxV - self.parent.objectsMinV)
|
size = (self.parent.objectsMaxV - self.parent.objectsMinV)
|
||||||
sizeXY = math.sqrt((size[0] * size[0]) + (size[1] * size[1]))
|
sizeXY = math.sqrt((size[0] * size[0]) + (size[1] * size[1]))
|
||||||
|
|
||||||
|
@ -701,6 +702,7 @@ class PreviewGLCanvas(glcanvas.GLCanvas):
|
||||||
glTranslate(self.parent.machineCenter.x, self.parent.machineCenter.y, 0)
|
glTranslate(self.parent.machineCenter.x, self.parent.machineCenter.y, 0)
|
||||||
|
|
||||||
#Draw the rotate circle
|
#Draw the rotate circle
|
||||||
|
if self.parent.objectsMaxV != None:
|
||||||
glDisable(GL_LIGHTING)
|
glDisable(GL_LIGHTING)
|
||||||
glDisable(GL_CULL_FACE)
|
glDisable(GL_CULL_FACE)
|
||||||
glEnable(GL_BLEND)
|
glEnable(GL_BLEND)
|
||||||
|
|
Loading…
Reference in a new issue