mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-01 21:56:43 +08:00
Follow up of T167, "private slots" -> "private"
This commit is contained in:
committed by
Mathew Sutcliffe
parent
8b1ef20146
commit
fb5b94e29f
@@ -139,7 +139,7 @@ void SwiftGuiStd::closeEvent(QCloseEvent *event)
|
||||
{
|
||||
// we do not just logoff, but give the user a chance to respond
|
||||
event->ignore();
|
||||
QTimer::singleShot(500, this, &SwiftGuiStd::ps_loginRequested);
|
||||
QTimer::singleShot(500, this, &SwiftGuiStd::loginRequested);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -158,7 +158,7 @@ QAction *SwiftGuiStd::getWindowMinimizeAction(QObject *parent)
|
||||
{
|
||||
const QIcon i(CIcons::changeIconBackgroundColor(this->style()->standardIcon(QStyle::SP_TitleBarMinButton), Qt::white, QSize(16, 16)));
|
||||
QAction *a = new QAction(i, "Window minimized", parent);
|
||||
connect(a, &QAction::triggered, this, &SwiftGuiStd::ps_showMinimized);
|
||||
connect(a, &QAction::triggered, this, &SwiftGuiStd::showMinimized);
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -166,7 +166,7 @@ QAction *SwiftGuiStd::getWindowNormalAction(QObject *parent)
|
||||
{
|
||||
const QIcon i(CIcons::changeIconBackgroundColor(this->style()->standardIcon(QStyle::SP_TitleBarNormalButton), Qt::white, QSize(16, 16)));
|
||||
QAction *a = new QAction(i, "Window normal", parent);
|
||||
connect(a, &QAction::triggered, this, &SwiftGuiStd::ps_showNormal);
|
||||
connect(a, &QAction::triggered, this, &SwiftGuiStd::showNormal);
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -174,7 +174,7 @@ QAction *SwiftGuiStd::getToggleWindowVisibilityAction(QObject *parent)
|
||||
{
|
||||
const QIcon i(CIcons::changeIconBackgroundColor(this->style()->standardIcon(QStyle::SP_TitleBarShadeButton), Qt::white, QSize(16, 16)));
|
||||
QAction *a = new QAction(i, "Toogle main window visibility", parent);
|
||||
connect(a, &QAction::triggered, this, &SwiftGuiStd::ps_toggleWindowVisibility);
|
||||
connect(a, &QAction::triggered, this, &SwiftGuiStd::toggleWindowVisibility);
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -182,18 +182,18 @@ QAction *SwiftGuiStd::getToggleStayOnTopAction(QObject *parent)
|
||||
{
|
||||
const QIcon i(CIcons::changeIconBackgroundColor(this->style()->standardIcon(QStyle::SP_TitleBarUnshadeButton), Qt::white, QSize(16, 16)));
|
||||
QAction *a = new QAction(i, "Toogle main window on top", parent);
|
||||
connect(a, &QAction::triggered, this, &SwiftGuiStd::ps_toogleWindowStayOnTop);
|
||||
connect(a, &QAction::triggered, this, &SwiftGuiStd::toogleWindowStayOnTop);
|
||||
return a;
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_setMainPage(SwiftGuiStd::MainPageIndex mainPage)
|
||||
void SwiftGuiStd::setMainPage(SwiftGuiStd::MainPageIndex mainPage)
|
||||
{
|
||||
ui->sw_MainMiddle->setCurrentIndex(mainPage);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_setMainPageInfoArea(CMainInfoAreaComponent::InfoArea infoArea)
|
||||
void SwiftGuiStd::setMainPageInfoArea(CMainInfoAreaComponent::InfoArea infoArea)
|
||||
{
|
||||
this->ps_setMainPageToInfoArea();
|
||||
this->setMainPageToInfoArea();
|
||||
ui->comp_MainInfoArea->selectArea(infoArea);
|
||||
}
|
||||
|
||||
@@ -202,7 +202,7 @@ bool SwiftGuiStd::isMainPageSelected(SwiftGuiStd::MainPageIndex mainPage) const
|
||||
return ui->sw_MainMiddle->currentIndex() == static_cast<int>(mainPage);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_loginRequested()
|
||||
void SwiftGuiStd::loginRequested()
|
||||
{
|
||||
if (ui->sw_MainMiddle->currentIndex() == static_cast<int>(MainPageLogin))
|
||||
{
|
||||
@@ -211,11 +211,11 @@ void SwiftGuiStd::ps_loginRequested()
|
||||
}
|
||||
else
|
||||
{
|
||||
this->ps_setMainPage(MainPageLogin);
|
||||
this->setMainPage(MainPageLogin);
|
||||
}
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_displayStatusMessageInGui(const CStatusMessage &statusMessage)
|
||||
void SwiftGuiStd::displayStatusMessageInGui(const CStatusMessage &statusMessage)
|
||||
{
|
||||
if (!m_init) { return; }
|
||||
// used with log subscriber
|
||||
@@ -236,12 +236,12 @@ void SwiftGuiStd::ps_displayStatusMessageInGui(const CStatusMessage &statusMessa
|
||||
}
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_onConnectionTerminated()
|
||||
void SwiftGuiStd::onConnectionTerminated()
|
||||
{
|
||||
this->updateGuiStatusInformation();
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_onConnectionStatusChanged(BlackCore::INetwork::ConnectionStatus from, BlackCore::INetwork::ConnectionStatus to)
|
||||
void SwiftGuiStd::onConnectionStatusChanged(BlackCore::INetwork::ConnectionStatus from, BlackCore::INetwork::ConnectionStatus to)
|
||||
{
|
||||
Q_UNUSED(from);
|
||||
this->updateGuiStatusInformation();
|
||||
@@ -263,13 +263,13 @@ void SwiftGuiStd::ps_onConnectionStatusChanged(BlackCore::INetwork::ConnectionSt
|
||||
}
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_handleTimerBasedUpdates()
|
||||
void SwiftGuiStd::handleTimerBasedUpdates()
|
||||
{
|
||||
this->setContextAvailability();
|
||||
this->updateGuiStatusInformation();
|
||||
|
||||
// own aircraft
|
||||
this->ps_reloadOwnAircraft();
|
||||
this->reloadOwnAircraft();
|
||||
}
|
||||
|
||||
void SwiftGuiStd::setContextAvailability()
|
||||
@@ -329,7 +329,7 @@ void SwiftGuiStd::updateGuiStatusInformation()
|
||||
ui->comp_InfoBarStatus->setDBusTooltip(s);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_onChangedWindowOpacity(int opacity)
|
||||
void SwiftGuiStd::onChangedWindowOpacity(int opacity)
|
||||
{
|
||||
qreal o = opacity / 100.0;
|
||||
o = o < 0.3 ? 0.3 : o;
|
||||
@@ -338,12 +338,12 @@ void SwiftGuiStd::ps_onChangedWindowOpacity(int opacity)
|
||||
ui->comp_MainInfoArea->getSettingsComponent()->setGuiOpacity(o * 100.0);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_toogleWindowStayOnTop()
|
||||
void SwiftGuiStd::toogleWindowStayOnTop()
|
||||
{
|
||||
CGuiUtility::toggleStayOnTop(this);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_toggleWindowVisibility()
|
||||
void SwiftGuiStd::toggleWindowVisibility()
|
||||
{
|
||||
if (this->isVisible())
|
||||
{
|
||||
@@ -355,39 +355,39 @@ void SwiftGuiStd::ps_toggleWindowVisibility()
|
||||
}
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_onStyleSheetsChanged()
|
||||
void SwiftGuiStd::onStyleSheetsChanged()
|
||||
{
|
||||
this->initStyleSheet();
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_onCurrentMainWidgetChanged(int currentIndex)
|
||||
void SwiftGuiStd::onCurrentMainWidgetChanged(int currentIndex)
|
||||
{
|
||||
emit currentMainInfoAreaChanged(ui->sw_MainMiddle->currentWidget());
|
||||
Q_UNUSED(currentIndex);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_onChangedMainInfoAreaFloating(bool floating)
|
||||
void SwiftGuiStd::onChangedMainInfoAreaFloating(bool floating)
|
||||
{
|
||||
// code for whole floating area goes here
|
||||
Q_UNUSED(floating);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_showMinimized()
|
||||
void SwiftGuiStd::showMinimized()
|
||||
{
|
||||
this->showMinimizedModeChecked();
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_showNormal()
|
||||
void SwiftGuiStd::showNormal()
|
||||
{
|
||||
this->showNormalModeChecked();
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_navigatorClosed()
|
||||
void SwiftGuiStd::navigatorClosed()
|
||||
{
|
||||
this->showNormal();
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_verifyDataAvailability()
|
||||
void SwiftGuiStd::verifyDataAvailability()
|
||||
{
|
||||
const CSimulatorInfo sims = sGui->getIContextSimulator()->simulatorsWithInitializedModelSet();
|
||||
if (sims.isNoSimulator())
|
||||
@@ -396,7 +396,7 @@ void SwiftGuiStd::ps_verifyDataAvailability()
|
||||
}
|
||||
}
|
||||
|
||||
void SwiftGuiStd::ps_sharedInfoObjectsLoaded()
|
||||
void SwiftGuiStd::sharedInfoObjectsLoaded()
|
||||
{
|
||||
Q_ASSERT_X(sGui && sGui->hasWebDataServices(), Q_FUNC_INFO, "Missing web services");
|
||||
Q_ASSERT_X(CThreadUtils::isCurrentThreadApplicationThread(), Q_FUNC_INFO, "Wrong thread");
|
||||
|
||||
@@ -107,7 +107,7 @@ private:
|
||||
QScopedPointer<BlackGui::Components::CNavigatorDialog> m_navigator{new BlackGui::Components::CNavigatorDialog()}; // if I pass the parent, the dialog is always centered over the parent
|
||||
BlackCore::CActionBindings m_menuHotkeyHandlers;
|
||||
BlackGui::CManagedStatusBar m_statusBar;
|
||||
BlackMisc::CLogSubscriber m_logSubscriber { this, &SwiftGuiStd::ps_displayStatusMessageInGui };
|
||||
BlackMisc::CLogSubscriber m_logSubscriber { this, &SwiftGuiStd::displayStatusMessageInGui };
|
||||
bool m_init = false;
|
||||
|
||||
// contexts
|
||||
@@ -173,85 +173,84 @@ private:
|
||||
//! Display a reconnect dialog
|
||||
void displayDBusReconnectDialog();
|
||||
|
||||
private slots:
|
||||
//
|
||||
// Data received related slots
|
||||
// Data receiving related funtions
|
||||
//
|
||||
|
||||
//! Reload own aircraft
|
||||
bool ps_reloadOwnAircraft();
|
||||
bool reloadOwnAircraft();
|
||||
|
||||
//! Display status message
|
||||
void ps_displayStatusMessageInGui(const BlackMisc::CStatusMessage &statusMessage);
|
||||
void displayStatusMessageInGui(const BlackMisc::CStatusMessage &statusMessage);
|
||||
|
||||
//! Connection status changed
|
||||
//! \param from old status
|
||||
//! \param to new status
|
||||
void ps_onConnectionStatusChanged(BlackCore::INetwork::ConnectionStatus from, BlackCore::INetwork::ConnectionStatus to);
|
||||
void onConnectionStatusChanged(BlackCore::INetwork::ConnectionStatus from, BlackCore::INetwork::ConnectionStatus to);
|
||||
|
||||
//
|
||||
// GUI related slots
|
||||
//
|
||||
|
||||
//! Set \sa MainPageInfoArea
|
||||
void ps_setMainPageToInfoArea() { this->ps_setMainPage(MainPageInfoArea); }
|
||||
void setMainPageToInfoArea() { this->setMainPage(MainPageInfoArea); }
|
||||
|
||||
//! Set one of the main pages
|
||||
void ps_setMainPage(MainPageIndex mainPage);
|
||||
void setMainPage(MainPageIndex mainPage);
|
||||
|
||||
//! Set the main info area
|
||||
void ps_setMainPageInfoArea(BlackGui::Components::CMainInfoAreaComponent::InfoArea infoArea);
|
||||
void setMainPageInfoArea(BlackGui::Components::CMainInfoAreaComponent::InfoArea infoArea);
|
||||
|
||||
//! Login requested
|
||||
void ps_loginRequested();
|
||||
void loginRequested();
|
||||
|
||||
//! Menu item clicked
|
||||
void ps_onMenuClicked();
|
||||
void onMenuClicked();
|
||||
|
||||
//! Terminated connection
|
||||
void ps_onConnectionTerminated();
|
||||
void onConnectionTerminated();
|
||||
|
||||
//! Update timer
|
||||
void ps_handleTimerBasedUpdates();
|
||||
void handleTimerBasedUpdates();
|
||||
|
||||
//! Change opacity 0-100
|
||||
void ps_onChangedWindowOpacityTo50(bool) { ps_onChangedWindowOpacity(50); }
|
||||
void onChangedWindowOpacityTo50(bool) { onChangedWindowOpacity(50); }
|
||||
|
||||
//! Change opacity 0-100
|
||||
void ps_onChangedWindowOpacityTo100(bool) { ps_onChangedWindowOpacity(100); }
|
||||
void onChangedWindowOpacityTo100(bool) { onChangedWindowOpacity(100); }
|
||||
|
||||
//! Change opacity 0-100
|
||||
void ps_onChangedWindowOpacity(int opacity = -1);
|
||||
void onChangedWindowOpacity(int opacity = -1);
|
||||
|
||||
//! Toogle if windows stays on top
|
||||
void ps_toogleWindowStayOnTop();
|
||||
void toogleWindowStayOnTop();
|
||||
|
||||
//! Toggle window visibility
|
||||
void ps_toggleWindowVisibility();
|
||||
void toggleWindowVisibility();
|
||||
|
||||
//! Style sheet has been changed
|
||||
void ps_onStyleSheetsChanged();
|
||||
void onStyleSheetsChanged();
|
||||
|
||||
//! Main info area current widget changed
|
||||
void ps_onCurrentMainWidgetChanged(int currentIndex);
|
||||
void onCurrentMainWidgetChanged(int currentIndex);
|
||||
|
||||
//! Whole main info area floating
|
||||
void ps_onChangedMainInfoAreaFloating(bool floating);
|
||||
void onChangedMainInfoAreaFloating(bool floating);
|
||||
|
||||
//! Show window minimized
|
||||
void ps_showMinimized();
|
||||
void showMinimized();
|
||||
|
||||
//! Show window normal
|
||||
void ps_showNormal();
|
||||
void showNormal();
|
||||
|
||||
//! Navigator dialog has been closed
|
||||
void ps_navigatorClosed();
|
||||
void navigatorClosed();
|
||||
|
||||
//! Checks if data such as model set etc. are available
|
||||
void ps_verifyDataAvailability();
|
||||
void verifyDataAvailability();
|
||||
|
||||
//! The shared headers have been loaded
|
||||
void ps_sharedInfoObjectsLoaded();
|
||||
//! The shared info objects have been loaded
|
||||
void sharedInfoObjectsLoaded();
|
||||
};
|
||||
|
||||
#pragma pop_macro("interface")
|
||||
|
||||
@@ -32,7 +32,7 @@ using namespace BlackMisc::PhysicalQuantities;
|
||||
using namespace BlackMisc::Geo;
|
||||
using namespace BlackMisc::Audio;
|
||||
|
||||
bool SwiftGuiStd::ps_reloadOwnAircraft()
|
||||
bool SwiftGuiStd::reloadOwnAircraft()
|
||||
{
|
||||
if (!this->m_contextNetworkAvailable) { return false; }
|
||||
|
||||
|
||||
@@ -121,12 +121,12 @@ void SwiftGuiStd::init()
|
||||
this->initGuiSignals();
|
||||
|
||||
// signal / slots contexts / timers
|
||||
connect(sGui->getWebDataServices(), &CWebDataServices::sharedInfoObjectsRead, this, &SwiftGuiStd::ps_sharedInfoObjectsLoaded);
|
||||
connect(sGui->getIContextNetwork(), &IContextNetwork::connectionTerminated, this, &SwiftGuiStd::ps_onConnectionTerminated);
|
||||
connect(sGui->getIContextNetwork(), &IContextNetwork::connectionStatusChanged, this, &SwiftGuiStd::ps_onConnectionStatusChanged);
|
||||
connect(sGui->getWebDataServices(), &CWebDataServices::sharedInfoObjectsRead, this, &SwiftGuiStd::sharedInfoObjectsLoaded);
|
||||
connect(sGui->getIContextNetwork(), &IContextNetwork::connectionTerminated, this, &SwiftGuiStd::onConnectionTerminated);
|
||||
connect(sGui->getIContextNetwork(), &IContextNetwork::connectionStatusChanged, this, &SwiftGuiStd::onConnectionStatusChanged);
|
||||
connect(sGui->getIContextNetwork(), &IContextNetwork::textMessagesReceived, ui->comp_MainInfoArea->getTextMessageComponent(), &CTextMessageComponent::onTextMessageReceived);
|
||||
connect(sGui->getIContextNetwork(), &IContextNetwork::textMessageSent, ui->comp_MainInfoArea->getTextMessageComponent(), &CTextMessageComponent::onTextMessageSent);
|
||||
connect(m_timerContextWatchdog, &QTimer::timeout, this, &SwiftGuiStd::ps_handleTimerBasedUpdates);
|
||||
connect(m_timerContextWatchdog, &QTimer::timeout, this, &SwiftGuiStd::handleTimerBasedUpdates);
|
||||
|
||||
// start timers, update timers will be started when network is connected
|
||||
m_timerContextWatchdog->start(2500);
|
||||
@@ -138,7 +138,7 @@ void SwiftGuiStd::init()
|
||||
this->initialDataReads();
|
||||
|
||||
// start screen and complete menu
|
||||
this->ps_setMainPageToInfoArea();
|
||||
this->setMainPageToInfoArea();
|
||||
this->initMenus();
|
||||
|
||||
// info
|
||||
@@ -154,7 +154,7 @@ void SwiftGuiStd::init()
|
||||
|
||||
emit sGui->startUpCompleted(true);
|
||||
m_init = true;
|
||||
QTimer::singleShot(2500, this, &SwiftGuiStd::ps_verifyDataAvailability);
|
||||
QTimer::singleShot(2500, this, &SwiftGuiStd::verifyDataAvailability);
|
||||
|
||||
if (!sGui->isNetworkAccessible())
|
||||
{
|
||||
@@ -180,12 +180,12 @@ void SwiftGuiStd::initGuiSignals()
|
||||
// This is why we still have some "old" SIGNAL/SLOT connections here
|
||||
|
||||
// main window
|
||||
connect(ui->sw_MainMiddle, &QStackedWidget::currentChanged, this, &SwiftGuiStd::ps_onCurrentMainWidgetChanged);
|
||||
connect(ui->sw_MainMiddle, &QStackedWidget::currentChanged, this, &SwiftGuiStd::onCurrentMainWidgetChanged);
|
||||
|
||||
// main keypad
|
||||
connect(ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::selectedMainInfoAreaDockWidget, this, &SwiftGuiStd::ps_setMainPageInfoArea);
|
||||
connect(ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::connectPressed, this, &SwiftGuiStd::ps_loginRequested);
|
||||
connect(ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::changedOpacity, this , &SwiftGuiStd::ps_onChangedWindowOpacity);
|
||||
connect(ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::selectedMainInfoAreaDockWidget, this, &SwiftGuiStd::setMainPageInfoArea);
|
||||
connect(ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::connectPressed, this, &SwiftGuiStd::loginRequested);
|
||||
connect(ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::changedOpacity, this , &SwiftGuiStd::onChangedWindowOpacity);
|
||||
connect(ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::identPressed, ui->comp_MainInfoArea->getCockpitComponent(), &CCockpitComponent::setSelectedTransponderModeStateIdent);
|
||||
connect(ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::commandEntered, ui->comp_MainInfoArea->getTextMessageComponent(), &CTextMessageComponent::handleGlobalCommandLine);
|
||||
connect(ui->comp_MainInfoArea, &CMainInfoAreaComponent::changedInfoAreaStatus, ui->comp_MainKeypadArea, &CMainKeypadAreaComponent::onMainInfoAreaChanged);
|
||||
@@ -196,36 +196,36 @@ void SwiftGuiStd::initGuiSignals()
|
||||
});
|
||||
|
||||
// menu
|
||||
connect(ui->menu_TestLocationsEDDF, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_TestLocationsEDDM, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_TestLocationsEDNX, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_TestLocationsEDRY, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_TestLocationsLOWW, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_TestLocationsEDDF, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
connect(ui->menu_TestLocationsEDDM, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
connect(ui->menu_TestLocationsEDNX, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
connect(ui->menu_TestLocationsEDRY, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
connect(ui->menu_TestLocationsLOWW, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
|
||||
connect(ui->menu_WindowFont, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_WindowMinimize, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_WindowToggleOnTop, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_WindowFont, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
connect(ui->menu_WindowMinimize, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
connect(ui->menu_WindowToggleOnTop, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
connect(ui->menu_WindowToggleNavigator, &QAction::triggered, m_navigator.data(), &CNavigatorDialog::toggleNavigator);
|
||||
connect(m_navigator.data(), &CNavigatorDialog::navigatorClosed, this, &SwiftGuiStd::ps_navigatorClosed);
|
||||
connect(ui->menu_InternalsPage, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(ui->menu_MovingMap, &QAction::triggered, this, &SwiftGuiStd::ps_onMenuClicked);
|
||||
connect(m_navigator.data(), &CNavigatorDialog::navigatorClosed, this, &SwiftGuiStd::navigatorClosed);
|
||||
connect(ui->menu_InternalsPage, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
connect(ui->menu_MovingMap, &QAction::triggered, this, &SwiftGuiStd::onMenuClicked);
|
||||
|
||||
// command line / text messages
|
||||
connect(ui->comp_MainInfoArea->getTextMessageComponent(), &CTextMessageComponent::displayInInfoWindow, ui->fr_CentralFrameInside, &COverlayMessagesFrame::showOverlayVariant);
|
||||
|
||||
// settings (GUI component), styles
|
||||
connect(ui->comp_MainInfoArea->getSettingsComponent(), &CSettingsComponent::changedWindowsOpacity, this, &SwiftGuiStd::ps_onChangedWindowOpacity);
|
||||
connect(sGui, &CGuiApplication::styleSheetsChanged, this, &SwiftGuiStd::ps_onStyleSheetsChanged);
|
||||
connect(ui->comp_MainInfoArea->getSettingsComponent(), &CSettingsComponent::changedWindowsOpacity, this, &SwiftGuiStd::onChangedWindowOpacity);
|
||||
connect(sGui, &CGuiApplication::styleSheetsChanged, this, &SwiftGuiStd::onStyleSheetsChanged);
|
||||
|
||||
// login
|
||||
connect(ui->comp_Login, &CLoginComponent::loginOrLogoffCancelled, this, &SwiftGuiStd::ps_setMainPageToInfoArea);
|
||||
connect(ui->comp_Login, &CLoginComponent::loginOrLogoffSuccessful, this, &SwiftGuiStd::ps_setMainPageToInfoArea);
|
||||
connect(ui->comp_Login, &CLoginComponent::loginOrLogoffCancelled, this, &SwiftGuiStd::setMainPageToInfoArea);
|
||||
connect(ui->comp_Login, &CLoginComponent::loginOrLogoffSuccessful, this, &SwiftGuiStd::setMainPageToInfoArea);
|
||||
connect(ui->comp_Login, &CLoginComponent::loginOrLogoffSuccessful, ui->comp_MainInfoArea->getFlightPlanComponent(), &CFlightPlanComponent::loginDataSet);
|
||||
connect(ui->comp_Login, &CLoginComponent::loginDataChangedDigest, ui->comp_MainInfoArea->getFlightPlanComponent(), &CFlightPlanComponent::loginDataSet);
|
||||
connect(this, &SwiftGuiStd::currentMainInfoAreaChanged, ui->comp_Login, &CLoginComponent::mainInfoAreaChanged);
|
||||
connect(ui->comp_Login, &CLoginComponent::requestNetworkSettings, [ this ]()
|
||||
{
|
||||
this->ps_setMainPageInfoArea(CMainInfoAreaComponent::InfoAreaSettings);
|
||||
this->setMainPageInfoArea(CMainInfoAreaComponent::InfoAreaSettings);
|
||||
ui->comp_MainInfoArea->getSettingsComponent()->setSettingsTab(CSettingsComponent::SettingTabServers);
|
||||
});
|
||||
|
||||
@@ -235,7 +235,7 @@ void SwiftGuiStd::initGuiSignals()
|
||||
connect(ui->comp_MainInfoArea->getAircraftComponent(), &CAircraftComponent::requestTextMessageWidget, ui->comp_MainInfoArea->getTextMessageComponent(), &CTextMessageComponent::showCorrespondingTab);
|
||||
|
||||
// main info area
|
||||
connect(ui->comp_MainInfoArea, &CMainInfoAreaComponent::changedWholeInfoAreaFloating, this, &SwiftGuiStd::ps_onChangedMainInfoAreaFloating);
|
||||
connect(ui->comp_MainInfoArea, &CMainInfoAreaComponent::changedWholeInfoAreaFloating, this, &SwiftGuiStd::onChangedMainInfoAreaFloating);
|
||||
}
|
||||
|
||||
void SwiftGuiStd::initialDataReads()
|
||||
@@ -247,7 +247,7 @@ void SwiftGuiStd::initialDataReads()
|
||||
return;
|
||||
}
|
||||
|
||||
this->ps_reloadOwnAircraft(); // init read, independent of traffic network
|
||||
this->reloadOwnAircraft(); // init read, independent of traffic network
|
||||
CLogMessage(this).info("Initial data read");
|
||||
}
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ using namespace BlackMisc::PhysicalQuantities;
|
||||
using namespace BlackMisc::Aviation;
|
||||
using namespace BlackMisc::Network;
|
||||
|
||||
void SwiftGuiStd::ps_onMenuClicked()
|
||||
void SwiftGuiStd::onMenuClicked()
|
||||
{
|
||||
QObject *sender = QObject::sender();
|
||||
if (sender == ui->menu_TestLocationsEDRY)
|
||||
@@ -57,7 +57,7 @@ void SwiftGuiStd::ps_onMenuClicked()
|
||||
}
|
||||
else if (sender == ui->menu_WindowFont)
|
||||
{
|
||||
this->ps_setMainPageToInfoArea();
|
||||
this->setMainPageToInfoArea();
|
||||
ui->comp_MainInfoArea->selectSettingsTab(BlackGui::Components::CSettingsComponent::SettingTabGui);
|
||||
}
|
||||
else if (sender == ui->menu_InternalsPage)
|
||||
|
||||
Reference in New Issue
Block a user