def hoverLeaveEvent(self, event): """ Remove hover effects for this piece. :param event: somekind of qt mouse event? """ self._hovering = False ctrl.remove_status(self.status_tip) QtWidgets.QGraphicsItem.hoverLeaveEvent(self, event)
def hovering(self, value): """ :param value: """ if value and not self._hovering: self._hovering = True ctrl.set_status(self.status_tip) self.setZValue(1000) elif (not value) and self._hovering: self._hovering = False ctrl.remove_status(self.status_tip) self.setZValue(self.z_value) self.update()
def hovering(self, value): """ :param value: """ if value and not self._hovering: self._hovering = True ctrl.set_status(self.status_tip) self.setZValue(1000) elif (not value) and self._hovering: self._hovering = False ctrl.remove_status(self.status_tip) self.setZValue(10) self.update()