Handle setting/clearing data a little more robustly.
This commit is contained in:
parent
501ad4f082
commit
654b76e6a3
@ -45,9 +45,11 @@ class ErrorBarItem(GraphicsObject):
|
||||
|
||||
This method was added in version 0.9.9. For prior versions, use setOpts.
|
||||
"""
|
||||
if 'x' in opts and 'y' in opts:
|
||||
self.setVisible(True)
|
||||
self.opts.update(opts)
|
||||
if self.opts['x'] is not None and self.opts['y'] is not None:
|
||||
self.setVisible(True)
|
||||
else:
|
||||
self.setVisible(False)
|
||||
self.path = None
|
||||
self.update()
|
||||
self.prepareGeometryChange()
|
||||
|
Loading…
Reference in New Issue
Block a user