Added "self.moving = False" in InfLineLabel class

Added  "self.moving = False" in  InfLineLabel class to solve the error message when clicking on the label.

    |  AttributeError: 'InfLineLabel' object has no attribute 'moving'
This commit is contained in:
Legnain 2016-05-03 04:54:21 -04:00
parent c599635319
commit b4b1aec162

View File

@ -325,6 +325,7 @@ class InfLineLabel(TextItem):
def __init__(self, line, text="", movable=False, position=0.5, anchors=None, **kwds):
self.line = line
self.movable = movable
self.moving = False
self.orthoPos = position # text will always be placed on the line at a position relative to view bounds
self.format = text
self.line.sigPositionChanged.connect(self.valueChanged)