MythTV master
mythevent.cpp
Go to the documentation of this file.
1#include "mythevent.h"
2#include "mythlogging.h"
3
4const QEvent::Type MythEvent::kMythEventMessage =
5 (QEvent::Type) QEvent::registerEventType();
6const QEvent::Type MythEvent::kMythUserMessage =
7 (QEvent::Type) QEvent::registerEventType();
9 (QEvent::Type) QEvent::registerEventType();
10const QEvent::Type MythEvent::kExitToMainMenuEventType =
11 (QEvent::Type) QEvent::registerEventType();
12const QEvent::Type MythEvent::kMythPostShowEventType =
13 (QEvent::Type) QEvent::registerEventType();
15 (QEvent::Type) QEvent::registerEventType();
17 (QEvent::Type) QEvent::registerEventType();
19 (QEvent::Type) QEvent::registerEventType();
21 (QEvent::Type) QEvent::registerEventType();
23 (QEvent::Type) QEvent::registerEventType();
25 (QEvent::Type) QEvent::registerEventType();
27 (QEvent::Type) QEvent::registerEventType();
28const QEvent::Type ExternalKeycodeEvent::kEventType =
29 (QEvent::Type) QEvent::registerEventType();
30
31// Force this class to have a vtable so that dynamic_cast works.
32// NOLINTNEXTLINE(modernize-use-equals-default)
34{
35}
36
37void MythEvent::log(const QString& prefix)
38{
39 LOG(VB_GENERAL, LOG_INFO, QString("%1: %2").arg(prefix, m_message));
40 if (m_extradata.isEmpty())
41 return;
42 if ((m_extradata.count() == 1) && (m_extradata[0] == "empty"))
43 return;
44 QStringList tmp = m_extradata;
45 if ((m_message.startsWith("GENERATED_PIXMAP")) && (tmp[0] == "OK"))
46 tmp[6]="Encoded pixmap";
47 LOG(VB_GENERAL, LOG_INFO, QString("Extra data: %1").arg(tmp.join('|')));
48}
static const Type kEventType
Definition: mythevent.h:113
static const Type kExitToMainMenuEventType
Definition: mythevent.h:82
static const Type kPushDisableDrawingEventType
Definition: mythevent.h:84
static const Type kDisableUDPListenerEventType
Definition: mythevent.h:89
QString m_message
Definition: mythevent.h:101
static const Type kUnlockInputDevicesEventType
Definition: mythevent.h:87
~MythEvent() override
Definition: mythevent.cpp:33
static const Type kPopDisableDrawingEventType
Definition: mythevent.h:85
static const Type kUpdateTvProgressEventType
Definition: mythevent.h:81
static const Type kEnableUDPListenerEventType
Definition: mythevent.h:90
static const Type kUpdateBrowseInfoEventType
Definition: mythevent.h:88
QStringList m_extradata
Definition: mythevent.h:102
static const Type kMythPostShowEventType
Definition: mythevent.h:83
static const Type kMythEventMessage
Definition: mythevent.h:79
static const Type kMythUserMessage
Definition: mythevent.h:80
static const Type kLockInputDevicesEventType
Definition: mythevent.h:86
void log(const QString &prefix)
Definition: mythevent.cpp:37
static guint32 * tmp
Definition: goom_core.cpp:26
#define LOG(_MASK_, _LEVEL_, _QSTRING_)
Definition: mythlogging.h:39