diff --git a/qml/main.qml b/qml/main.qml index bd4f05901..e22f57635 100755 --- a/qml/main.qml +++ b/qml/main.qml @@ -33,8 +33,8 @@ ApplicationWindow { contentOrientation: settings.general_screen_rotation===0 ? Qt.PortraitOrientation : Qt.LandscapeOrientation contentItem.rotation: settings.general_screen_rotation - minimumWidth: 480 - minimumHeight: 320 + minimumWidth: 850 + minimumHeight: 480 title: qsTr("QOpenHD EVO") // Transparent background is needed when the video is not rendered via (OpenGL) inside QT, // but rather done independently by using a pipeline that directly goes to the HW composer (e.g. mmal on pi). diff --git a/qml/qml.qrc b/qml/qml.qrc index 55f1b057d..3563af141 100644 --- a/qml/qml.qrc +++ b/qml/qml.qrc @@ -159,6 +159,7 @@ resources/master3.png resources/master4.png resources/master5.png + resources/noconnection.svg ui/widgets/AirspeedTempWidget.qml ui/widgets/AoaWidget.qml ui/widgets/MessageHUDRow.qml @@ -253,7 +254,8 @@ ui/elements/CardToast.qml ui/elements/ButtonYellow.qml ui/configpopup/connect/PaneLocalhost.qml - ui/configpopup/connect/PaneInfo.qml + ui/configpopup/connect/PaneTethering.qml ui/configpopup/connect/GenericInfoPane.qml + ui/elements/ButtonSimple.qml diff --git a/qml/resources/noconnection.svg b/qml/resources/noconnection.svg new file mode 100644 index 000000000..18711360e --- /dev/null +++ b/qml/resources/noconnection.svg @@ -0,0 +1,18 @@ + + + + + + diff --git a/qml/ui/configpopup/connect/ConnectPanel.qml b/qml/ui/configpopup/connect/ConnectPanel.qml index c828c2f13..2b85eeb76 100644 --- a/qml/ui/configpopup/connect/ConnectPanel.qml +++ b/qml/ui/configpopup/connect/ConnectPanel.qml @@ -27,26 +27,26 @@ Item { id: selectItemInStackLayoutBar width: parent.width TabButton { - text: qsTr("INFO") + text: qsTr("TCP") } TabButton{ - text: "LOCAL" - } - TabButton { - text: qsTr("USB Tether") - } - TabButton { - text: qsTr("(USB) Ethernet passive") - } - TabButton { - text: qsTr("(USB) Ethernet active") - } - TabButton { - text: qsTr("WiFi") - } - TabButton { - text: qsTr("Custom (TCP)") + text: "Tethering" } + // TabButton { + // text: qsTr("USB Tether") + // } + // TabButton { + // text: qsTr("(USB) Ethernet passive") + // } + // TabButton { + // text: qsTr("(USB) Ethernet active") + // } + // TabButton { + // text: qsTr("WiFi") + // } + // TabButton { + // text: qsTr("Custom (TCP)") + // } } // placed right below the top bar @@ -59,41 +59,41 @@ Item { currentIndex: selectItemInStackLayoutBar.currentIndex - PaneInfo{ + PaneCustom{ } - PaneLocalhost{ - } + PaneTethering{ + } - PaneUSBTether{ - id: pane_usb_tether - } + // PaneUSBTether{ + // id: pane_usb_tether + // } - GenericInfoPane{ - m_info_text: { - return"1) Make sure ETH_HOTSPOT_E is disabled (Ground param)\n\n"+ - "2) Enable ETH_PASSIVE_F on your openhd ground unit (Ground param)\n\n"+ - "3) Connect your external device running QOpenHD to your ground station via ethernet\n(e.g. ethernet port on rpi 4).\n\n"+ - "4) Make sure to select 'share my internet with ...' when the android connection setup pops up\n\n"+ - "Video and telemetry forwarding should start automatically, and your GCS can get internet from your phone." - } - } - GenericInfoPane{ - m_info_text: { - return "1) Make sure ETH_PASSIVE_F is disabled (Ground param)\n\n"+ - "2) Enable ETH_HOTSPOT_E on your openhd ground unit (Ground param)\n\n"+ - "3) Connect your external device running QOpenHD to your ground station via ethernet\n(e.g. ethernet port on rpi 4).\n\n"+ - "You might have to disable wifi and cellular on your phone !.\n\n"+ - "Video and telemetry forwarding should start automatically." - } - } + // GenericInfoPane{ + // m_info_text: { + // return"1) Make sure ETH_HOTSPOT_E is disabled (Ground param)\n\n"+ + // "2) Enable ETH_PASSIVE_F on your openhd ground unit (Ground param)\n\n"+ + // "3) Connect your external device running QOpenHD to your ground station via ethernet\n(e.g. ethernet port on rpi 4).\n\n"+ + // "4) Make sure to select 'share my internet with ...' when the android connection setup pops up\n\n"+ + // "Video and telemetry forwarding should start automatically, and your GCS can get internet from your phone." + // } + // } + // GenericInfoPane{ + // m_info_text: { + // return "1) Make sure ETH_PASSIVE_F is disabled (Ground param)\n\n"+ + // "2) Enable ETH_HOTSPOT_E on your openhd ground unit (Ground param)\n\n"+ + // "3) Connect your external device running QOpenHD to your ground station via ethernet\n(e.g. ethernet port on rpi 4).\n\n"+ + // "You might have to disable wifi and cellular on your phone !.\n\n"+ + // "Video and telemetry forwarding should start automatically." + // } + // } - PaneWIFI{ - id: wifi - } + // PaneWIFI{ + // id: wifi + // } - PaneCustom{ - id: pane_custom - } + // PaneCustom{ + // id: pane_custom + // } } } diff --git a/qml/ui/configpopup/connect/GenericInfoPane.qml b/qml/ui/configpopup/connect/GenericInfoPane.qml index 6157444f8..e96d2055b 100644 --- a/qml/ui/configpopup/connect/GenericInfoPane.qml +++ b/qml/ui/configpopup/connect/GenericInfoPane.qml @@ -20,8 +20,9 @@ Pane { ScrollView { id:mavlinkExtraWBParamPanel - width: parent.width - height: parent.height + width: parent.width-24 + height: parent.height-24 + anchors.centerIn: parent contentHeight: mainItem.height contentWidth: mainItem.width clip: true diff --git a/qml/ui/configpopup/connect/PaneCustom.qml b/qml/ui/configpopup/connect/PaneCustom.qml index 9ff313c1b..855fa3ea2 100644 --- a/qml/ui/configpopup/connect/PaneCustom.qml +++ b/qml/ui/configpopup/connect/PaneCustom.qml @@ -10,63 +10,58 @@ import OpenHD 1.0 import "../../../ui" as Ui import "../../elements" - Rectangle { width: parent.width height: parent.height - //color: "green" - - property string m_info_text: "ADVANCED - Connect to a ground station (running OpenHD core) located anywhere in your network using TCP.\n"+ - "After connecting (mavlink) via TCP, video will also be streamed to this device (using UDP)." - - ColumnLayout{ - anchors.fill: parent - spacing: 6 + Rectangle { + id: innerRect + width: 300 + height: 300 + anchors.centerIn: parent + anchors.horizontalCenterOffset: 70 + ColumnLayout { + spacing: 6 - Text{ - Layout.alignment: Qt.AlignTop - width:parent.width - wrapMode: Text.WordWrap - text: m_info_text - } - RowLayout{ - TextField { - id: textFieldip - validator: RegExpValidator { - regExp: /^((?:[0-1]?[0-9]?[0-9]|2[0-4][0-9]|25[0-5])\.){0,3}(?:[0-1]?[0-9]?[0-9]|2[0-4][0-9]|25[0-5])$/ + RowLayout { + TextField { + id: textFieldip + validator: RegExpValidator { + regExp: /^((?:[0-1]?[0-9]?[0-9]|2[0-4][0-9]|25[0-5])\.){0,3}(?:[0-1]?[0-9]?[0-9]|2[0-4][0-9]|25[0-5])$/ + } + inputMethodHints: Qt.ImhFormattedNumbersOnly + text: "192.168.178.36" //settings.dev_mavlink_tcp_ip + } + ButtonIconInfoText { + m_info_text: "Connect with a OpenHD Ground Station, via TCP, this will still stream video va UDP for lower latency, after a successful conneciton." } - inputMethodHints: Qt.ImhFormattedNumbersOnly - text: "192.168.178.36" //settings.dev_mavlink_tcp_ip } - ButtonIconInfoText{ - m_info_text: "Enter your grund station IP, then click 'CONNECT TCP'" + + Button { + Layout.alignment: Qt.AlignTop + text: "CONNECT TCP" + onClicked: { + var ip_address = textFieldip.text + if (_qopenhd.is_valid_ip(ip_address)) { + _mavlinkTelemetry.add_tcp_connection_handler(ip_address) + } else { + _qopenhd.show_toast("Please enter a valid ip") + } + } } - } - Button{ - Layout.alignment: Qt.AlignTop - text: "CONNECT TCP" - onClicked: { - var ip_address=textFieldip.text - if(_qopenhd.is_valid_ip(ip_address)){ - _mavlinkTelemetry.add_tcp_connection_handler(ip_address) - }else{ - _qopenhd.show_toast("Please enter a valid ip") + Button { + text: "RE-ENABLE UDP" + onClicked: { + _mavlinkTelemetry.enable_udp() } } - } - Button{ - text: "RE-ENABLE UDP" - onClicked: { - _mavlinkTelemetry.enable_udp() + + // padding to bottom + Item { + Layout.fillHeight: true + Layout.fillWidth: true } } - // padding to bottom - Item{ - Layout.fillHeight: true - Layout.fillWidth: true - } - } } diff --git a/qml/ui/configpopup/connect/PaneTethering.qml b/qml/ui/configpopup/connect/PaneTethering.qml new file mode 100644 index 000000000..a19cbef3b --- /dev/null +++ b/qml/ui/configpopup/connect/PaneTethering.qml @@ -0,0 +1,102 @@ +import QtQuick 2.12 +import QtQuick.Controls 2.12 +import QtQuick.Layouts 1.12 +import QtQuick.Dialogs 1.0 +import QtQuick.Controls.Material 2.12 + +import Qt.labs.settings 1.0 + +import OpenHD 1.0 + +import "../../../ui" as Ui +import "../../elements" +Rectangle { + width: parent.width + height: parent.height + property bool m_local_mode_enabled: _mavlinkTelemetry.udp_localhost_mode_enabled + + + Rectangle { + id: innerRect + width: 300 + height: 300 + anchors.centerIn: parent + anchors.horizontalCenterOffset: 40 + ColumnLayout { + spacing: 6 + + RowLayout { + Button{ + text: m_local_mode_enabled ? "LOCAL MODE ACTIVE" : "ENABLE LOCAL MODE" + Layout.preferredWidth: 180 + onClicked: { + _mavlinkTelemetry.enable_udp() + } + enabled: !m_local_mode_enabled + } + ButtonIconInfoText { + m_info_text: "Use this if you are running QOpenHD on your ground station itself and don't use it as a secondary device."+ + "\n\nIt uses UDP localhost to communicate with OpenHD core via mavlink (best performance and latency)." + } + } + RowLayout { + Button{ + text: "Android Tethering" + Layout.preferredWidth: 180 + onClicked: _qopenhd.android_open_tethering_settings() + } + ButtonIconInfoText { + m_info_text: "1) Connect your phone via high quality USB cable to your ground station.\n\n"+ + "2) enable USB Tethering on your phone.\n\n"+ + "3) Telemetry and video forwarding is started automatically \n\n"+ + " ! Requires a phone and cellular contract that allows USB tethering. !" + } + } + RowLayout { + Button{ + text: "Passive Eth tethering" + Layout.preferredWidth: 180 + //TODO disable active tethering and enable passive when clicking the button + } + ButtonIconInfoText { + m_info_text: "1) Disable ETH_HOTSPOT_E and Enable ETH_PASSIVE_F\n\n"+ + "2) Connect your external device to your ground station via ethernet.\n\n"+ + "3) Select 'share my internet with ...' when the android connection setup pops up\n\n"+ + "Video and telemetry forwarding should start automatically, internet will be forwarded from your phone." + } + } + RowLayout { + Button{ + text: "Active Eth tethering" + Layout.preferredWidth: 180 + //TODO disable passive tethering and enable active when clicking the button + } + ButtonIconInfoText { + m_info_text: "1) Disable ETH_PASSIVE_F and Enable ETH_HOTSPOT_E\n\n"+ + "2) Connect your external device to your ground station via ethernet.\n\n"+ + "You might need to disable wifi and cellular on your phone\n\n"+ + "Video and telemetry forwarding should start automatically, internet will not be available." + } + } + RowLayout { + Button{ + text: "Wifi tethering" + Layout.preferredWidth: 180 + //TODO enable hotspot + } + ButtonIconInfoText { + m_info_text: "1) Enable WIFI_HOTSPOT_E\n\n"+ + "2) Connect to WiFi: openhd pw openhdopenhd\n\n"+ + "3) Press 'Connect' button.\n\n"+ + "NOTE: You cannot use WIFI hotspot during flight (while armed)" + } + } + + // padding to bottom + Item { + Layout.fillHeight: true + Layout.fillWidth: true + } + } + } +} diff --git a/qml/ui/configpopup/credits/Credits.qml b/qml/ui/configpopup/credits/Credits.qml index 9cd693906..e94fd4231 100644 --- a/qml/ui/configpopup/credits/Credits.qml +++ b/qml/ui/configpopup/credits/Credits.qml @@ -43,8 +43,8 @@ Rectangle { id: ee1 visible: true source: "../../../resources/master1.png" - width: consti.height * 0.7 - height: consti.height * 0.7 + width: max.height * 0.7 + height: max.height * 0.7 } } } diff --git a/qml/ui/configpopup/dev/AppDeveloperStatsPanel.qml b/qml/ui/configpopup/dev/AppDeveloperStatsPanel.qml index 83accd948..bf4d3abbc 100644 --- a/qml/ui/configpopup/dev/AppDeveloperStatsPanel.qml +++ b/qml/ui/configpopup/dev/AppDeveloperStatsPanel.qml @@ -10,7 +10,7 @@ import OpenHD 1.0 import "../../../ui" as Ui import "../../elements" -// Dirty here i place stuff that can be usefaully during development +// Dirty here i place stuff that can be usefully during development Rectangle { id: elementAppDeveloperStats Layout.fillHeight: true @@ -22,19 +22,19 @@ Rectangle { color: "#eaeaea" function yes_or_no_as_string(yes){ - if(yes)return "Y" + if(yes) return "Y" return "N" } function get_features_string(){ - var ret="" - ret+="AVCODEC:"+yes_or_no_as_string(QOPENHD_ENABLE_VIDEO_VIA_AVCODEC)+", " - ret+="MMAL:"+yes_or_no_as_string(QOPENHD_HAVE_MMAL)+", " - ret+="GSTREAMER_QMLGLSINK:"+yes_or_no_as_string(QOPENHD_ENABLE_GSTREAMER_QMLGLSINK)+", " + var ret = "" + ret += "AVCODEC:" + yes_or_no_as_string(QOPENHD_ENABLE_VIDEO_VIA_AVCODEC) + ", " + ret += "MMAL:" + yes_or_no_as_string(QOPENHD_HAVE_MMAL) + ", " + ret += "GSTREAMER_QMLGLSINK:" + yes_or_no_as_string(QOPENHD_ENABLE_GSTREAMER_QMLGLSINK) + ", " return ret; } - ColumnLayout{ + ColumnLayout { Layout.fillWidth: true Layout.minimumHeight: 30 spacing: 6 @@ -42,97 +42,122 @@ Rectangle { anchors.left: parent.left anchors.margins: 10 - Button{ + Button { height: 24 text: "Restart local OHD service" - onClicked:{ + onClicked: { _qopenhd.restart_local_oenhd_service() } } - Button{ + Button { id: local_ip_button height: 24 text: "Show local IP" - onClicked:{ - var text=_qopenhd.show_local_ip() - local_ip_button.text=text + onClicked: { + var text = _qopenhd.show_local_ip() + local_ip_button.text = text } } - Button{ + Button { id: exp_set_rates height: 24 text: "Set Tele rates" - onClicked:{ + onClicked: { _mavlinkTelemetry.re_apply_rates() } } - - Text { - id: test1 - text: qsTr("Art Horizon mavlink update rate:"+_fcMavlinkSystem.curr_update_rate_mavlink_message_attitude+" Hz") - } - Text { - id: tele_in - text: qsTr("Tele in"+_mavlinkTelemetry.telemetry_pps_in+" pps") - } - // air - Text { - id: test2 - text: qsTr("video0 FEC encode: "+_cameraStreamModelPrimary.curr_fec_encode_time_avg_min_max) - } - Text { - id: testX - text: qsTr("video0 TX delay: "+_cameraStreamModelPrimary.curr_time_until_tx_min_max_avg) - } - Text { - id: test4 - text: qsTr("video0 FEC block length: "+_cameraStreamModelPrimary.curr_fec_block_length_min_max_avg) - } - // ground - Text { - id: test3 - text: qsTr("video0 FEC decode: "+_cameraStreamModelPrimary.curr_fec_decode_time_avg_min_max) - } - Text { - id: test5 - text: qsTr("FEATURES: "+get_features_string()) - } - Text { - id: test6 - text: qsTr("Screen resolution: "+_qrenderstats.display_width_height_str) - } - Text { - id: test7 - text: qsTr("Window resolution: "+_qrenderstats.window_width_height_str) - } - Text { - id: test8 - text: qsTr("You're running on: "+Qt.platform.os) + Card { + id: infoBox3 + height: 275 + Layout.topMargin: 15 + Layout.leftMargin: 15 + Layout.rightMargin: 15 + width: 480 + cardName: qsTr("Debug") + cardBody: ColumnLayout { + spacing: 6 + Layout.topMargin: 15 + Layout.leftMargin: 15 + Layout.rightMargin: 15 + Text { + id: test1 + text: qsTr("Art Horizon mavlink update rate:" + _fcMavlinkSystem.curr_update_rate_mavlink_message_attitude + " Hz") + Layout.leftMargin: 12 + } + Text { + id: tele_in + text: qsTr("Tele in" + _mavlinkTelemetry.telemetry_pps_in + " pps") + Layout.leftMargin: 12 + } + // air + Text { + id: test2 + text: qsTr("video0 FEC encode: " + _cameraStreamModelPrimary.curr_fec_encode_time_avg_min_max) + Layout.leftMargin: 12 + } + Text { + id: testX + text: qsTr("video0 TX delay: " + _cameraStreamModelPrimary.curr_time_until_tx_min_max_avg) + Layout.leftMargin: 12 + } + Text { + id: test4 + text: qsTr("video0 FEC block length: " + _cameraStreamModelPrimary.curr_fec_block_length_min_max_avg) + Layout.leftMargin: 12 + } + // ground + Text { + id: test3 + text: qsTr("video0 FEC decode: " + _cameraStreamModelPrimary.curr_fec_decode_time_avg_min_max) + Layout.leftMargin: 12 + } + Text { + id: test5 + text: qsTr("FEATURES: " + get_features_string()) + Layout.leftMargin: 12 + } + Text { + id: test6 + text: qsTr("Screen resolution: " + _qrenderstats.display_width_height_str) + Layout.leftMargin: 12 + } + Text { + id: test7 + text: qsTr("Window resolution: " + _qrenderstats.window_width_height_str) + Layout.leftMargin: 12 + } + Text { + id: test8 + text: qsTr("You're running on: " + Qt.platform.os) + Layout.leftMargin: 12 + } + } } - RowLayout{ + + RowLayout { width: parent.width height: 200 visible: _qopenhd.is_linux() - Button{ + Button { text: "Sysctl start openhd" onClicked: { _qopenhd.sysctl_openhd(0); } } - Button{ + Button { text: "Sysctl stop openhd" onClicked: { _qopenhd.sysctl_openhd(1); } } - Button{ + Button { text: "Sysctl enable openhd" onClicked: { _qopenhd.sysctl_openhd(2); } } - Button{ + Button { text: "Sysctl disable openhd" onClicked: { _qopenhd.sysctl_openhd(3); diff --git a/qml/ui/configpopup/log/LogMessagesStatusView.qml b/qml/ui/configpopup/log/LogMessagesStatusView.qml index b180a70a1..49bed9bea 100644 --- a/qml/ui/configpopup/log/LogMessagesStatusView.qml +++ b/qml/ui/configpopup/log/LogMessagesStatusView.qml @@ -15,10 +15,10 @@ Item { Layout.fillHeight: true Layout.fillWidth: true + property int rowHeight: 64 property int elementHeight: 48 property int elementComboBoxWidth: 300 - // Tab bar for selecting items in stack layout TabBar { id: selectItemInStackLayoutBar @@ -42,59 +42,66 @@ Item { anchors.left: selectItemInStackLayoutBar.left anchors.bottom: parent.bottom currentIndex: selectItemInStackLayoutBar.currentIndex + Rectangle { + color: Qt.rgba(0.2, 0.2, 0.2, 1.0) + Rectangle { + width: parent.width - 24 + height: parent.height - 24 + anchors.centerIn: parent + color: Qt.rgba(0.2, 0.2, 0.2, 1.0) - Pane { - // Uses the c++ logmessagemodel under app/logging/logmessagesmodel - ListView { - id: logMessagesModelParentListView - width: parent.width - height: parent.height - model: _ohdlogMessagesModel - delegate: - Rectangle { - color: Qt.rgba(0.3,0.3,0.3) - height: childrenRect.height - width: logMessagesModelParentListView.width //parent.width for some reason we cannot just use parent.width here + // Uses the c++ logmessagemodel under app/logging/logmessagesmodel + ListView { + id: logMessagesModelParentListView + width: parent.width + height: parent.height-12 + model: _ohdlogMessagesModel + delegate: + Rectangle { + color: Qt.rgba(0.2, 0.2, 0.2, 1.0) + height: childrenRect.height + width: logMessagesModelParentListView.width //parent.width for some reason we cannot just use parent.width here - Text { - id: tagView - text: model.tag - color: model.severity_color - anchors { left:parent.left } - } - Text { - text: model.message - anchors { left:tagView.right; verticalCenter: tagView.verticalCenter; leftMargin: 5 } + Text { + id: tagView + text: model.tag + color: model.severity_color + anchors { left:parent.left } + } + Text { + text: model.message + color: "#fff" + anchors { left:tagView.right; verticalCenter: tagView.verticalCenter; leftMargin: 5 } + } } } - } - } - Pane { - // Uses the c++ logmessagemodel under app/logging/logmessagesmodel - ListView { - id: logMessagesModelFCParentListView - width: parent.width - height: parent.height - model: _fclogMessagesModel - delegate: - Rectangle { - color: Qt.rgba(0.3,0.3,0.3) - height: childrenRect.height - width: logMessagesModelFCParentListView.width //parent.width for some reason we cannot just use parent.width here - Text { - id: tagViewFC - text: model.tag - color: model.severity_color - anchors { left:parent.left } - } - Text { - text: model.message - anchors { left:tagViewFC.right; verticalCenter: tagViewFC.verticalCenter; leftMargin: 5 } + // Uses the c++ logmessagemodel under app/logging/logmessagesmodel + ListView { + id: logMessagesModelFCParentListView + width: parent.width + height: parent.height + model: _fclogMessagesModel + delegate: + Rectangle { + color: Qt.rgba(0.2, 0.2, 0.2, 1.0) + height: childrenRect.height + width: logMessagesModelFCParentListView.width //parent.width for some reason we cannot just use parent.width here + + Text { + id: tagViewFC + text: model.tag + color: model.severity_color + anchors { left:parent.left } + } + Text { + text: model.message + anchors { left:tagViewFC.right; verticalCenter: tagViewFC.verticalCenter; leftMargin: 5 } + } } } + // TODO Fetch OpenHD log via journalctl + why the fuck is the second tab invisible } } - // TODO Fetch OpenHD log via journalctl } } diff --git a/qml/ui/configpopup/openhd_settings/MavlinkExtraWBParamPanel.qml b/qml/ui/configpopup/openhd_settings/MavlinkExtraWBParamPanel.qml index 35016334b..fd549678e 100644 --- a/qml/ui/configpopup/openhd_settings/MavlinkExtraWBParamPanel.qml +++ b/qml/ui/configpopup/openhd_settings/MavlinkExtraWBParamPanel.qml @@ -325,8 +325,9 @@ and automatically connect. Otherwise, use the 'FIND AIR UNIT' feature to scan al ScrollView { id:mavlinkExtraWBParamPanel - width: parent.width - height: parent.height + width: parent.width-24 + height: parent.height-24 + anchors.centerIn: parent contentHeight: mainItem.height clip: true //ScrollBar.vertical.policy: ScrollBar.AlwaysOn diff --git a/qml/ui/configpopup/openhd_settings/MavlinkParamPanel.qml b/qml/ui/configpopup/openhd_settings/MavlinkParamPanel.qml index d394b7bd2..dd1ab86aa 100644 --- a/qml/ui/configpopup/openhd_settings/MavlinkParamPanel.qml +++ b/qml/ui/configpopup/openhd_settings/MavlinkParamPanel.qml @@ -39,7 +39,7 @@ Rectangle { anchors.top: parent.top visible: m_progress_perc>=0 && m_progress_perc<=100 impl_curr_progress_perc: m_progress_perc - //impl_curr_color: m_progress_perc>=100 ? "green" : "blue" + impl_curr_color: "#333c4c" } RowLayout{ @@ -48,6 +48,8 @@ Rectangle { height: 48 anchors.top: fetch_all_progress.bottom anchors.topMargin: 1 + anchors.left: parent.left + anchors.leftMargin: 12 ButtonIconWarning{ onClicked: { _messageBoxInstance.set_text_and_show(""+m_name+ " not alive, parameters unavailable. Please check status view."); @@ -116,13 +118,15 @@ Rectangle { //height: 64 //width: 200 height: 64 - width: listView.width + width: listView.width-12 Row { id: elementsRow //anchors.fill: parent spacing: 5 //color: (Positioner.index % 2 == 0) ? "#8cbfd7f3" : "#00000000" height: 64 + anchors.left: parent.left + anchors.leftMargin: 12 Text { anchors.verticalCenter: parent.verticalCenter //font.pixelSize: 20 diff --git a/qml/ui/configpopup/rc/RcInfoScreen.qml b/qml/ui/configpopup/rc/RcInfoScreen.qml index 3e23297cc..df29a61e4 100644 --- a/qml/ui/configpopup/rc/RcInfoScreen.qml +++ b/qml/ui/configpopup/rc/RcInfoScreen.qml @@ -1,8 +1,8 @@ import QtQuick 2.12 +import QtQuick.Window 2.0 import QtQuick.Controls 2.12 import QtQuick.Layouts 1.12 -import QtQuick.Dialogs 1.0 -import QtQuick.Controls.Material 2.12 +import QtGraphicalEffects 1.12 import Qt.labs.settings 1.0 @@ -11,15 +11,12 @@ import OpenHD 1.0 import "../../../ui" as Ui import "../../elements" -Item { +ScrollView { + clip:true + //contentHeight: 850 width: parent.width height: parent.height - - Rectangle{ - width:parent.width - height:parent.height - color: "#eaeaea" - } + background: Rectangle { color: "#eaeaea" } ColumnLayout{ width: parent.width @@ -34,20 +31,33 @@ Item { Layout.leftMargin: 15 Layout.rightMargin: 15 Layout.fillWidth: true - cardName: qsTr("About") + width:parent.width + cardName: qsTr("Info") cardBody: Text { - width: parent.width - height: parent.height - text: qsTr("To enable RC over wifibroadcast go to OpenHD / Ground (Ground parameters set) and set 'ENABLE_JOY_RC' to 'ENABLED',"+ -"connect a joystick (or a RC in joystick mode) and (optionally) reboot.\n"+ -"You can use the other screens to validate/debug your setup.\n"+ -"INFO: Channel mapping is not intuitive, but it works when done correctly.\n"+ -"If you cannot make it work, any proper RC controller (e.g. running EdgeTX / OpenTX)\n"+ -"supports more advanced channel mapping and works via USB !") + text: qsTr("Enable OpenHD-RC: \n\n1.Set 'ENABLE_JOY_RC' to 'ENABLED',\n2.Connect a joystick\n3.Reboot\n\nYou can use the other screens to validate/debug your setup.\n\n") + height: 24 font.pixelSize: 14 - wrapMode: Text.WordWrap + leftPadding: 12 } } + Card { + id: infoBox2 + height: 100 + Layout.topMargin: 15 + Layout.leftMargin: 15 + Layout.rightMargin: 15 + Layout.fillWidth: true + width:parent.width + cardName: qsTr("Channel mapping") + cardBody: + Text { + text: qsTr("Channel mapping is not intuitive, but it works when done correctly.\nIf you cannot make it work, any proper RC controller (e.g. running EdgeTX / OpenTX)\nsupports more advanced channel mapping and works via USB !") + height: 24 + font.pixelSize: 14 + leftPadding: 12 + } + } + } } diff --git a/qml/ui/configpopup/status/ActionsColumn.qml b/qml/ui/configpopup/status/ActionsColumn.qml index 32d7bbb4f..6663e63d0 100644 --- a/qml/ui/configpopup/status/ActionsColumn.qml +++ b/qml/ui/configpopup/status/ActionsColumn.qml @@ -10,9 +10,7 @@ import OpenHD 1.0 import "../../../ui" as Ui import "../../elements" -// Holds the ping, fetch, ... buttons for this panel -// NOTE : Not the power action buttons -Item{ +Item { Timer { id: autopingTimer @@ -20,39 +18,40 @@ Item{ interval: 1000 repeat: true onTriggered: { - _mavlinkTelemetry.ping_all_systems() + _mavlinkTelemetry.ping_all_systems() } } - ColumnLayout{ + ColumnLayout { // 2 Rows - RowLayout{ + anchors.left: parent.left + anchors.leftMargin: 12 + + RowLayout { id: actions_1 width: parent.width - ButtonIconInfo{ + ButtonIconInfo { onClicked: { - _messageBoxInstance.set_text_and_show("Ping all systems, aka check if they respond to the mavlink ping command. Both OpenHD air and ground support - this command, FC only ardupilot / px4 support this command. The command is lossy, aka you might need to use it more than once to get a response from all systems. - No response after >10 tries is a hint that one of your systems is not functioning properly.") + _messageBoxInstance.set_text_and_show("Ping all systems, aka check if they respond to the mavlink ping command. Both OpenHD air and ground support this command, FC only ardupilot / px4 support this command. The command is lossy, aka you might need to use it more than once to get a response from all systems. No response after >10 tries is a hint that one of your systems is not functioning properly.") } } - Button{ + Button { text: "Ping all systems" onClicked: _mavlinkTelemetry.ping_all_systems() } - Switch{ + Switch { text: "Auto-ping" onCheckedChanged: { - if(checked){ + if (checked) { autopingTimer.start() - }else{ + } else { autopingTimer.stop() } } } // Padding - Item{ - + Item { + // Padding } } @@ -60,23 +59,21 @@ Item{ width: parent.width Button { - //font.pixelSize: 14 font.capitalization: Font.MixedCase text: qsTr("DEV-Restart QOpenHD") onPressed: { qopenhdservicedialoque.open_dialoque(0) } } - Button{ - //font.pixelSize: 14 + Button { font.capitalization: Font.MixedCase text: qsTr("DEV-Cancel QOpenHD") onPressed: { qopenhdservicedialoque.open_dialoque(1) } } - Item{ - // padding + Item { + // Padding } } } diff --git a/qml/ui/configpopup/status/PanelStatus.qml b/qml/ui/configpopup/status/PanelStatus.qml index 861395411..8f650b3d4 100644 --- a/qml/ui/configpopup/status/PanelStatus.qml +++ b/qml/ui/configpopup/status/PanelStatus.qml @@ -11,6 +11,7 @@ import "../../../ui" as Ui import "../../elements" Rectangle { + id:mainRect width: parent.width height: parent.height @@ -48,38 +49,33 @@ Rectangle { QOpenHDVersionCard{ id: qopenhdversioncard height: 80 - //anchors.top: airBox.bottom - } - /*Item{ - id: qopenhdversioncard - width: parent.width - height: 80 - }*/ - StatusCardsColumn{ - width: parent.width - height: 300 + StatusCardsColumn{ + width: parent.width + height: 250 - anchors.leftMargin: 12 - anchors.rightMargin: 12 - anchors.topMargin: 12 + anchors.leftMargin: 12 + anchors.rightMargin: 12 + anchors.topMargin: 12 - id: status_openhd_fc - anchors.top: qopenhdversioncard.bottom - } + id: status_openhd_fc + anchors.top: qopenhdversioncard.bottom + } - ActionsColumn{ - width:parent.width - height: 80 - anchors.top: status_openhd_fc.bottom - anchors.topMargin: 2 + ActionsColumn { + id:actionsButtonMenu + width: parent.width + height: 80 + y: (applicationWindow.height-(actionsButtonMenu.height*1.5)) + + } } } - } - PowerActionDialoque{ - id: powerDialog - } - QOpenHDServiceDialoque{ - id: qopenhdservicedialoque + PowerActionDialoque{ + id: powerDialog + } + QOpenHDServiceDialoque{ + id: qopenhdservicedialoque + } } } diff --git a/qml/ui/configpopup/status/QOpenHDVersionCard.qml b/qml/ui/configpopup/status/QOpenHDVersionCard.qml index fb172d4ea..13437e2d7 100644 --- a/qml/ui/configpopup/status/QOpenHDVersionCard.qml +++ b/qml/ui/configpopup/status/QOpenHDVersionCard.qml @@ -22,10 +22,13 @@ Card { hasHeader: false - cardBody: ColumnLayout { + cardBody: + ColumnLayout { + anchors.centerIn: parent + Row { spacing: 12 - leftPadding: 18 + topPadding: 60 Image { id: image @@ -40,36 +43,34 @@ Card { id: title height: 48 color: "#ff3a3a3a" - text: qsTr("QOpenHD-evo-2.5.1-alpha") + text: qsTr("QOpenHD") font.pixelSize: 36 } } - RowLayout{ - height: 14 - width: parent.width - anchors.leftMargin: 18 - anchors.rightMargin: 18 - Text { - id: qopenhd_version - color: "#ff3a3a3a" - text: qsTr(QOPENHD_GIT_VERSION) - } - - Text { - id: license - color: "#ff3a3a3a" - text: qsTr("License: GPLv3") - onLinkActivated: { - Qt.openUrlExternally("https://github.com/OpenHD/QOpenHD/blob/master/LICENSE") - } - } + Text { + id: qopenhd_version + Layout.fillWidth: true + Layout.leftMargin: 75 + height: 48 + color: "#ff3a3a3a" + //text: qsTr(QOPENHD_GIT_VERSION) + text: "2.5.1-evo-alpha" + font.pixelSize: 12 + } + } - Text { - id: qopenhd_commit_hash - color: "#ff3a3a3a" - text: qsTr(QOPENHD_GIT_COMMIT_HASH) - } + Text { + text: qsTr("GPLv3") + height: 60 + color: "#ff3a3a3a" + anchors.bottom: parent.bottom + anchors.bottomMargin: -35 + anchors.right: parent.right + rightPadding: 12 + font.pixelSize: 12 + onLinkActivated: { + Qt.openUrlExternally("https://github.com/OpenHD/QOpenHD/blob/master/LICENSE") } } } diff --git a/qml/ui/configpopup/status/StatusCardBodyOpenHD.qml b/qml/ui/configpopup/status/StatusCardBodyOpenHD.qml index 1b1a5becb..f23211a50 100644 --- a/qml/ui/configpopup/status/StatusCardBodyOpenHD.qml +++ b/qml/ui/configpopup/status/StatusCardBodyOpenHD.qml @@ -23,7 +23,7 @@ ColumnLayout { property string m_version: m_model.openhd_version property string m_last_ping: m_model.last_ping_result_openhd property bool m_is_alive: m_model.is_alive - property string m_qopenhd_version: "2.5.0-beta4X" + property string m_qopenhd_version: "2.5.1-evo-alpha" function get_alive_text(){ return m_is_alive ? "Yes" : "NOT ALIVE !" @@ -33,26 +33,38 @@ ColumnLayout { return m_is_alive ? "green" : "black" } - function get_cards_text(){ - if(!m_is_ground){ - return _wifi_card_air.card_type_as_string; - } - // Ground - var ret=""; - if(_wifi_card_gnd0.alive){ - ret+="[1]"+_wifi_card_gnd0.card_type_as_string; - } - if(_wifi_card_gnd1.alive){ - ret+="\n"+"[2]"+_wifi_card_gnd1.card_type_as_string; - } - if(_wifi_card_gnd2.alive){ - ret+="\n"+"[3]"+_wifi_card_gnd2.card_type_as_string; - } - if(_wifi_card_gnd3.alive){ - ret+="\n"+"[4]"+_wifi_card_gnd3.card_type_as_string; - } - if(ret.length==0)return "N/A"; - return ret; + function get_cards_text() { + if (!m_is_ground) { + var airCardType = _wifi_card_air.card_type_as_string; + airCardType = airCardType.substring(3); + return airCardType; + } + + + // Ground + var ret = ""; + + if (_wifi_card_gnd0.alive) { + ret += _wifi_card_gnd0.card_type_as_string; + } + if (_wifi_card_gnd1.alive) { + ret += "\n" + _wifi_card_gnd1.card_type_as_string; + } + if (_wifi_card_gnd2.alive) { + ret += "\n" + _wifi_card_gnd2.card_type_as_string; + } + if (_wifi_card_gnd3.alive) { + ret += "\n" + _wifi_card_gnd3.card_type_as_string; + } + + if (ret.length == 0) return "N/A"; + + // Remove the first 3 characters if ret is not "N/A" + if (ret !== "N/A") { + ret = ret.substring(3); + } + + return ret; } function gnd_uplink_state(){ @@ -87,16 +99,19 @@ ColumnLayout { RowLayout{ Layout.fillWidth: true Layout.minimumHeight: text_minHeight - spacing: 6 + Layout.leftMargin: 12 + spacing: 3 Text { Layout.preferredWidth: left_part_preferred_with text: qsTr("OHD Version:") + font.bold: true } Text { text: m_version + color: "green" visible: !b_version_warning.visible } - ButtonYellow{ + ButtonSimple{ text: m_version id: b_version_warning onClicked: { @@ -126,22 +141,27 @@ ColumnLayout { RowLayout{ Layout.fillWidth: true Layout.minimumHeight: text_minHeight - spacing: 6 + Layout.leftMargin: 12 + spacing: 3 Text { Layout.preferredWidth: left_part_preferred_with text: qsTr("Last Ping:") + font.bold: true } Text { text: m_last_ping + color: m_last_ping === "N/A" ? "#DC143C" : "green" } } RowLayout{ Layout.fillWidth: true Layout.minimumHeight: text_minHeight - spacing: 6 + Layout.leftMargin: 12 + spacing: 3 Text { Layout.preferredWidth: left_part_preferred_with text: qsTr("Alive: ") + font.bold: true } Text { text: get_alive_text() @@ -151,16 +171,19 @@ ColumnLayout { RowLayout{ Layout.fillWidth: true Layout.minimumHeight: text_minHeight - spacing: 6 + Layout.leftMargin: 12 + spacing: 3 Text { Layout.preferredWidth: left_part_preferred_with text: qsTr(m_is_ground ? "WB Card(s): " : "WB Card:") + font.bold: true } Text { text: get_cards_text() + color: get_cards_text().endsWith("OHD") ? "green" : "DC143C" visible: !b_unsupported_cards_warning.visible } - ButtonYellow{ + ButtonSimple{ id: b_unsupported_cards_warning text: get_cards_text() onClicked: { @@ -188,21 +211,24 @@ ColumnLayout { RowLayout{ Layout.fillWidth: true Layout.minimumHeight: text_minHeight - spacing: 6 + Layout.leftMargin: 12 + visible: m_is_ground Text{ Layout.preferredWidth: left_part_preferred_with text: "Uplink:" + font.bold: true } Text{ text: gnd_uplink_state_text() + color: "green" visible: { var gnd_up_state=gnd_uplink_state() if(gnd_up_state===0 || gnd_up_state===1)return true; return false; } } - ButtonYellow{ + ButtonSimple{ text: gnd_uplink_state_text() onClicked: { var message="Looks like your uplink (GND to AIR) is not functional - please use a supported card on your GND station"+ diff --git a/qml/ui/configpopup/status/StatusCardFooterGenericOHDFC.qml b/qml/ui/configpopup/status/StatusCardFooterGenericOHDFC.qml index 3ec086425..056479d39 100644 --- a/qml/ui/configpopup/status/StatusCardFooterGenericOHDFC.qml +++ b/qml/ui/configpopup/status/StatusCardFooterGenericOHDFC.qml @@ -72,6 +72,7 @@ Item { ButtonIconWarning{ visible: !get_show_power_actions() Layout.alignment: Qt.AlignCenter + height:12 onPressed: { open_warning(); } diff --git a/qml/ui/configpopup/status/StatusCardsColumn.qml b/qml/ui/configpopup/status/StatusCardsColumn.qml index f3b7df07d..8d75b1cef 100644 --- a/qml/ui/configpopup/status/StatusCardsColumn.qml +++ b/qml/ui/configpopup/status/StatusCardsColumn.qml @@ -15,64 +15,78 @@ import "../../elements" // next to each other Item { - RowLayout { - width: parent.width + ColumnLayout { + id: ohdCards + width: parent.width - 24 height: parent.height - - Card { - id: groundBox - Layout.fillHeight: true - Layout.fillWidth: true - cardName: qsTr("OHD Ground station") - - m_style_error: !_ohdSystemGround.is_alive - //m_style_error: false - - cardBody: StatusCardBodyOpenHD{ - m_is_ground: true + anchors.centerIn: parent + property int maximumWidth: width + + RowLayout { + width: parent.width - 24 + Layout.alignment: Qt.AlignHCenter | Qt.AlignVCenter + + Card { + id: groundBox + Layout.fillHeight: true + Layout.fillWidth: true + Layout.maximumWidth: ohdCards.maximumWidth/3 + cardName: qsTr("Ground station") + + visible: _ohdSystemGround.is_alive + + cardBody: StatusCardBodyOpenHD{ + m_is_ground: true + } + + hasFooter: true + cardFooter: StatusCardFooterGenericOHDFC{ + m_type: 0 + } } - hasFooter: true - cardFooter: StatusCardFooterGenericOHDFC{ - m_type: 0 + Card { + id: airBox + Layout.fillHeight: true + Layout.fillWidth: true + Layout.maximumWidth: ohdCards.maximumWidth/3 + cardName: qsTr("Air unit") + visible: _ohdSystemAir.is_alive + cardBody: StatusCardBodyOpenHD{ + m_is_ground: false + } + + hasFooter: true + cardFooter: StatusCardFooterGenericOHDFC{ + m_type: 1 + } } - } - Card { - id: airBox - Layout.fillHeight: true - Layout.fillWidth: true - cardName: qsTr("OHD Air unit") - m_style_error: !_ohdSystemAir.is_alive - //m_style_error: false - cardBody: StatusCardBodyOpenHD{ - m_is_ground: false - } - - hasFooter: true - cardFooter: StatusCardFooterGenericOHDFC{ - m_type: 1 - } - } + Card { + id: fcBox + Layout.fillHeight: true + Layout.fillWidth: true + cardName: qsTr("Flight Controller") + visible: _fcMavlinkSystem.is_alive + cardBody: StatusCardBodyFC{ - Card { - id: fcBox - visible: true - Layout.fillHeight: true - Layout.fillWidth: true - cardName: qsTr("Flight Controller") - m_style_error: !_fcMavlinkSystem.is_alive - //m_style_error: false - cardBody: StatusCardBodyFC{ + } + hasFooter: true + cardFooter: StatusCardFooterGenericOHDFC{ + m_type: 2 + } } - - hasFooter: true - cardFooter: StatusCardFooterGenericOHDFC{ - m_type: 2 - } + Image { + id: ee1 + visible: !_ohdSystemAir.is_alive && !_ohdSystemGround.is_alive && !_ohdSystemGround.is_alive + source: "../../../resources/noconnection.svg" + Layout.alignment: Qt.AlignHCenter | Qt.AlignVCenter + Layout.topMargin: Layout.preferredWidth * -0.15 + Layout.preferredWidth: ohdCards.width * 0.5 + Layout.preferredHeight: Layout.preferredWidth + } } - } // end OpenHD air, ground, FC status cards layout - + } } diff --git a/qml/ui/elements/ButtonIconWarning.qml b/qml/ui/elements/ButtonIconWarning.qml index 97107b6ca..ff58ca9e8 100644 --- a/qml/ui/elements/ButtonIconWarning.qml +++ b/qml/ui/elements/ButtonIconWarning.qml @@ -8,5 +8,6 @@ import QtQuick.Controls.Material 2.12 Button { text: "\uf071" font.family: "Font Awesome 5 Free" - Material.background:Material.Lime + font.pixelSize: 14 + Material.background: "#fffc4c" } diff --git a/qml/ui/elements/ButtonSimple.qml b/qml/ui/elements/ButtonSimple.qml new file mode 100644 index 000000000..9ecda885d --- /dev/null +++ b/qml/ui/elements/ButtonSimple.qml @@ -0,0 +1,21 @@ +import QtQuick 2.12 +import QtQuick.Controls 2.12 +import QtQuick.Dialogs 1.0 +import QtQuick.Controls.Material 2.12 + +Button { + id: control + background: Rectangle { + opacity:0 + } + contentItem: Text { + text: control.text + font: control.font + opacity: enabled ? 1.0 : 0.3 + color: control.down ? "#8B0000" : "#DC143C" + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter + elide: Text.ElideRight + } + +} diff --git a/qml/ui/elements/ButtonYellow.qml b/qml/ui/elements/ButtonYellow.qml index 8564799dd..561ad3ebe 100644 --- a/qml/ui/elements/ButtonYellow.qml +++ b/qml/ui/elements/ButtonYellow.qml @@ -1,9 +1,15 @@ import QtQuick 2.12 import QtQuick.Controls 2.12 -import QtQuick.Dialogs 1.0 +import QtQuick.Controls.Styles 1.4 import QtQuick.Controls.Material 2.12 +import QtQuick.Layouts 1.0 +import QtGraphicalEffects 1.12 +import Qt.labs.settings 1.0 -// Yellow (Lime) background +import OpenHD 1.0 + +// Lime button Button { - Material.background:Material.Lime + Material.accent: Material.Lime + highlighted: true } diff --git a/qml/ui/elements/Card.qml b/qml/ui/elements/Card.qml index 1fd247037..0905f90b3 100644 --- a/qml/ui/elements/Card.qml +++ b/qml/ui/elements/Card.qml @@ -17,7 +17,7 @@ Item { property bool hasHeaderImage: false property int cardRadius: 6 - property color cardNameColor: "#33aaff" + property color cardNameColor: "black" property color borderColor: "#3a000000" property bool m_style_error: false @@ -72,7 +72,7 @@ Item { font.bold: true font.pixelSize: 16 verticalAlignment: Text.AlignVCenter - horizontalAlignment: Text.AlignLeft + horizontalAlignment: Text.AlignHCenter anchors.top: parent.top anchors.left: cardHeaderImage.right leftPadding: 12 @@ -84,6 +84,7 @@ Item { id: cardBodyHolder anchors.top: cardID.bottom anchors.topMargin: 6 + anchors.leftMargin: 12 //anchors.bottom: cardFooterInner.top //anchors.bottomMargin: 3 width: parent.width @@ -107,7 +108,7 @@ Item { children: cardFooter visible: hasFooter - height: 64 + height: 52 color: "#f6f6f6" border.width: 1 border.color: borderColor diff --git a/qml/ui/widgets/Sidebar.qml b/qml/ui/widgets/Sidebar.qml index 5f714a17b..ff757fab2 100644 --- a/qml/ui/widgets/Sidebar.qml +++ b/qml/ui/widgets/Sidebar.qml @@ -89,7 +89,7 @@ BaseWidget { width: parent.width height: parent.height focus: true - snapMode: ListView.SnapOneItem + //snapMode: ListView.SnapOneItem model: ListModel { ListElement { text: " \uf1eb"; subText: "link" } ListElement { text: " \uf03d"; subText: "video" } @@ -215,7 +215,7 @@ BaseWidget { from: 0 to: 3 stepSize: 1 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -246,7 +246,7 @@ BaseWidget { from: 22 to: 58 stepSize: 4 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 22 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -320,7 +320,7 @@ BaseWidget { from: 0 to: 2 stepSize: 1 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -339,7 +339,7 @@ BaseWidget { from: 0 to: 2 stepSize: 1 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -358,7 +358,7 @@ BaseWidget { from: 2 to: 18 stepSize: 2 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 8 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -396,7 +396,7 @@ BaseWidget { from: 0 to: 2 stepSize: 1 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -415,7 +415,7 @@ BaseWidget { from: 0 to: 2 stepSize: 1 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -434,7 +434,7 @@ BaseWidget { from: 0 to: 2 stepSize: 1 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -472,7 +472,7 @@ BaseWidget { from: 0 to: 2 stepSize: 1 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -489,9 +489,9 @@ BaseWidget { Slider { id: recFramerateSlider from: 0 - to: 2 + to: 3 stepSize: 1 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { @@ -510,7 +510,7 @@ BaseWidget { from: 2 to: 18 stepSize: 2 - snapMode: Slider.SnapToStep + //snapMode: Slider.SnapToStep value: 8 // Initial value Material.accent: Material.Grey onValueChanged: {