mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-20 04:25:42 +08:00
Ref T536, ATC and cockpit component request overlay text messages and use COverlayMessagesFrameEnableForDockWidgetInfoArea
This commit is contained in:
committed by
Mat Sutcliffe
parent
045f79d0bd
commit
963ac03be0
@@ -58,7 +58,7 @@ namespace BlackGui
|
|||||||
namespace Components
|
namespace Components
|
||||||
{
|
{
|
||||||
CAtcStationComponent::CAtcStationComponent(QWidget *parent) :
|
CAtcStationComponent::CAtcStationComponent(QWidget *parent) :
|
||||||
COverlayMessagesFrame(parent),
|
COverlayMessagesFrameEnableForDockWidgetInfoArea(parent),
|
||||||
CIdentifiable(this),
|
CIdentifiable(this),
|
||||||
ui(new Ui::CAtcStationComponent)
|
ui(new Ui::CAtcStationComponent)
|
||||||
{
|
{
|
||||||
@@ -106,7 +106,6 @@ namespace BlackGui
|
|||||||
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::testRequestDummyAtcOnlineStations, this, &CAtcStationComponent::testCreateDummyOnlineAtcStations);
|
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::testRequestDummyAtcOnlineStations, this, &CAtcStationComponent::testCreateDummyOnlineAtcStations);
|
||||||
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::requestUpdate, this, &CAtcStationComponent::requestOnlineStationsUpdate);
|
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::requestUpdate, this, &CAtcStationComponent::requestOnlineStationsUpdate);
|
||||||
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::requestNewBackendData, this, &CAtcStationComponent::requestOnlineStationsUpdate);
|
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::requestNewBackendData, this, &CAtcStationComponent::requestOnlineStationsUpdate);
|
||||||
// will be manually set
|
|
||||||
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::modelDataChangedDigest, this, &CAtcStationComponent::onCountChanged);
|
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::modelDataChangedDigest, this, &CAtcStationComponent::onCountChanged);
|
||||||
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::requestComFrequency, this, &CAtcStationComponent::setComFrequency);
|
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::requestComFrequency, this, &CAtcStationComponent::setComFrequency);
|
||||||
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::requestTextMessageWidget, this, &CAtcStationComponent::requestTextMessageWidget);
|
connect(ui->tvp_AtcStationsOnline, &CAtcStationView::requestTextMessageWidget, this, &CAtcStationComponent::requestTextMessageWidget);
|
||||||
@@ -488,7 +487,8 @@ namespace BlackGui
|
|||||||
|
|
||||||
void CAtcStationComponent::showOverlayInlineTextMessage()
|
void CAtcStationComponent::showOverlayInlineTextMessage()
|
||||||
{
|
{
|
||||||
COverlayMessagesFrame::showOverlayInlineTextMessage(TextMessagesCom1);
|
// COverlayMessagesFrame::showOverlayInlineTextMessage(TextMessagesCom1);
|
||||||
|
this->requestTextMessageEntryTab(TextMessagesCom1);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CAtcStationComponent::onDetailsToggled(bool checked)
|
void CAtcStationComponent::onDetailsToggled(bool checked)
|
||||||
|
|||||||
@@ -14,7 +14,6 @@
|
|||||||
|
|
||||||
#include "blackgui/settings/viewupdatesettings.h"
|
#include "blackgui/settings/viewupdatesettings.h"
|
||||||
#include "blackgui/settings/atcstationssettings.h"
|
#include "blackgui/settings/atcstationssettings.h"
|
||||||
#include "blackgui/enablefordockwidgetinfoarea.h"
|
|
||||||
#include "blackgui/overlaymessagesframe.h"
|
#include "blackgui/overlaymessagesframe.h"
|
||||||
#include "blackgui/blackguiexport.h"
|
#include "blackgui/blackguiexport.h"
|
||||||
#include "blackcore/network.h"
|
#include "blackcore/network.h"
|
||||||
@@ -45,8 +44,7 @@ namespace BlackGui
|
|||||||
{
|
{
|
||||||
//! ATC stations component
|
//! ATC stations component
|
||||||
class BLACKGUI_EXPORT CAtcStationComponent :
|
class BLACKGUI_EXPORT CAtcStationComponent :
|
||||||
public COverlayMessagesFrame,
|
public COverlayMessagesFrameEnableForDockWidgetInfoArea,
|
||||||
public CEnableForDockWidgetInfoArea,
|
|
||||||
public BlackMisc::CIdentifiable
|
public BlackMisc::CIdentifiable
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
@@ -86,9 +84,6 @@ namespace BlackGui
|
|||||||
virtual bool setParentDockWidgetInfoArea(BlackGui::CDockWidgetInfoArea *parentDockableWidget) override;
|
virtual bool setParentDockWidgetInfoArea(BlackGui::CDockWidgetInfoArea *parentDockableWidget) override;
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
//! Request a text message
|
|
||||||
void requestTextMessageWidget(const BlackMisc::Aviation::CCallsign &callsign);
|
|
||||||
|
|
||||||
//! Request audio widget
|
//! Request audio widget
|
||||||
void requestAudioWidget();
|
void requestAudioWidget();
|
||||||
|
|
||||||
|
|||||||
@@ -22,8 +22,7 @@ namespace BlackGui
|
|||||||
namespace Components
|
namespace Components
|
||||||
{
|
{
|
||||||
CCockpitComponent::CCockpitComponent(QWidget *parent) :
|
CCockpitComponent::CCockpitComponent(QWidget *parent) :
|
||||||
COverlayMessagesFrame(parent),
|
COverlayMessagesFrameEnableForDockWidgetInfoArea(parent),
|
||||||
CEnableForDockWidgetInfoArea(),
|
|
||||||
ui(new Ui::CCockpitComponent)
|
ui(new Ui::CCockpitComponent)
|
||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
@@ -128,12 +127,12 @@ namespace BlackGui
|
|||||||
|
|
||||||
void CCockpitComponent::onRequestTextMessageCom1()
|
void CCockpitComponent::onRequestTextMessageCom1()
|
||||||
{
|
{
|
||||||
this->showOverlayInlineTextMessage(TextMessagesCom1);
|
this->requestTextMessageEntryTab(TextMessagesCom1);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CCockpitComponent::onRequestTextMessageCom2()
|
void CCockpitComponent::onRequestTextMessageCom2()
|
||||||
{
|
{
|
||||||
this->showOverlayInlineTextMessage(TextMessagesCom2);
|
this->requestTextMessageEntryTab(TextMessagesCom2);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CCockpitComponent::onToggleFloating(bool floating)
|
void CCockpitComponent::onToggleFloating(bool floating)
|
||||||
|
|||||||
@@ -12,7 +12,6 @@
|
|||||||
#ifndef BLACKGUI_COMPONENTS_COCKPITCOMPONENT_H
|
#ifndef BLACKGUI_COMPONENTS_COCKPITCOMPONENT_H
|
||||||
#define BLACKGUI_COMPONENTS_COCKPITCOMPONENT_H
|
#define BLACKGUI_COMPONENTS_COCKPITCOMPONENT_H
|
||||||
|
|
||||||
#include "blackgui/enablefordockwidgetinfoarea.h"
|
|
||||||
#include "blackgui/overlaymessagesframe.h"
|
#include "blackgui/overlaymessagesframe.h"
|
||||||
#include "blackgui/blackguiexport.h"
|
#include "blackgui/blackguiexport.h"
|
||||||
|
|
||||||
@@ -29,9 +28,7 @@ namespace BlackGui
|
|||||||
namespace Components
|
namespace Components
|
||||||
{
|
{
|
||||||
//! Cockpit component: COM unit, show / hide bar, voice rooms
|
//! Cockpit component: COM unit, show / hide bar, voice rooms
|
||||||
class BLACKGUI_EXPORT CCockpitComponent :
|
class BLACKGUI_EXPORT CCockpitComponent : public COverlayMessagesFrameEnableForDockWidgetInfoArea
|
||||||
public COverlayMessagesFrame,
|
|
||||||
public CEnableForDockWidgetInfoArea
|
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user