X-Git-Url: https://vaikene.ee/gitweb/pswgen09.html?a=blobdiff_plain;f=src%2Flibs%2FCommon%2Fevent.h;h=0658a6a4652fb201a8a76437c8bce5ff74ad95a3;hb=4c0329c5c2690bde28212c89029015a5da4c7e34;hp=960b53e05db0c69d1c8656bf0f022b2d6e02b68f;hpb=5815060246f84e8efdf3143b4e8c7d00778168cf;p=evaf
diff --git a/src/libs/Common/event.h b/src/libs/Common/event.h
index 960b53e..0658a6a 100644
--- a/src/libs/Common/event.h
+++ b/src/libs/Common/event.h
@@ -3,7 +3,7 @@
* @brief Base class for all the events
* @author Enar Vaikene
*
- * Copyright (c) 2011 Enar Vaikene
+ * Copyright (c) 2011-2019 Enar Vaikene
*
* This file is part of the eVaf C++ cross-platform application development framework.
*
@@ -58,13 +58,15 @@ public:
* is decreased by 1 when the event object is destroyed. If nobody else claimed the ownership, then
* the shared data object is destroyed too.
*/
- Event(uint eventId, quint32 intValue = 0, QSharedData * dataObj = 0)
+ Event(uint eventId, quint32 intValue = 0, QSharedData * dataObj = nullptr)
: QEvent(eVafEvent)
, mId(eventId)
, mValue(intValue)
, mData(dataObj)
{}
+ virtual ~Event();
+
/**
* Returns the event ID value
*/
@@ -82,7 +84,7 @@ public:
* is finished, the event and shared data attached to it are destroyed. To keep the shared
* data object, use QExplicitlySharedDataPointer<> to claim ownership.
*/
- inline QSharedData * data() const { return mData ? mData.data() : 0; }
+ inline QSharedData * data() const { return mData != nullptr ? mData.data() : nullptr; }
private: