mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-05-06 02:16:04 +08:00
refactor: Remove build-in console
The console feature was not documented very well and was only used for a few messages.
This commit is contained in:
@@ -409,15 +409,6 @@ void SwiftGuiStd::onChangedMainInfoAreaFloating(bool floating)
|
||||
Q_UNUSED(floating)
|
||||
}
|
||||
|
||||
void SwiftGuiStd::onRequestedConsoleMessage(const QString &logMsg, bool clear)
|
||||
{
|
||||
if (logMsg.isEmpty()) { return; }
|
||||
CLogComponent *log = ui->comp_MainInfoArea->getLogComponent();
|
||||
Q_ASSERT_X(log, Q_FUNC_INFO, "Missing log component");
|
||||
if (clear) { log->clearConsole(); }
|
||||
log->appendPlainTextToConsole(logMsg);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::onAudioClientFailure(const CStatusMessage &msg)
|
||||
{
|
||||
if (msg.isEmpty()) { return; }
|
||||
@@ -545,11 +536,6 @@ void SwiftGuiStd::playNotifcationSound(CNotificationSounds::NotificationFlag not
|
||||
sGui->getCContextAudioBase()->playNotification(notification, true);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::displayConsole()
|
||||
{
|
||||
ui->comp_MainInfoArea->displayConsole();
|
||||
}
|
||||
|
||||
void SwiftGuiStd::displayLog()
|
||||
{
|
||||
ui->comp_MainInfoArea->displayLog();
|
||||
|
||||
@@ -191,9 +191,6 @@ private:
|
||||
//! Play notifcation sound
|
||||
void playNotifcationSound(BlackMisc::Audio::CNotificationSounds::NotificationFlag notification) const;
|
||||
|
||||
//! Display console
|
||||
void displayConsole();
|
||||
|
||||
//! Display log
|
||||
void displayLog();
|
||||
|
||||
@@ -281,9 +278,6 @@ private:
|
||||
//! Whole main info area floating
|
||||
void onChangedMainInfoAreaFloating(bool floating);
|
||||
|
||||
//! UI Console message has been recevied
|
||||
void onRequestedConsoleMessage(const QString &logMsg, bool clear);
|
||||
|
||||
//! Reported issue with the client
|
||||
void onAudioClientFailure(const BlackMisc::CStatusMessage &msg);
|
||||
|
||||
|
||||
@@ -145,8 +145,6 @@ void SwiftGuiStd::init()
|
||||
Q_ASSERT(s);
|
||||
s = connect(sGui->getIContextNetwork(), &IContextNetwork::kicked, this, &SwiftGuiStd::onKickedFromNetwork, Qt::QueuedConnection);
|
||||
Q_ASSERT(s);
|
||||
s = connect(sGui->getIContextSimulator(), &IContextSimulator::requestUiConsoleMessage, this, &SwiftGuiStd::onRequestedConsoleMessage, Qt::QueuedConnection);
|
||||
Q_ASSERT(s);
|
||||
s = connect(sGui->getIContextSimulator(), &IContextSimulator::validatedModelSet, this, &SwiftGuiStd::onValidatedModelSet, Qt::QueuedConnection);
|
||||
Q_ASSERT(s);
|
||||
s = connect(&m_timerContextWatchdog, &QTimer::timeout, this, &SwiftGuiStd::handleTimerBasedUpdates);
|
||||
@@ -177,8 +175,6 @@ void SwiftGuiStd::init()
|
||||
this->initMenus();
|
||||
|
||||
// info
|
||||
ui->comp_MainInfoArea->getLogComponent()->appendPlainTextToConsole(sGui->swiftVersionString());
|
||||
ui->comp_MainInfoArea->getLogComponent()->appendPlainTextToConsole(CBuildConfig::compiledWithInfo());
|
||||
connect(ui->comp_InfoBarStatus, &CInfoBarStatusComponent::transponderModeChanged, ui->dw_InfoBarStatus, &CDockWidgetInfoBar::reloadStyleSheet, Qt::QueuedConnection);
|
||||
|
||||
// Show kill button
|
||||
|
||||
Reference in New Issue
Block a user