mirror of
https://github.com/YACReader/yacreader
synced 2025-07-18 21:14:33 -04:00
Update QsLog to 2.1 snapshot 46b643d5bcbc
This commit is contained in:
15
third_party/QsLog/QsLogDestFunctor.h
vendored
15
third_party/QsLog/QsLogDestFunctor.h
vendored
@ -37,19 +37,22 @@ namespace QsLogging
|
||||
// called from a different thread or even a different binary. You should not access QsLog from
|
||||
// inside LogFunction and should not perform any time-consuming operations.
|
||||
// logMessageReady is connected through a queued connection and trace messages are not included
|
||||
class FunctorDestination : public QObject, public Destination
|
||||
class QSLOG_SHARED_OBJECT FunctorDestination : public QObject, public Destination
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit FunctorDestination(LogFunction f);
|
||||
FunctorDestination(QObject *receiver, const char *member);
|
||||
static const char* const Type;
|
||||
|
||||
virtual void write(const QString &message, Level level);
|
||||
virtual bool isValid();
|
||||
explicit FunctorDestination(LogFunction f);
|
||||
FunctorDestination(QObject* receiver, const char* member);
|
||||
|
||||
void write(const LogMessage& message) override;
|
||||
bool isValid() override;
|
||||
QString type() const override;
|
||||
|
||||
protected:
|
||||
// int used to avoid registering a new enum type
|
||||
Q_SIGNAL void logMessageReady(const QString &message, int level);
|
||||
Q_SIGNAL void logMessageReady(const QsLogging::LogMessage& message);
|
||||
|
||||
private:
|
||||
LogFunction mLogFunction;
|
||||
|
Reference in New Issue
Block a user