diff options
-rw-r--r-- | src/scxml/qscxmlevent.cpp | 13 | ||||
-rw-r--r-- | src/scxml/qscxmlevent.h | 12 | ||||
-rw-r--r-- | src/scxml/qscxmlstatemachine.cpp | 3 |
3 files changed, 4 insertions, 24 deletions
diff --git a/src/scxml/qscxmlevent.cpp b/src/scxml/qscxmlevent.cpp index bf5de7a..f26aa97 100644 --- a/src/scxml/qscxmlevent.cpp +++ b/src/scxml/qscxmlevent.cpp @@ -48,9 +48,6 @@ QT_BEGIN_NAMESPACE using namespace QScxmlExecutableContent; -QEvent::Type QScxmlEvent::scxmlEventType = (QEvent::Type) QEvent::registerEventType(); -QEvent::Type QScxmlEvent::ignoreEventType = (QEvent::Type) QEvent::registerEventType(); - QAtomicInt QScxmlEventBuilder::idCounter = QAtomicInt(0); QScxmlEvent *QScxmlEventBuilder::buildEvent() @@ -267,7 +264,7 @@ void QScxmlEventBuilder::submitError(const QString &type, const QString &msg, co * Creates a new external SCXML event. */ QScxmlEvent::QScxmlEvent() - : QEvent(scxmlEventType), d(new QScxmlEventPrivate) + : d(new QScxmlEventPrivate) { } /*! @@ -308,7 +305,6 @@ void QScxmlEvent::clear() */ QScxmlEvent &QScxmlEvent::operator=(const QScxmlEvent &other) { - QEvent::operator=(other); *d = *other.d; return *this; } @@ -317,7 +313,7 @@ QScxmlEvent &QScxmlEvent::operator=(const QScxmlEvent &other) * Constructs a copy of \a other. */ QScxmlEvent::QScxmlEvent(const QScxmlEvent &other) - : QEvent(other), d(new QScxmlEventPrivate(*other.d)) + : d(new QScxmlEventPrivate(*other.d)) { } @@ -562,11 +558,6 @@ void QScxmlEvent::setErrorMessage(const QString &message) d->data = message; } -void QScxmlEvent::makeIgnorable() -{ - t = ignoreEventType; -} - QByteArray QScxmlEventPrivate::debugString(QScxmlEvent *event) { if (event == nullptr) { diff --git a/src/scxml/qscxmlevent.h b/src/scxml/qscxmlevent.h index 82efc57..c9f901d 100644 --- a/src/scxml/qscxmlevent.h +++ b/src/scxml/qscxmlevent.h @@ -42,7 +42,6 @@ #include <QtScxml/qscxmlglobals.h> -#include <QEvent> #include <QStringList> #include <QVariantList> @@ -54,7 +53,7 @@ class WrappedQStateMachine; class QScxmlEventPrivate; -class Q_SCXML_EXPORT QScxmlEvent: public QEvent +class Q_SCXML_EXPORT QScxmlEvent { Q_GADGET Q_PROPERTY(QString name READ name CONSTANT) @@ -110,15 +109,8 @@ public: QString errorMessage() const; void setErrorMessage(const QString &message); -protected: - friend class QScxmlInternal::WrappedQStateMachine; -#ifndef Q_QDOC - static QEvent::Type scxmlEventType; - static QEvent::Type ignoreEventType; - void makeIgnorable(); -#endif // Q_QDOC - private: + friend class QScxmlInternal::WrappedQStateMachine; QScxmlEventPrivate *d; }; diff --git a/src/scxml/qscxmlstatemachine.cpp b/src/scxml/qscxmlstatemachine.cpp index 31e620c..7aa64a2 100644 --- a/src/scxml/qscxmlstatemachine.cpp +++ b/src/scxml/qscxmlstatemachine.cpp @@ -518,9 +518,6 @@ void QScxmlStateMachinePrivate::returnDoneEvent(QScxmlExecutableContent::Contain bool QScxmlStateMachinePrivate::nameMatch(const StateTable::Array &patterns, QScxmlEvent *event) const { - if (event->type() == QEvent::None) - return false; - const QString eventName = event->name(); bool selected = false; for (int eventSelectorIter = 0; eventSelectorIter < patterns.size(); ++eventSelectorIter) { |