6 #ifndef SWIFT_GUI_COMPONENTS_TEXTMESSAGECOMPONENT_H
7 #define SWIFT_GUI_COMPONENTS_TEXTMESSAGECOMPONENT_H
11 #include <QScopedPointer>
27 class CTextMessageComponent;
31 class CDockWidgetInfoArea;
32 class CTextMessageTextEdit;
49 virtual bool setParentDockWidgetInfoArea(
CDockWidgetInfoArea *parentDockableWidget)
override;
71 bool hasAllMessagesTab()
const;
74 void showSettings(
bool show);
77 void showTextMessageEntry(
bool show);
80 void focusTextEntry();
83 void removeAllMessagesTab();
97 void activate(
bool send,
bool receive);
100 bool isActivated()
const {
return m_activeSend || m_activeReceive; }
103 void setAtcButtonsRowsColumns(
int rows,
int cols,
bool setMaxElements);
106 void setAtcButtonsBackgroundUpdates(
bool backgroundUpdates);
109 void updateAtcStationsButtons();
123 QScopedPointer<Ui::CTextMessageComponent> ui;
126 this, &CTextMessageComponent::onSettingsChanged
129 bool m_usedAsOverlayWidget =
false;
130 bool m_activeSend =
true;
131 bool m_activeReceive =
true;
132 bool m_showRealNames =
true;
147 bool isCloseableTab(
const QWidget *tabWidget)
const;
154 bool callsignResolution =
false)
const;
157 QWidget *findTextMessageTabByName(
const QString &name)
const;
169 bool isNetworkConnected()
const;
173 void showCurrentFrequenciesFromCockpit();
181 QString textMessageToCommand(
const QString &enteredLine);
187 void handleEnteredTextMessage(
const QString &textMessage);
200 void onSettingsChecked(
bool checked);
203 void onMessageToChecked(
bool checked);
206 void onSettingsChanged();
209 void onLatestFirstChanged(
bool checked);
212 void onStyleSheetChanged();
218 void updateSettings();
221 QList<CTextMessageTextEdit *> findAllTextEdit()
const;
224 QString getStyleSheet()
const;
227 void closeTextMessageTab();
230 void updateAllTabs();
233 void topLevelChanged(QWidget *widget,
bool topLevel);
236 void textMessageEntered();
245 bool isVisibleWidgetHack()
const;
251 void emitDisplayInInfoWindow(
const misc::CVariant &message, std::chrono::milliseconds displayDuration);
254 static QString firstPartOfTabText(
const QString &tabText);
void setShowingRealNames(bool show)
Showing real names.
void commandEntered(const QString &commandLine, const swift::misc::CIdentifier &originator)
Command line was entered.
void displayInInfoWindow(const swift::misc::CVariant &message, std::chrono::milliseconds displayDuration)
Message to be displayed in central info window.
void textMessageTabSelected()
Text message tab selected.
bool isShowingRealNames() const
Showing real names.
void setAsUsedInOverlayMode()
Used as overlay and not dock widget.
bool isActivated() const
Text activated.
Value object encapsulating information identifying a component of a modular distributed swift process...
Class template for accessing a specific value in the CSettingsCache.
Wrapper around QVariant which provides transparent access to CValueObject methods of the contained ob...
Value object encapsulating information about an ATC station.
Value object encapsulating information of a callsign.
Value object encapsulating information of a text message.
Value object encapsulating a list of text messages.
Comprehensive information of an aircraft.
#define SWIFT_GUI_EXPORT
Export a class or function from the library.