QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
ConnectionStatusRow.qml
Go to the documentation of this file.
1import QtQuick
2import QtQuick.Layouts
3
4import QGroundControl.Controls
5
6RowLayout {
7 id: root
8
9 property color statusColor
10 property string statusText
11 property string buttonText
12 property bool buttonEnabled: true
13 property string buttonObjectName: ""
14
15 signal clicked()
16
17 spacing: ScreenTools.defaultFontPixelWidth
18
19 FixStatusDot {
20 Layout.preferredWidth: ScreenTools.defaultFontPixelHeight * 0.75
21 Layout.preferredHeight: ScreenTools.defaultFontPixelHeight * 0.75
22 Layout.alignment: Qt.AlignVCenter
23 statusColor: root.statusColor
24 }
25
26 QGCLabel {
27 Layout.fillWidth: true
28 text: root.statusText
29 wrapMode: Text.WordWrap
30 }
31
32 QGCButton {
33 objectName: root.buttonObjectName
34 text: root.buttonText
35 enabled: root.buttonEnabled
36 visible: root.buttonText !== ""
37 onClicked: root.clicked()
38 }
39}