mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-06 10:15:38 +08:00
refs #338 Added class CLogSubscriber, a helper for subscribing to log messages matching a certain pattern, with the ability to change the pattern at runtime.
This commit is contained in:
@@ -21,7 +21,6 @@
|
||||
#include "blackmisc/avselcal.h"
|
||||
#include "blackmisc/project.h"
|
||||
#include "blackmisc/hotkeyfunction.h"
|
||||
#include "blackmisc/loghandler.h"
|
||||
#include "blackmisc/logmessage.h"
|
||||
#include <QSortFilterProxyModel>
|
||||
#include <QSizeGrip>
|
||||
@@ -112,7 +111,7 @@ void MainWindow::init(const CRuntimeConfig &runtimeConfig)
|
||||
this->connect(this->ui->comp_MainInfoArea->getSettingsComponent(), &CSettingsComponent::changedAtcStationsUpdateInterval, this->ui->comp_MainInfoArea->getAtcStationComponent(), &::CAtcStationComponent::setUpdateIntervalSeconds);
|
||||
|
||||
// log messages
|
||||
CLogHandler::instance()->handlerForPattern(CLogPattern().withSeverityAtOrAbove(CStatusMessage::SeverityInfo))->subscribe(this, &MainWindow::ps_displayStatusMessageInGui);
|
||||
m_logSubscriber.changeSubscription(CLogPattern().withSeverityAtOrAbove(CStatusMessage::SeverityInfo));
|
||||
|
||||
Q_ASSERT(connect);
|
||||
Q_UNUSED(connect); // suppress GCC warning in release build
|
||||
|
||||
Reference in New Issue
Block a user