fix Coverity issues

This commit is contained in:
wmayer
2016-08-21 14:03:02 +02:00
parent 8cc3ee64e8
commit 0824c5fd3c
29 changed files with 621 additions and 543 deletions

View File

@@ -91,7 +91,7 @@ public:
{
if (bar->customize())
bar->Notify(0);
this->deleteLater();
this->deleteLater();
}
private:
@@ -108,6 +108,11 @@ SoFCColorBar::SoFCColorBar()
{
SO_NODE_CONSTRUCTOR(SoFCColorBar);
_fMaxX = 0;
_fMinX = 0;
_fMaxY = 0;
_fMinY = 0;
// SoEventCallback * cb = new SoEventCallback;
// cb->addEventCallback(SoMouseButtonEvent::getClassTypeId(), eventCallback, this);
// insertChild(cb, 0);
@@ -250,9 +255,9 @@ void SoFCColorBar::handleEvent (SoHandleEventAction *action)
if (e->getState() == SoButtonEvent::DOWN) {
// double click event
if (_timer.restart() < QApplication::doubleClickInterval()) {
QApplication::postEvent(
new SoFCColorBarProxyObject(this),
new QEvent(QEvent::User));
QApplication::postEvent(
new SoFCColorBarProxyObject(this),
new QEvent(QEvent::User));
}
}
}
@@ -274,9 +279,9 @@ void SoFCColorBar::handleEvent (SoHandleEventAction *action)
QAction* action = menu.exec(QCursor::pos());
if (action == option) {
QApplication::postEvent(
new SoFCColorBarProxyObject(this),
new QEvent(QEvent::User));
QApplication::postEvent(
new SoFCColorBarProxyObject(this),
new QEvent(QEvent::User));
}
else if (action) {
int id = action->data().toInt();