diff --git a/qml/qml.qrc b/qml/qml.qrc index 0cc509afa..f3907ee16 100644 --- a/qml/qml.qrc +++ b/qml/qml.qrc @@ -1,33 +1,33 @@ - + ../translations/QOpenHD_en.qm resources/cursors/arrow_512_green.png resources/cursors/arrow_512_transparent.png resources/cursors/arrow_512_white.png resources/cursors/hand_white.png - + ../translations/QOpenHD_de.qm - + ../translations/QOpenHD_ru.qm - + ../translations/QOpenHD_es.qm - + ../translations/QOpenHD_fr.qm - + ../translations/QOpenHD_nl.qm - + ../translations/QOpenHD_ro.qm - + ../translations/QOpenHD_it.qm - + ../translations/QOpenHD_zh.qm @@ -187,10 +187,6 @@ ui/elements/SettingBaseElement.qml ui/widgets/WBLinkRateControlWidget.qml ui/widgets/BaseWidgetDefaultUiControlElements.qml - ui/elements/NewSlider.qml - ui/elements/NewComboBox.qml - ui/elements/NewSwitch.qml - ui/elements/NewSpinBox.qml resources/cursors/arrow_512_transparent.png resources/cursors/arrow_512_green.png resources/cursors/arrow_512_white.png diff --git a/qml/ui/configpopup/connect/PaneConnectionMode.qml b/qml/ui/configpopup/connect/PaneConnectionMode.qml index 2588af79a..12219c879 100644 --- a/qml/ui/configpopup/connect/PaneConnectionMode.qml +++ b/qml/ui/configpopup/connect/PaneConnectionMode.qml @@ -64,7 +64,7 @@ Rectangle{ horizontalAlignment: Qt.AlignHCenter font.pixelSize: settings.qopenhd_general_font_pixel_size } - NewComboBox { + ComboBox { Layout.fillWidth: false Layout.fillHeight: true; Layout.preferredWidth: 200 diff --git a/qml/ui/configpopup/openhd_settings/LinkQuickPanel.qml b/qml/ui/configpopup/openhd_settings/LinkQuickPanel.qml index 0f633df95..6cae39cee 100644 --- a/qml/ui/configpopup/openhd_settings/LinkQuickPanel.qml +++ b/qml/ui/configpopup/openhd_settings/LinkQuickPanel.qml @@ -150,7 +150,7 @@ Rectangle{ Row{ anchors.horizontalCenter: parent.horizontalCenter spacing: 8 - NewComboBox { + ComboBox { width: elementComboBoxWidth id: comboBoxFreq model: frequencies_model diff --git a/qml/ui/configpopup/openhd_settings/MavlinkParamEditor.qml b/qml/ui/configpopup/openhd_settings/MavlinkParamEditor.qml index 54d3eef4b..f1cbf6add 100644 --- a/qml/ui/configpopup/openhd_settings/MavlinkParamEditor.qml +++ b/qml/ui/configpopup/openhd_settings/MavlinkParamEditor.qml @@ -324,10 +324,10 @@ Rectangle{ // Value edit part begin // Type int only begin -------------------------- - // For int values that do not have an enum mapping, we use a NewSpinBox such that the user can either + // For int values that do not have an enum mapping, we use a SpinBox such that the user can either // use the +/- to edit the value (for touch screen users) but also allows the user to // type in an int value directly with the keyboard. - NewSpinBox { + SpinBox { id: spinBoxInputParamtypeInt height: customHeight font.pixelSize: 14 @@ -352,7 +352,7 @@ Rectangle{ id: intEnumDynamicListModel ListElement {title: "I SHOULD NEVER APPEAR"; value: 0} } - NewComboBox { + ComboBox { id: intEnumDynamicComboBox height: customHeight font.pixelSize: 14 @@ -373,7 +373,7 @@ Rectangle{ ListElement {title: "I SHOULD NEVER APPEAR"; value:"ERROR"} } - NewComboBox { + ComboBox { id: stringEnumDynamicComboBox height: customHeight font.pixelSize: 14 diff --git a/qml/ui/configpopup/openhd_settings/MavlinkParamPanel.qml b/qml/ui/configpopup/openhd_settings/MavlinkParamPanel.qml index 207ee63b5..90dfdf41b 100644 --- a/qml/ui/configpopup/openhd_settings/MavlinkParamPanel.qml +++ b/qml/ui/configpopup/openhd_settings/MavlinkParamPanel.qml @@ -73,7 +73,7 @@ Rectangle { _messageBoxInstance.set_text_and_show(text) } } - NewSwitch{ + Switch{ checked: settings.screen_settings_openhd_parameters_transparent onCheckedChanged: settings.screen_settings_openhd_parameters_transparent = checked } diff --git a/qml/ui/configpopup/openhd_settings/PopupAnalyzeChannels.qml b/qml/ui/configpopup/openhd_settings/PopupAnalyzeChannels.qml index 54bb4497d..1f938ffbb 100644 --- a/qml/ui/configpopup/openhd_settings/PopupAnalyzeChannels.qml +++ b/qml/ui/configpopup/openhd_settings/PopupAnalyzeChannels.qml @@ -114,7 +114,7 @@ Rectangle{ } enabled: _ohdSystemGround.is_alive && _ohdSystemGround.wb_gnd_operating_mode==0 } - NewComboBox { + ComboBox { Layout.preferredWidth: 150 Layout.minimumWidth: 50 id: comboBoxWhichFrequencyToAnalyze @@ -124,7 +124,7 @@ Rectangle{ pollution_chart.update_pollution_graph(); } } - NewSwitch{ + Switch{ id:normalize_sw checked: m_normalize_data onCheckedChanged: { diff --git a/qml/ui/configpopup/openhd_settings/PopupEnableSTBCLDPC.qml b/qml/ui/configpopup/openhd_settings/PopupEnableSTBCLDPC.qml index ed7724661..ec850adda 100644 --- a/qml/ui/configpopup/openhd_settings/PopupEnableSTBCLDPC.qml +++ b/qml/ui/configpopup/openhd_settings/PopupEnableSTBCLDPC.qml @@ -78,7 +78,7 @@ Rectangle{ } } - NewComboBox { + ComboBox { id: comboBoxNAntennasAir Layout.minimumWidth: 100 Layout.preferredWidth: 450 @@ -91,7 +91,7 @@ Rectangle{ } } } - NewComboBox { + ComboBox { id: comboBoxNAntennasGnd Layout.minimumWidth: 100 Layout.preferredWidth: 450 diff --git a/qml/ui/configpopup/openhd_settings/PopupScanChannels.qml b/qml/ui/configpopup/openhd_settings/PopupScanChannels.qml index 1edc1d237..db63713b7 100644 --- a/qml/ui/configpopup/openhd_settings/PopupScanChannels.qml +++ b/qml/ui/configpopup/openhd_settings/PopupScanChannels.qml @@ -95,7 +95,7 @@ Rectangle{ } } - NewComboBox { + ComboBox { Layout.preferredWidth: 400 Layout.minimumWidth: 100 id: comboBoxWhichFrequencyToScan diff --git a/qml/ui/configpopup/qopenhd_settings/AppDevSettingsView.qml b/qml/ui/configpopup/qopenhd_settings/AppDevSettingsView.qml index bedcb324e..64202d6e3 100755 --- a/qml/ui/configpopup/qopenhd_settings/AppDevSettingsView.qml +++ b/qml/ui/configpopup/qopenhd_settings/AppDevSettingsView.qml @@ -32,7 +32,7 @@ ScrollView { SettingBaseElement{ m_short_description: "DEV_SHOW_WHITELISTED_PARAMS" m_long_description: "Enabling this gives you full controll over the mavlink parameters set openhd exposes (both air and ground) BUT BE WARNED yu can easily break things!" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -46,7 +46,7 @@ ScrollView { SettingBaseElement{ m_short_description:"DEV_SHOW_ADVANCED_BUTTON" m_long_description: "Allows more customization of the mavlink parameters set than what openhd exposes, BE WARNED you can easily break things this way !" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -60,7 +60,7 @@ ScrollView { SettingBaseElement{ m_short_description:"dev_allow_freq_change_when_armed" m_long_description: "Allows changing the frequency and channel width while armed, THIS CAN BREAK YOUR LINK DURING FLIGHT !" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -142,7 +142,7 @@ ScrollView { m_short_description: "Enable audio playback" m_long_description: "Enable live audio playback in QOpenHD, NOTE: audio streaming is not supported in OpenHD yet. Requires restart of QOpenHD." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -157,7 +157,7 @@ ScrollView { m_short_description: "dirty_enable_inav_hacks" m_long_description: "NEVER ENABLE UNLESS YOU HAVE TO. INAV mavlink support is quirky in some ways to say the least." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -172,7 +172,7 @@ ScrollView { m_short_description: "dirty_enable_mavlink_fc_sys_id_check" m_long_description: "Only accept FCs that explicitly expose themselves as autopilot - can fix issues with FC discovery in QOpenHD." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -187,7 +187,7 @@ ScrollView { SettingBaseElement{ m_short_description: "dev_mavlink_via_tcp" m_long_description: "Requires full restart. Connect via TCP instead of UDP. Requires matching server IP." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -216,7 +216,7 @@ ScrollView { SettingBaseElement{ m_short_description: "dev_wb_show_no_stbc_enabled_warning" m_long_description: "Do not show the STBC recommended enabled message" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 diff --git a/qml/ui/configpopup/qopenhd_settings/AppGeneralSettingsView.qml b/qml/ui/configpopup/qopenhd_settings/AppGeneralSettingsView.qml index 79cf8cebc..b7a6c13c6 100755 --- a/qml/ui/configpopup/qopenhd_settings/AppGeneralSettingsView.qml +++ b/qml/ui/configpopup/qopenhd_settings/AppGeneralSettingsView.qml @@ -32,7 +32,7 @@ ScrollView { m_short_description: "Enable speech" m_long_description: "Enable text to speech - events like flight mode change are given as audio messages" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -60,7 +60,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -101,7 +101,7 @@ ScrollView { } - NewSlider { + Slider { id: smoothing_Slider height: elementHeight width: 210 @@ -141,7 +141,7 @@ ScrollView { anchors.left: parent.left } - NewSpinBox { + SpinBox { id: gndBatteryCellspinBox height: elementHeight width: 210 @@ -204,7 +204,7 @@ ScrollView { anchors.left: parent.left } - NewSpinBox { + SpinBox { id: dev_qopenhd_n_cameras_spinbox height: elementHeight width: 210 @@ -230,7 +230,7 @@ ScrollView { m_short_description: "Mavlink sys id" m_long_description: "Mavlink sys id of QOpenHD (this Ground control station application). Leave default (255) ! . Change requires restart." - NewSpinBox { + SpinBox { id: mavlinkSysIDSpinBox height: elementHeight width: 210 @@ -256,7 +256,7 @@ ScrollView { m_short_description: "Hide identity offset lattitude" m_long_description: "Set this to a random value only you know to hide lat identity" - /*NewSpinBox { + /*SpinBox { height: elementHeight width: 210 font.pixelSize: 14 diff --git a/qml/ui/configpopup/qopenhd_settings/AppScreenSettingsView.qml b/qml/ui/configpopup/qopenhd_settings/AppScreenSettingsView.qml index da39fb868..aaa1c4d3d 100755 --- a/qml/ui/configpopup/qopenhd_settings/AppScreenSettingsView.qml +++ b/qml/ui/configpopup/qopenhd_settings/AppScreenSettingsView.qml @@ -43,7 +43,7 @@ ScrollView { } - NewSlider { + Slider { id: screenScaleSpinBox height: elementHeight width: 210 @@ -70,7 +70,7 @@ ScrollView { m_short_description: "Cursor AutoHide" m_long_description: "Automatically hide cursor on inactivity" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -89,7 +89,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Custom cursor" m_long_description: "Customize cursor for high visibility in the field" - NewSpinBox { + SpinBox { width: 210 font.pixelSize: 14 height: elementHeight @@ -111,7 +111,7 @@ ScrollView { m_short_description: "Custom cursor scale" m_long_description: "Scale of your custom cursor. NOTE: Only works if custom cursor is not 0 !" - NewSpinBox { + SpinBox { width: 210 font.pixelSize: 14 height: elementHeight @@ -137,7 +137,7 @@ ScrollView { m_short_description: "Screen rotation" m_long_description: "Rotate QOpenHD, can be usefull if your screen is installed the wrong way around. Might or might not work." // anything other than 0 and 180 can breaks things - NewComboBox { + ComboBox { height: elementHeight anchors.right: parent.right anchors.rightMargin: Qt.inputMethod.visible ? 78 : 18 @@ -169,7 +169,7 @@ ScrollView { m_short_description: "Background transparent" m_long_description: "Use a transparent surface, such that another application can play (hw composer accelerated) video behind the QOpenHD surface." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -184,7 +184,7 @@ ScrollView { m_short_description: "Force full screen" m_long_description: "Force Full screen if QOpenHD is not already full screen" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -199,7 +199,7 @@ ScrollView { m_short_description: "Swap interval 0" m_long_description: "Can decrease latency on x86 / laptop. Requires restart. Experimental." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -215,7 +215,7 @@ ScrollView { m_short_description: "Settings window size" m_long_description: "Change the size of the settings window, such that you can view the live video while changing settings" - NewSpinBox { + SpinBox { width: 210 font.pixelSize: 14 height: elementHeight @@ -236,7 +236,7 @@ ScrollView { m_short_description: "Settings window transparency" m_long_description: "make the openhd parameters window semi-transparent" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -250,7 +250,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Font DPI" m_long_description: "Scale the text / line size of the artifical horizon / ladders, requires restart of QOpenHD." - NewComboBox { + ComboBox { height: elementHeight anchors.right: parent.right anchors.rightMargin: Qt.inputMethod.visible ? 78 : 18 diff --git a/qml/ui/configpopup/qopenhd_settings/AppVehicleSettingsView.qml b/qml/ui/configpopup/qopenhd_settings/AppVehicleSettingsView.qml index d9fb36814..ef6956e26 100755 --- a/qml/ui/configpopup/qopenhd_settings/AppVehicleSettingsView.qml +++ b/qml/ui/configpopup/qopenhd_settings/AppVehicleSettingsView.qml @@ -31,7 +31,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Vehicle Battery Cells" m_long_description: "When show voltage per cell is selected (off by dfault) in the HUD, set this to the N of cells your air battery has." - NewSpinBox { + SpinBox { height: elementHeight width: 210 font.pixelSize: 14 @@ -52,7 +52,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Show FC Messages in HUD" m_long_description: "When enabled, FC log messages are shown in the HUD log messages element,e.g. they might apear before,during and after flight" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -66,7 +66,7 @@ ScrollView { m_short_description: "Set mavlink message rates" m_long_description: "Set mavlink message rate(s) that should work for most users. NOTE: When disabling this feature, you have to manually set the mavlink message rate(s) via mission planner for your autpilot running ardupilot/ PX4 ! After disabling, a reboot of the FC is required." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -81,7 +81,7 @@ ScrollView { SettingBaseElement{ m_short_description: "High mavlink message rates" m_long_description: "Doubles the rates for all mavlink messages - this requires more telemetry bandwidth, but results in an even smoother OSD." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -99,7 +99,7 @@ ScrollView { SettingBaseElement{ m_short_description: "High mavlink message rates RC" m_long_description: "Increases the rate for mavlink down rc channel messages (This does not affect your RC over openhd latency !)" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -117,7 +117,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Log quiet FC warning" m_long_description: "Log a warning when we get heartbeats from the FC, but not proper data" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 diff --git a/qml/ui/configpopup/qopenhd_settings/AppVideoSettingsView.qml b/qml/ui/configpopup/qopenhd_settings/AppVideoSettingsView.qml index 77b708457..25719b014 100755 --- a/qml/ui/configpopup/qopenhd_settings/AppVideoSettingsView.qml +++ b/qml/ui/configpopup/qopenhd_settings/AppVideoSettingsView.qml @@ -39,7 +39,7 @@ ScrollView { m_short_description: "Scale primary video to fit" m_long_description: "Fit the primary video to the exact screen size (discards actual video aspect ratio,aka video is a bit distorted). Not supported on all platforms / implementations. Might require a restart." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -59,7 +59,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Video codec primary" m_long_description: "Video codec of primary stream (main video). Automatically fetched from OpenHD." - NewComboBox { + ComboBox { id: selectVideoCodecPrimary width: 320 height: elementHeight @@ -84,7 +84,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Primary video force SW" m_long_description: "Force SW decode for primary video stream (unless it already defaulted to sw decode). Can fix bug(s) in rare hardware incompability cases." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -98,7 +98,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Primary video udp in port" m_long_description: "UDP port where qopenhd listens for video data for the primary video stream" - NewSpinBox { + SpinBox { height: elementHeight width: 210 font.pixelSize: 14 @@ -118,7 +118,7 @@ ScrollView { m_long_description: "Video codec of secondary stream (pip video). Automatically fetched from OpenHD." // only show to dualcam users visible: settings.dev_qopenhd_n_cameras==2 - NewComboBox { + ComboBox { id: selectVideoCodecSecondary width: 320 height: elementHeight @@ -146,7 +146,7 @@ ScrollView { m_long_description: "Force SW decode for secondary video stream (unless it already defaulted to sw decode). Can fix bug(s) in rare hardware incompability cases." // only show to dualcam users visible: settings.dev_qopenhd_n_cameras==2 - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -161,7 +161,7 @@ ScrollView { m_short_description: "Secondary video udp in port" m_long_description: "UDP port where qopenhd listens for video data for the secondary video stream" visible: settings.dev_qopenhd_n_cameras==2 - NewSpinBox { + SpinBox { height: elementHeight width: 210 font.pixelSize: 14 @@ -193,7 +193,7 @@ ScrollView { height: elementHeight anchors.left: parent.left } - NewComboBox { + ComboBox { width: 320 height: elementHeight anchors.right: parent.right @@ -236,7 +236,7 @@ ScrollView { anchors.left: parent.left } - NewSpinBox { + SpinBox { id: dev_limit_fps_on_test_fileSpinBox height: elementHeight width: 210 @@ -268,7 +268,7 @@ ScrollView { height: elementHeight anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -294,7 +294,7 @@ ScrollView { height: elementHeight anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -320,7 +320,7 @@ ScrollView { height: elementHeight anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -335,7 +335,7 @@ ScrollView { SettingBaseElement{ m_short_description: "dev_rpi_use_external_omx_decode_service" //m_long_description: "On by default, RPI specific." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -348,7 +348,7 @@ ScrollView { SettingBaseElement{ m_short_description: "dev_always_use_generic_external_decode_service" //m_long_description: "Video decode is not done via QOpenHD, but rather in an extra service (started and stopped by QOpenHD). For platforms other than rpi" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -362,7 +362,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Switch primary / secondary video" m_long_description: "Show secondary video in main video window & primary video in pip window (if the platform supports pip)" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 diff --git a/qml/ui/configpopup/qopenhd_settings/AppWidgetSettingsView.qml b/qml/ui/configpopup/qopenhd_settings/AppWidgetSettingsView.qml index 310299701..2e6b2538d 100755 --- a/qml/ui/configpopup/qopenhd_settings/AppWidgetSettingsView.qml +++ b/qml/ui/configpopup/qopenhd_settings/AppWidgetSettingsView.qml @@ -33,7 +33,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Show Downlink RSSI" m_long_description: "RSSI / Stats about downlink" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -48,7 +48,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Show Uplink RSSI" m_long_description: "RSSI / Stats about uplink" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -62,7 +62,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Show live rate control widget" m_long_description: "Trade range / stability for bitrate at run time. Requires hw support." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -76,7 +76,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Show video widget" m_long_description: "More stats about each camera stream, quick resolution changes and quick air recording." - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -111,7 +111,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -140,7 +140,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -168,7 +168,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -197,7 +197,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -226,7 +226,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -255,7 +255,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -284,7 +284,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -313,7 +313,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -342,7 +342,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -371,7 +371,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -400,7 +400,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -429,7 +429,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -458,7 +458,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -487,7 +487,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -516,7 +516,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -545,7 +545,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -574,7 +574,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -603,7 +603,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -633,7 +633,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -662,7 +662,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -691,7 +691,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -720,7 +720,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -749,7 +749,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -778,7 +778,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -807,7 +807,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -836,7 +836,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -865,7 +865,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -894,7 +894,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -925,7 +925,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -954,7 +954,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -982,7 +982,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1010,7 +1010,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1039,7 +1039,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1070,7 +1070,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1088,7 +1088,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Show distance sensor widget" m_long_description: "For UAVs with a distance sensor" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1103,7 +1103,7 @@ ScrollView { SettingBaseElement{ m_short_description: "Show (GPS) time widget" m_long_description: "For UAVs with GPS, shows the time as reported by the UAV" - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1136,7 +1136,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1171,7 +1171,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1199,7 +1199,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1227,7 +1227,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 @@ -1258,7 +1258,7 @@ ScrollView { anchors.left: parent.left } - NewSwitch { + Switch { width: 32 height: elementHeight anchors.rightMargin: Qt.inputMethod.visible ? 96 : 36 diff --git a/qml/ui/configpopup/status/PingUtilColumn.qml b/qml/ui/configpopup/status/PingUtilColumn.qml index 59e8bda52..1f9e0e225 100644 --- a/qml/ui/configpopup/status/PingUtilColumn.qml +++ b/qml/ui/configpopup/status/PingUtilColumn.qml @@ -39,7 +39,7 @@ Item { text: "Ping all systems" onClicked: _mavlinkTelemetry.ping_all_systems() } - NewSwitch { + Switch { text: "Auto-ping" onCheckedChanged: { if (checked) { diff --git a/qml/ui/elements/FontSelect.qml b/qml/ui/elements/FontSelect.qml index 6331c79e6..95829c863 100644 --- a/qml/ui/elements/FontSelect.qml +++ b/qml/ui/elements/FontSelect.qml @@ -18,7 +18,7 @@ Item { update_selection(); } - NewComboBox { + ComboBox { id: fontDropdown anchors.fill: parent font.pixelSize: 14 diff --git a/qml/ui/elements/LanguageSelectForm.ui.qml b/qml/ui/elements/LanguageSelectForm.ui.qml index 826e50ee0..51e5e2223 100644 --- a/qml/ui/elements/LanguageSelectForm.ui.qml +++ b/qml/ui/elements/LanguageSelectForm.ui.qml @@ -2,7 +2,7 @@ import QtQuick 2.12 import QtQuick.Controls 2.12 Item { - NewComboBox { + ComboBox { anchors.fill: parent model: ListModel { diff --git a/qml/ui/elements/NewComboBox.qml b/qml/ui/elements/NewComboBox.qml deleted file mode 100644 index 77722c9c4..000000000 --- a/qml/ui/elements/NewComboBox.qml +++ /dev/null @@ -1,100 +0,0 @@ -import QtQuick 2.12 -import QtQuick.Controls 2.12 - - -//This combobox logic could be improved after a selection is made and -//an escape is still required to "exit" the combo box... - -ComboBox { - id: control - //anchors.fill: parent - - activeFocusOnTab: true - - property bool activeFocusOnPress: false - - property bool selected: false - - property int selection: control.currentIndex - - popup.visible: selected - - background.opacity:.5 - - NumberAnimation { - id: animateBackground - target: background - properties: "opacity" - from: .1 - to: .3 - loops: Animation.Infinite - duration: 1000 - easing {type: Easing.OutBack; overshoot: 5} - } - - onActiveFocusChanged: { - if (control.activeFocus == true){ - background.color="grey" - background.opacity=.3 - } - else if (control.activeFocus == false){ - background.color="white" - background.opacity=.5 - animateBackground.stop() - } - } - - textRole: "text" - - //Keys.forwardTo: comboBox - //Keys.onPressed: allowComplete = (event.key !== Qt.Key_Backspace && event.key !== Qt.Key_Delete); - Keys.onPressed: { - if (event.key === Qt.Key_S){ - if (selected == false){ - control.popup.open() - selected = true - background.color = "#33aaff" - animateBackground.start() - } else { - //console.log("Make Selection"); - control.currentIndex=selection - control.activated(selection) - control.popup.close() - selected = false - } - } else if (event.key === Qt.Key_Escape){ - if (selected == true){ - control.popup.close() - selected = false - control.activeFocus=false - } - else { - animateBackground.stop() - background.color = "grey" - background.opacity=.3 - } - } else if (event.key === Qt.Key_Minus){ - if (selected == true){ - control.incrementCurrentIndex() - selection= selection+1 - //event.accepted = true; - //console.log("event accepted<<<<<<<"); - //event.key = accepted() //prevent the keypress from "bubbling up" to parent - } - } else if (event.key === Qt.Key_Equal){ - if (selected == true){ - control.decrementCurrentIndex() - selection= selection-1 - //event.accepted = true; - //console.log("event accepted<<<<<<<"); - // event.key = accepted() //prevent the keypress from "bubbling up" to parent - } - } - - } - - onPressedChanged: if (pressed)selected=true - - - -} diff --git a/qml/ui/elements/NewSlider.qml b/qml/ui/elements/NewSlider.qml deleted file mode 100644 index 703886c5c..000000000 --- a/qml/ui/elements/NewSlider.qml +++ /dev/null @@ -1,126 +0,0 @@ -import QtQuick 2.12 -import QtQuick.Controls 2.12 -import QtQuick.Layouts 1.12 - -import Qt.labs.settings 1.0 - - -Slider { - id: control - - //NEW feature of this slider is possibility to go vertical - property bool sliderVertical: false - - rotation: sliderVertical ? 90 : 0 - - property bool selected: false - - NumberAnimation { - id: animateHighlight - target: highlight - properties: "width" - from: 5 - to: 35 - loops: Animation.Infinite - duration: 1000 - easing {type: Easing.OutBack; overshoot: 5} - } - - onActiveFocusChanged: { - if (control.activeFocus == true){ - if (selected == false){ - handle.color="grey" - highlight.color="grey" - } - else{ - handle.color="#33aaff" - highlight.color="#33aaff" - animateHighlight.start() - } - } - else if (control.activeFocus == false){ - //console.log("New slider has lost focus"); - handle.color="#33aaff" - highlight.color="transparent" - animateHighlight.stop() - } - } - - onHoveredChanged: { - if (control.hovered == true){ - handle.color="#33aaff" - highlight.color="#33aaff" - animateHighlight.start() - } - else{ - handle.color="#33aaff" - highlight.color="transparent" - animateHighlight.stop() - } - } - - Keys.onPressed: { - if (event.key === Qt.Key_S){ - if (selected == false){ - selected = true - handle.color="#33aaff" - highlight.color="#33aaff" - animateHighlight.start() - } else { - //console.log("Make Selection"); - selected = false - } - } else if (event.key === Qt.Key_Escape){ - if (selected == true){ - selected = false - handle.color="grey" - highlight.color="grey" - animateHighlight.stop() - } - } else if (event.key === Qt.Key_Minus){ - if (selected == true){ - control.increase() - } - } else if (event.key === Qt.Key_Equal){ - if (selected == true){ - control.decrease() - } - } - - } - - handle: Rectangle { - id:handle - x: control.leftPadding + control.visualPosition * (control.availableWidth - width) - y: control.topPadding + control.availableHeight / 2 - height / 2 - width: 20 - height: 20 - radius: width/2 - color: "#33aaff" - - Rectangle { - id:highlight - anchors.centerIn: handle - z:0 - width: 40 - height: highlight.width - radius: width/2 - opacity: .3 - color: "transparent" - - /* This could be extended later to fix the mouse hover effect... - - MouseArea { - anchors.fill: parent - hoverEnabled: true - onEntered: { highlight.color="#33aaff" } - onExited: { highlight.color="transparent" } - - DragHandler { - - target: handle - } - } */ - } - } -} diff --git a/qml/ui/elements/NewSpinBox.qml b/qml/ui/elements/NewSpinBox.qml deleted file mode 100644 index 67cf124e9..000000000 --- a/qml/ui/elements/NewSpinBox.qml +++ /dev/null @@ -1,175 +0,0 @@ -import QtQuick 2.15 -import QtQuick.Controls 2.15 -import QtQuick.Layouts 1.12 -import QtQuick.Controls.Styles 1.4 -import Qt.labs.settings 1.0 - - -SpinBox { - id: control - - property bool selected: false - - NumberAnimation { - id: animatePlus - target: plusHighlight - properties: "width" - from: 20 - to: 40 - loops: Animation.Infinite - duration: 1000 - easing {type: Easing.OutBack; overshoot: 5} - } - - NumberAnimation { - id: animateMinus - target: minusHighlight - properties: "width" - from: 20 - to: 40 - loops: Animation.Infinite - duration: 1000 - easing {type: Easing.OutBack; overshoot: 5} - } - - Keys.onPressed: { - if (event.key === Qt.Key_S){ - selected = true - highlight.color= "#33aaff" - animateMinus.start() - animatePlus.start() - } - else if (event.key === Qt.Key_Escape){ - selected = false - highlight.color= "grey" - } - else if (event.key === Qt.Key_Equal){ - if (selected == true){ - control.increase() - up.pressed - } - } - else if (event.key === Qt.Key_Minus){ - if (selected == true){ - control.decrease() - down.pressed - } - } - } - - onActiveFocusChanged: { - if (control.activeFocus == true){ - //console.log("New spinbox has focus"); - highlight.visible=true - highlight.color= "#33aaff" - - if(control.selected){ - highlight.color= "#33aaff" - } - else - highlight.color= "grey" - } - else if (control.activeFocus == false){ - //console.log("New spinbox has lost focus"); - highlight.visible=false - animateMinus.stop() - animatePlus.stop() - } - } - - contentItem: TextInput { - z: 2 - text: control.textFromValue(control.value, control.locale) - - font: control.font - color: control.activeFocus ? "black" : "grey" - selectionColor: "black" - selectedTextColor: "black" - horizontalAlignment: Qt.AlignHCenter - verticalAlignment: Qt.AlignVCenter - - readOnly: !control.editable - } - - up.indicator: Rectangle { - x: control.mirrored ? 0 : parent.width - width - height: parent.height - implicitWidth: 30 - color: "transparent" - - Rectangle { - id: plusHighlight - anchors.centerIn: parent - width: 30 - height: plusHighlight.width - color: up.pressed ? "grey" : - control.selected ? "#33aaff" : "transparent" - border.color: "transparent" - radius: plusHighlight.width/2 - opacity: .2 - } - - Text { - text: "+" - anchors.centerIn: parent - font.pixelSize: control.font.pixelSize * 2 - color: control.selected ? "black" : "grey" - anchors.fill: parent - fontSizeMode: Text.Fit - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - opacity:1 - } - } - - - down.indicator: Rectangle { - x: control.mirrored ? parent.width - width : 0 - height: parent.height - implicitWidth: 30 - color: "transparent" - - Rectangle { - id: minusHighlight - anchors.centerIn: parent - width: 30 - height: minusHighlight.width - color: down.pressed ? "grey" : - control.selected ? "#33aaff" : "transparent" - border.color: "transparent" - radius: minusHighlight.width/2 - opacity: .2 - } - - Text { - text: "-" - anchors.centerIn: parent - font.pixelSize: control.font.pixelSize * 2 - color: control.selected ? "black" : "grey" - anchors.fill: parent - fontSizeMode: Text.Fit - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - opacity:1 - } - } - - background: Rectangle { - implicitWidth: 100 - border.color: "transparent" - color: "transparent" - radius:12 - } - - Rectangle { - id: highlight //this is the center highlight of the button on text - - z:0 - - anchors.centerIn: parent - width: 60 - height: 35 - radius: 20 - opacity: .3 - } -} diff --git a/qml/ui/elements/NewSwitch.qml b/qml/ui/elements/NewSwitch.qml deleted file mode 100644 index ad503bf3d..000000000 --- a/qml/ui/elements/NewSwitch.qml +++ /dev/null @@ -1,126 +0,0 @@ -import QtQuick 2.12 -import QtQuick.Controls 2.12 -import QtQuick.Layouts 1.12 - -import Qt.labs.settings 1.0 - - -SwitchDelegate { - id: control - text: qsTr("SwitchDelegate") - checked: true - clip:false - - NumberAnimation { - id: animateHighlight - target: highlight - properties: "width" - from: 5 - to: 35 - loops: Animation.Infinite - duration: 1000 - easing {type: Easing.OutBack; overshoot: 5} - } - - Keys.onPressed: { - if (event.key === Qt.Key_S && !event.isAutoRepeat) - checked = !checked; - } - - onActiveFocusChanged: { - if (control.activeFocus == true){ - //console.log("New switch has focus"); - control.highlighted=true - animateHighlight.start() - } - else if (control.activeFocus == false){ - //console.log("New switch has lost focus"); - control.highlighted=false - animateHighlight.stop() - } - } - - contentItem: Text { - rightPadding: control.indicator.width + control.spacing - text: control.text - font: control.font - opacity: enabled ? 1.0 : 0.3 - color: control.down ? "#17a81a" : "#21be2b" - elide: Text.ElideRight - verticalAlignment: Text.AlignVCenter - } - - indicator: Rectangle { - id:pill - implicitWidth: 48 - implicitHeight: 13 - x: control.width - width - control.rightPadding - y: parent.height / 2 - height / 2 - radius: 13 - color: control.checked ? "#7dbcf0" : "#BEBBBA" - border.color: "transparent" - - Rectangle { - id: highlight - - x: control.checked ? parent.width - width : 0 - y: parent.height / 2 - height / 2 - width: 35 - height: 35 - radius: 17 - visible: control.down || control.highlighted - color: control.checked ? "#33aaff" : "grey" - opacity:.3 - } - - Rectangle { - id:knob - x: control.checked ? parent.width - width : 0 - y: parent.height / 2 - height / 2 - width: 22 - height: 22 - radius: 12 - color: control.checked ? "#33aaff" : "#A5A1A0" - border.color: control.checked ? "transparent" : "grey" - opacity: 1 - } - } - - background: Rectangle { - visible:false - } - - MouseArea { - id: mouseArea - - implicitWidth: parent.width - implicitHeight: parent.height - x: control.width - width - control.rightPadding - y: parent.height / 2 - height / 2 - - onClicked: { - - control.clicked(!checked) // emit - - if (control.checked== true) - control.checked=false - else - control.checked=true - } - - hoverEnabled:true - - onEntered: { - control.highlighted=true - if(control.checked) - highlight.color= "#33aaff" - else - highlight.color= "grey" - } - onExited: { - control.highlighted=false - - } - } - -} diff --git a/qml/ui/elements/SettingBaseElement.qml b/qml/ui/elements/SettingBaseElement.qml index 090418bdb..23fe9ff56 100644 --- a/qml/ui/elements/SettingBaseElement.qml +++ b/qml/ui/elements/SettingBaseElement.qml @@ -9,7 +9,7 @@ import QtQuick.Controls.Material 2.12 // NOTE: QOpenHD, not OpenHD/Mavlink settings ! // It does not define the element that is actually then used to edit the QT setting - // See any implementation for an example how to use. -// This element could be a Switch, a NewSpinBox, ... +// This element could be a Switch, a SpinBox, ... // E.g. visualized a single column with this layout: // ---------------------------------------------------------------------------------- // | [Description] [opional info popup] [actuall seting element, empty] | diff --git a/qml/ui/elements/SettingsHeaderElement.qml b/qml/ui/elements/SettingsHeaderElement.qml index ff676a407..b7c015715 100644 --- a/qml/ui/elements/SettingsHeaderElement.qml +++ b/qml/ui/elements/SettingsHeaderElement.qml @@ -9,7 +9,7 @@ import QtQuick.Controls.Material 2.12 // NOTE: QOpenHD, not OpenHD/Mavlink settings ! // It does not define the element that is actually then used to edit the QT setting - // See any implementation for an example how to use. -// This element could be a Switch, a NewSpinBox, ... +// This element could be a Switch, a SpinBox, ... // E.g. visualized a single column with this layout: // ---------------------------------------------------------------------------------- // | [Description] [opional info popup] [actuall seting element, empty] | diff --git a/qml/ui/elements/XDecimalSpinBox.qml b/qml/ui/elements/XDecimalSpinBox.qml index f2e2361cb..3e5d3fdc1 100644 --- a/qml/ui/elements/XDecimalSpinBox.qml +++ b/qml/ui/elements/XDecimalSpinBox.qml @@ -13,7 +13,7 @@ import "../elements" // From https://doc.qt.io/qt-5/qml-qtquick-controls2-spinbox.html // Modified a bit for easier use -NewSpinBox { +SpinBox { // Min,max,default in double space property double m_default_value: 0.00 diff --git a/qml/ui/widgets/AirBatteryWidget.qml b/qml/ui/widgets/AirBatteryWidget.qml index 770331bdd..1005781e2 100644 --- a/qml/ui/widgets/AirBatteryWidget.qml +++ b/qml/ui/widgets/AirBatteryWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: airBatteryWidget width: 96 @@ -76,7 +74,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -98,7 +96,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -147,7 +145,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/AirspeedTempWidget.qml b/qml/ui/widgets/AirspeedTempWidget.qml index a0b0fee71..a1d27d09a 100644 --- a/qml/ui/widgets/AirspeedTempWidget.qml +++ b/qml/ui/widgets/AirspeedTempWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: airspeedTempWidget width: 30 @@ -71,7 +69,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -102,7 +100,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: airspeed_temp_warn_Slider orientation: Qt.Horizontal from: 0 @@ -142,7 +140,7 @@ BaseWidget { anchors.left: airspeed_temp_caution_label.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: airspeed_temp_caution_Slider orientation: Qt.Horizontal from: 10 diff --git a/qml/ui/widgets/AltitudeSecondWidget.qml b/qml/ui/widgets/AltitudeSecondWidget.qml index 834d49fc1..991e7ac36 100644 --- a/qml/ui/widgets/AltitudeSecondWidget.qml +++ b/qml/ui/widgets/AltitudeSecondWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: altitudesecondWidget width: 40 @@ -52,7 +50,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/AltitudeWidget.qml b/qml/ui/widgets/AltitudeWidget.qml index 304b24ade..3af92c2e7 100644 --- a/qml/ui/widgets/AltitudeWidget.qml +++ b/qml/ui/widgets/AltitudeWidget.qml @@ -10,8 +10,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: altitudeWidget width: 64 @@ -78,7 +76,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -99,7 +97,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -120,7 +118,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -141,7 +139,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: altitude_range_Slider orientation: Qt.Horizontal from: 40 diff --git a/qml/ui/widgets/AoaWidget.qml b/qml/ui/widgets/AoaWidget.qml index 36e0e68ec..0ee4a12b1 100644 --- a/qml/ui/widgets/AoaWidget.qml +++ b/qml/ui/widgets/AoaWidget.qml @@ -10,8 +10,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: aoaWidget width: 50 @@ -48,7 +46,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: aoa_max_Slider orientation: Qt.Horizontal from: 15 diff --git a/qml/ui/widgets/ArrowWidget.qml b/qml/ui/widgets/ArrowWidget.qml index 025033f69..9db8bc369 100644 --- a/qml/ui/widgets/ArrowWidget.qml +++ b/qml/ui/widgets/ArrowWidget.qml @@ -7,8 +7,6 @@ import QtQuick.Shapes 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: arrowWidget width: 64 @@ -45,7 +43,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/BaseWidget.qml b/qml/ui/widgets/BaseWidget.qml index 710ee16f5..35d643eab 100644 --- a/qml/ui/widgets/BaseWidget.qml +++ b/qml/ui/widgets/BaseWidget.qml @@ -4,8 +4,6 @@ import QtQuick.Layouts 1.12 import QtQuick.Controls 2.12 import Qt.labs.settings 1.0 -import "../elements" - // This is a base implementation for all HUD widgets - // e.g. it exposes the dragging around, clicking once and clicking long action(s) // for clicking once, set hasWidgetDetail to true and provide the widgetDetailComponent diff --git a/qml/ui/widgets/BaseWidgetDefaultUiControlElements.qml b/qml/ui/widgets/BaseWidgetDefaultUiControlElements.qml index 22a17e56c..dfb736eb1 100644 --- a/qml/ui/widgets/BaseWidgetDefaultUiControlElements.qml +++ b/qml/ui/widgets/BaseWidgetDefaultUiControlElements.qml @@ -3,7 +3,6 @@ import QtQuick.Controls 2.12 import QtQuick.Layouts 1.12 import QtGraphicalEffects 1.12 import Qt.labs.settings 1.0 -import "../elements" // Can be used to quickly add the right UI elements for (persistently) setting scale and opacity for a HUD element (e.g. an element extending BaseWidget) // By default, placed in one of the popups, and more values can be added manually if needed @@ -59,7 +58,7 @@ ColumnLayout{ anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: transparency_slider orientation: Qt.Horizontal from: .1 @@ -89,7 +88,7 @@ ColumnLayout{ anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: item_scale_Slider orientation: Qt.Horizontal from: .5 @@ -119,7 +118,7 @@ ColumnLayout{ anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { orientation: Qt.Horizontal from: .5 value: bw_qquickpainteditem_font_scale @@ -150,7 +149,7 @@ ColumnLayout{ anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -186,7 +185,7 @@ ColumnLayout{ anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/BaseWidgetForm.qml b/qml/ui/widgets/BaseWidgetForm.qml index f41d689ad..ec8155bd8 100644 --- a/qml/ui/widgets/BaseWidgetForm.qml +++ b/qml/ui/widgets/BaseWidgetForm.qml @@ -5,8 +5,6 @@ import QtQuick.Controls 2.12 import OpenHD 1.0 -import "../elements" - /* * This file is WAY longer than I'd like, it's very repetitive and could probably be cleaned * up with a common base Component for some of the elements @@ -107,7 +105,7 @@ Rectangle { Item { anchors.fill: parent - NewComboBox { + ComboBox { id: choiceBox model: ["Top Left", "Top Right", "Bottom Right", "Bottom Left"] } diff --git a/qml/ui/widgets/ControlWidget.qml b/qml/ui/widgets/ControlWidget.qml index 6c4460047..20b4cb1f4 100644 --- a/qml/ui/widgets/ControlWidget.qml +++ b/qml/ui/widgets/ControlWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: controlWidget width: 100 @@ -95,7 +93,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -116,7 +114,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -137,7 +135,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -158,7 +156,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -179,7 +177,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -200,7 +198,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/ControlWidgetSubElement.qml b/qml/ui/widgets/ControlWidgetSubElement.qml index b0e15e617..ca5b64e13 100644 --- a/qml/ui/widgets/ControlWidgetSubElement.qml +++ b/qml/ui/widgets/ControlWidgetSubElement.qml @@ -1,7 +1,5 @@ import QtQuick 2.0 -import "../elements" - // Simple way to show a "stick" position in qml // Draws a big circle to show the full range and // a small circle to show the input itself diff --git a/qml/ui/widgets/DistanceSensorWidget.qml b/qml/ui/widgets/DistanceSensorWidget.qml index 4bc39291a..03d535792 100644 --- a/qml/ui/widgets/DistanceSensorWidget.qml +++ b/qml/ui/widgets/DistanceSensorWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: distancesensorwidget width: 40 diff --git a/qml/ui/widgets/EscTempWidget.qml b/qml/ui/widgets/EscTempWidget.qml index 9730f8cba..1c2eb4934 100644 --- a/qml/ui/widgets/EscTempWidget.qml +++ b/qml/ui/widgets/EscTempWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: escTempWidget width: 30 @@ -47,7 +45,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -78,7 +76,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: esc_temp_warn_Slider orientation: Qt.Horizontal from: 75 @@ -118,7 +116,7 @@ BaseWidget { anchors.left: esc_temp_caution_label.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: esc_temp_caution_Slider orientation: Qt.Horizontal from: 30 diff --git a/qml/ui/widgets/ExampleWidget.qml b/qml/ui/widgets/ExampleWidget.qml index fbf4f6f83..664cb1f5a 100644 --- a/qml/ui/widgets/ExampleWidget.qml +++ b/qml/ui/widgets/ExampleWidget.qml @@ -4,8 +4,6 @@ import QtQuick.Layouts 1.12 import OpenHD 1.0 -import "../elements" - BaseWidget { width: 256 height: 48 diff --git a/qml/ui/widgets/FlightDistanceWidget.qml b/qml/ui/widgets/FlightDistanceWidget.qml index 30d9123d1..6af9a4695 100644 --- a/qml/ui/widgets/FlightDistanceWidget.qml +++ b/qml/ui/widgets/FlightDistanceWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: flightDistanceWidget width: 96 diff --git a/qml/ui/widgets/FlightMahKmWidget.qml b/qml/ui/widgets/FlightMahKmWidget.qml index 88d238182..479c2eb1f 100644 --- a/qml/ui/widgets/FlightMahKmWidget.qml +++ b/qml/ui/widgets/FlightMahKmWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: flightMahKmWidget width: 130 diff --git a/qml/ui/widgets/FlightMahWidget.qml b/qml/ui/widgets/FlightMahWidget.qml index 82c71689f..1a9a727f1 100644 --- a/qml/ui/widgets/FlightMahWidget.qml +++ b/qml/ui/widgets/FlightMahWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: flightMahWidget width: 96 diff --git a/qml/ui/widgets/FlightModeWidget.qml b/qml/ui/widgets/FlightModeWidget.qml index c2fadb051..9ec8fd080 100644 --- a/qml/ui/widgets/FlightModeWidget.qml +++ b/qml/ui/widgets/FlightModeWidget.qml @@ -56,7 +56,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/FlightTimeWidget.qml b/qml/ui/widgets/FlightTimeWidget.qml index 4aa9ab7fc..1b0455f71 100644 --- a/qml/ui/widgets/FlightTimeWidget.qml +++ b/qml/ui/widgets/FlightTimeWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: flightTimeWidget width: 96 diff --git a/qml/ui/widgets/FpvWidget.qml b/qml/ui/widgets/FpvWidget.qml index 3b2ee7c60..99f4b6546 100644 --- a/qml/ui/widgets/FpvWidget.qml +++ b/qml/ui/widgets/FpvWidget.qml @@ -7,8 +7,6 @@ import QtQuick.Controls.Material 2.12 import OpenHD 1.0 -import "../elements" - BaseWidget { id: fpvWidget width: 50 @@ -43,7 +41,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -65,7 +63,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -90,7 +88,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/GPSWidget.qml b/qml/ui/widgets/GPSWidget.qml index 0a9402b9d..d49ffda4f 100644 --- a/qml/ui/widgets/GPSWidget.qml +++ b/qml/ui/widgets/GPSWidget.qml @@ -7,8 +7,6 @@ import QtQuick.Shapes 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: gpsWidget width: 96 @@ -92,7 +90,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -113,7 +111,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -141,7 +139,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -172,7 +170,7 @@ BaseWidget { anchors.left: gps_warn_label.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: gps_warn_Slider orientation: Qt.Horizontal from: 3 @@ -212,7 +210,7 @@ BaseWidget { anchors.left: gps_caution_label.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: gps_caution_Slider orientation: Qt.Horizontal from: .5 diff --git a/qml/ui/widgets/GroundPowerWidget.qml b/qml/ui/widgets/GroundPowerWidget.qml index 99768bd07..7002a9265 100644 --- a/qml/ui/widgets/GroundPowerWidget.qml +++ b/qml/ui/widgets/GroundPowerWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: groundPowerWidget width: 96 @@ -45,7 +43,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -68,7 +66,7 @@ BaseWidget { verticalAlignment: Text.AlignVCenter } - NewComboBox { + ComboBox { id: batteryComboBox width: 100 height: parent.height diff --git a/qml/ui/widgets/HeadingWidget.qml b/qml/ui/widgets/HeadingWidget.qml index 18745f5b7..cf7500c21 100644 --- a/qml/ui/widgets/HeadingWidget.qml +++ b/qml/ui/widgets/HeadingWidget.qml @@ -7,8 +7,6 @@ import QtQuick.Shapes 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: headingWidget width: 48 @@ -53,7 +51,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 12 @@ -74,7 +72,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 12 diff --git a/qml/ui/widgets/HorizonWidget.qml b/qml/ui/widgets/HorizonWidget.qml index d5b48c288..c697546d5 100644 --- a/qml/ui/widgets/HorizonWidget.qml +++ b/qml/ui/widgets/HorizonWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: horizonWidget width: 250 @@ -51,7 +49,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { orientation: Qt.Horizontal from: .3 value: settings.horizon_clip_area_scale @@ -80,7 +78,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: horizon_width_Slider orientation: Qt.Horizontal from: 1 @@ -110,7 +108,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: horizon_spacing_Slider orientation: Qt.Horizontal from: 10 @@ -139,7 +137,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: horizon_range_Slider orientation: Qt.Horizontal from: 1 @@ -168,7 +166,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: horizon_step_Slider orientation: Qt.Horizontal from: 5 @@ -197,7 +195,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -219,7 +217,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -240,7 +238,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -261,7 +259,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { x: 190 y: 0 width: 32 @@ -284,7 +282,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { x: 190 y: 0 width: 32 @@ -308,7 +306,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { x: 190 y: 0 width: 32 @@ -331,7 +329,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { x: 190 y: 0 width: 32 diff --git a/qml/ui/widgets/ImuTempWidget.qml b/qml/ui/widgets/ImuTempWidget.qml index 5a7f33cc4..2286398a0 100644 --- a/qml/ui/widgets/ImuTempWidget.qml +++ b/qml/ui/widgets/ImuTempWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: imuTempWidget width: 30 @@ -46,7 +44,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -77,7 +75,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: imu_temp_warn_Slider orientation: Qt.Horizontal from: 75 @@ -117,7 +115,7 @@ BaseWidget { anchors.left: imu_temp_caution_label.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: imu_temp_caution_Slider orientation: Qt.Horizontal from: 30 diff --git a/qml/ui/widgets/LinkDownRSSIWidget.qml b/qml/ui/widgets/LinkDownRSSIWidget.qml index dbbf0c33a..9e64dbdff 100644 --- a/qml/ui/widgets/LinkDownRSSIWidget.qml +++ b/qml/ui/widgets/LinkDownRSSIWidget.qml @@ -7,8 +7,6 @@ import QtQuick.Shapes 1.0 import OpenHD 1.0 -import "../elements" - import "../../ui" as Ui import "../../ui/elements" import "../elements" @@ -132,7 +130,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -153,7 +151,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -175,7 +173,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { orientation: Qt.Horizontal from: 0 value: settings.downlink_packet_loss_perc_caution @@ -203,7 +201,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { orientation: Qt.Horizontal from: 0 value: settings.downlink_packet_loss_perc_warn @@ -231,7 +229,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -252,7 +250,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -273,7 +271,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/LinkUpRSSIWidget.qml b/qml/ui/widgets/LinkUpRSSIWidget.qml index 7e196d5db..8a27ecd87 100644 --- a/qml/ui/widgets/LinkUpRSSIWidget.qml +++ b/qml/ui/widgets/LinkUpRSSIWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: linkUpRSSIWidget width: 112 diff --git a/qml/ui/widgets/MessageHUD.qml b/qml/ui/widgets/MessageHUD.qml index 34d45b625..ae4a21053 100644 --- a/qml/ui/widgets/MessageHUD.qml +++ b/qml/ui/widgets/MessageHUD.qml @@ -7,8 +7,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: messageWidget property alias messageListView: messageListView diff --git a/qml/ui/widgets/MessageHUDRow.qml b/qml/ui/widgets/MessageHUDRow.qml index c14d9b145..658fc46c6 100644 --- a/qml/ui/widgets/MessageHUDRow.qml +++ b/qml/ui/widgets/MessageHUDRow.qml @@ -7,8 +7,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - Item { height: 25 clip: true diff --git a/qml/ui/widgets/PerformanceHorizonWidget2.qml b/qml/ui/widgets/PerformanceHorizonWidget2.qml index d20f3545b..74400f464 100644 --- a/qml/ui/widgets/PerformanceHorizonWidget2.qml +++ b/qml/ui/widgets/PerformanceHorizonWidget2.qml @@ -7,8 +7,6 @@ import QtQuick.Shapes 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: horizonWidget width: 250 diff --git a/qml/ui/widgets/PressTempWidget.qml b/qml/ui/widgets/PressTempWidget.qml index d38c7458b..1a2952d02 100644 --- a/qml/ui/widgets/PressTempWidget.qml +++ b/qml/ui/widgets/PressTempWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: pressTempWidget width: 30 @@ -46,7 +44,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -77,7 +75,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: press_temp_warn_Slider orientation: Qt.Horizontal from: 75 @@ -117,7 +115,7 @@ BaseWidget { anchors.left: press_temp_caution_label.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: press_temp_caution_Slider orientation: Qt.Horizontal from: 30 diff --git a/qml/ui/widgets/QRenderStatsWidget.qml b/qml/ui/widgets/QRenderStatsWidget.qml index 6d10c08fa..249029fb7 100644 --- a/qml/ui/widgets/QRenderStatsWidget.qml +++ b/qml/ui/widgets/QRenderStatsWidget.qml @@ -8,8 +8,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - // For development, shows some decoding and QT rendering statistics (when applicable) BaseWidget { diff --git a/qml/ui/widgets/RCRssiWidget.qml b/qml/ui/widgets/RCRssiWidget.qml index ff7196f2b..508e314eb 100644 --- a/qml/ui/widgets/RCRssiWidget.qml +++ b/qml/ui/widgets/RCRssiWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - // RSSI reported by the FC, aka the RSSI from the (non-wifibroadcast!) rc controll link // (In case rc over wb is used, this widget should be disabled) BaseWidget { diff --git a/qml/ui/widgets/RollWidget.qml b/qml/ui/widgets/RollWidget.qml index 7f24fee37..5435b5359 100644 --- a/qml/ui/widgets/RollWidget.qml +++ b/qml/ui/widgets/RollWidget.qml @@ -7,8 +7,6 @@ import QtQuick.Shapes 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: rollWidget width: 100 @@ -48,7 +46,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -70,7 +68,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -92,7 +90,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -114,7 +112,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/SOCStatusWidgetAir.qml b/qml/ui/widgets/SOCStatusWidgetAir.qml index c769055bb..b206a4ae6 100644 --- a/qml/ui/widgets/SOCStatusWidgetAir.qml +++ b/qml/ui/widgets/SOCStatusWidgetAir.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: airStatusWidget width: 112 @@ -99,7 +97,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -120,7 +118,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -150,7 +148,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: air_status_cpu_caution_Slider orientation: Qt.Horizontal value: settings.air_status_cpu_caution @@ -189,7 +187,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: air_status_cpu_warn_Slider orientation: Qt.Horizontal value: settings.air_status_cpu_warn @@ -228,7 +226,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: air_status_temp_caution_Slider orientation: Qt.Horizontal value: settings.air_status_temp_caution @@ -267,7 +265,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: air_status_temp_warn_Slider orientation: Qt.Horizontal value: settings.air_status_temp_warn diff --git a/qml/ui/widgets/SOCStatusWidgetGround.qml b/qml/ui/widgets/SOCStatusWidgetGround.qml index 776b777e6..a92a83627 100644 --- a/qml/ui/widgets/SOCStatusWidgetGround.qml +++ b/qml/ui/widgets/SOCStatusWidgetGround.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: groundStatusWidget width: 112 @@ -99,7 +97,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -120,7 +118,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -150,7 +148,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: ground_status_cpu_caution_Slider orientation: Qt.Horizontal value: settings.ground_status_cpu_caution @@ -189,7 +187,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: ground_status_cpu_warn_Slider orientation: Qt.Horizontal value: settings.ground_status_cpu_warn @@ -228,7 +226,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: ground_status_temp_caution_Slider orientation: Qt.Horizontal value: settings.ground_status_temp_caution @@ -267,7 +265,7 @@ BaseWidget { anchors.left: parent.right verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: ground_status_temp_warn_Slider orientation: Qt.Horizontal value: settings.ground_status_temp_warn diff --git a/qml/ui/widgets/Sidebar.qml b/qml/ui/widgets/Sidebar.qml index eb9c74f1f..fa46a00f7 100644 --- a/qml/ui/widgets/Sidebar.qml +++ b/qml/ui/widgets/Sidebar.qml @@ -242,17 +242,17 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: valueSlider from: 0 to: 3 stepSize: 1 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { // Handle the slider value change here - console.log("MCS NewSlider:", value) + console.log("MCS Slider:", value) } } Text{ @@ -262,7 +262,7 @@ BaseWidget { color: "#ffffff" smooth: true } - NewComboBox { + ComboBox { width: 200 model: [ "2312", "2332", "2352", "2372", "2392", "2412", "2432", "2452", "2472", "2492", "2512", "2532", "2572", "2592", "2612", "2632", "2652", "2672", "2692", "2712", "5180", "5200", "5220", "5240", "5260", "5280", "5300", "5320", "5500", "5520", "5540", "5560", "5580", "5600", "5620", "5640", "5660", "5680", "5700", "5745", "5765", "5785", "5805", "5825", "5845", "5865", "5885" ] } @@ -273,17 +273,17 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: txPowerAirSlider from: 22 to: 58 stepSize: 4 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 22 // Initial value Material.accent: Material.Grey onValueChanged: { // Handle the slider value change here - console.log("TX Power Air NewSlider:", value) + console.log("TX Power Air Slider:", value) } } Text{ @@ -369,7 +369,7 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSwitch { + Switch { text: qsTr("") } Text{ @@ -481,13 +481,13 @@ BaseWidget { anchors.centerIn: parent spacing: 5 - NewComboBox { + ComboBox { id:raspberryCams3 visible: true width: 200 model: [ "IMX708","IMX462","IMX477" ] } - NewComboBox { + ComboBox { id:rock5Cams3 visible: false width: 200 @@ -500,16 +500,16 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: resolutionSlider3 from: 0 to: 2 stepSize: 1 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { - console.log("Resolution NewSlider:", value) + console.log("Resolution Slider:", value) } } Text{ @@ -519,7 +519,7 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSwitch { + Switch { } TabBar { id: cameraSwitch @@ -596,16 +596,16 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: isoSlider from: 0 to: 2 stepSize: 1 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { - console.log("Resolution NewSlider:", value) + console.log("Resolution Slider:", value) } } Text{ @@ -615,16 +615,16 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: exposureSlider from: 0 to: 2 stepSize: 1 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { - console.log("Framerate NewSlider:", value) + console.log("Framerate Slider:", value) } } Text{ @@ -634,16 +634,16 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: modeSlider from: 0 to: 2 stepSize: 1 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { - console.log("Resolution NewSlider:", value) + console.log("Resolution Slider:", value) } } } @@ -705,16 +705,16 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: recResolutionSlider from: 0 to: 2 stepSize: 1 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { - console.log("Resolution NewSlider:", value) + console.log("Resolution Slider:", value) } } Text{ @@ -724,16 +724,16 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: recFramerateSlider from: 0 to: 3 stepSize: 1 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 0 // Initial value Material.accent: Material.Grey onValueChanged: { - console.log("Framerate NewSlider:", value) + console.log("Framerate Slider:", value) } } Text{ @@ -743,16 +743,16 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSlider { + Slider { id: recBitrateSlider from: 2 to: 18 stepSize: 2 - //snapMode: NewSlider.SnapToStep + //snapMode: Slider.SnapToStep value: 8 // Initial value Material.accent: Material.Grey onValueChanged: { - console.log("Birtate NewSlider:", value) + console.log("Birtate Slider:", value) } } Text{ @@ -762,7 +762,7 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSwitch { + Switch { } } } @@ -824,7 +824,7 @@ BaseWidget { color: "#ffffff" smooth: true } - NewComboBox { + ComboBox { id:displayResolution visible: true width: 200 @@ -837,7 +837,7 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSwitch { + Switch { text: qsTr("Wifi Hotspot") } Text{ @@ -847,7 +847,7 @@ BaseWidget { color: "#ffffff" smooth: true } - NewSwitch { + Switch { text: qsTr("Ethernet Hotspot") } Text{ diff --git a/qml/ui/widgets/SpeedSecondWidget.qml b/qml/ui/widgets/SpeedSecondWidget.qml index 740b613a5..7413de0ef 100644 --- a/qml/ui/widgets/SpeedSecondWidget.qml +++ b/qml/ui/widgets/SpeedSecondWidget.qml @@ -6,8 +6,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: speedsecondWidget width: 80 @@ -77,7 +75,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -98,7 +96,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -119,7 +117,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/SpeedWidget.qml b/qml/ui/widgets/SpeedWidget.qml index 0d2274d68..c727480ee 100644 --- a/qml/ui/widgets/SpeedWidget.qml +++ b/qml/ui/widgets/SpeedWidget.qml @@ -8,8 +8,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: speedWidget width: 64 @@ -86,7 +84,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -107,7 +105,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -128,7 +126,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -149,7 +147,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -170,7 +168,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: speed_range_Slider orientation: Qt.Horizontal from: 40 @@ -200,7 +198,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: speed_minimum_Slider orientation: Qt.Horizontal from: 0 diff --git a/qml/ui/widgets/UAVTimeWiget.qml b/qml/ui/widgets/UAVTimeWiget.qml index feda8c7e4..2262bd712 100644 --- a/qml/ui/widgets/UAVTimeWiget.qml +++ b/qml/ui/widgets/UAVTimeWiget.qml @@ -8,8 +8,6 @@ import QtQml 2.15 import OpenHD 1.0 -import "../elements" - BaseWidget { id: uavtmewidget width: 100 diff --git a/qml/ui/widgets/VerticalSpeedGaugeWidget.qml b/qml/ui/widgets/VerticalSpeedGaugeWidget.qml index e78c06b92..836bf66a1 100644 --- a/qml/ui/widgets/VerticalSpeedGaugeWidget.qml +++ b/qml/ui/widgets/VerticalSpeedGaugeWidget.qml @@ -10,8 +10,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: vsGaugeWidget width: 50 @@ -60,7 +58,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: vsi_max_Slider orientation: Qt.Horizontal from: 5 diff --git a/qml/ui/widgets/VerticalSpeedSimpleWidget.qml b/qml/ui/widgets/VerticalSpeedSimpleWidget.qml index 0032b809b..9576654f0 100644 --- a/qml/ui/widgets/VerticalSpeedSimpleWidget.qml +++ b/qml/ui/widgets/VerticalSpeedSimpleWidget.qml @@ -10,8 +10,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: vsiWidget width: 64 @@ -100,7 +98,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -122,7 +120,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/VibrationWidget.qml b/qml/ui/widgets/VibrationWidget.qml index 168405f8d..85bec7c21 100644 --- a/qml/ui/widgets/VibrationWidget.qml +++ b/qml/ui/widgets/VibrationWidget.qml @@ -8,8 +8,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - BaseWidget { id: vibrationWidget width: 60 diff --git a/qml/ui/widgets/VideoBitrateWidgetGeneric.qml b/qml/ui/widgets/VideoBitrateWidgetGeneric.qml index 40b2b6ba2..bbdecf748 100644 --- a/qml/ui/widgets/VideoBitrateWidgetGeneric.qml +++ b/qml/ui/widgets/VideoBitrateWidgetGeneric.qml @@ -146,7 +146,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -190,7 +190,7 @@ BaseWidget { } } - NewComboBox{ + ComboBox{ id: resolution_fps_cb model: resolutions_model textRole: "title" diff --git a/qml/ui/widgets/VideoBitrateWidgetPrimary.qml b/qml/ui/widgets/VideoBitrateWidgetPrimary.qml index 3363da21b..551d81971 100644 --- a/qml/ui/widgets/VideoBitrateWidgetPrimary.qml +++ b/qml/ui/widgets/VideoBitrateWidgetPrimary.qml @@ -8,8 +8,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - VideoBitrateWidgetGeneric{ visible: settings.show_bitrate diff --git a/qml/ui/widgets/VideoBitrateWidgetSecondary.qml b/qml/ui/widgets/VideoBitrateWidgetSecondary.qml index 1d0da96ec..ebbd9c7e7 100644 --- a/qml/ui/widgets/VideoBitrateWidgetSecondary.qml +++ b/qml/ui/widgets/VideoBitrateWidgetSecondary.qml @@ -8,8 +8,6 @@ import Qt.labs.settings 1.0 import OpenHD 1.0 -import "../elements" - VideoBitrateWidgetGeneric{ m_is_for_primary_camera: false // Also show it if air has a seconary cam diff --git a/qml/ui/widgets/WBLinkRateControlWidget.qml b/qml/ui/widgets/WBLinkRateControlWidget.qml index 7198f5b1b..9ee17494f 100644 --- a/qml/ui/widgets/WBLinkRateControlWidget.qml +++ b/qml/ui/widgets/WBLinkRateControlWidget.qml @@ -225,7 +225,7 @@ Make the video more stable (less microfreezes) on the cost of less image quality anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -246,7 +246,7 @@ Make the video more stable (less microfreezes) on the cost of less image quality anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -267,7 +267,7 @@ Make the video more stable (less microfreezes) on the cost of less image quality anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -288,7 +288,7 @@ Make the video more stable (less microfreezes) on the cost of less image quality anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -311,7 +311,7 @@ Make the video more stable (less microfreezes) on the cost of less image quality anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -382,7 +382,7 @@ Make the video more stable (less microfreezes) on the cost of less image quality width: parent.width height: m_row_height - NewComboBox{ + ComboBox{ width: parent.width height: m_row_height id: mcs_cb @@ -417,7 +417,7 @@ Make the video more stable (less microfreezes) on the cost of less image quality Row{ width: parent.width height: m_row_height - NewComboBox{ + ComboBox{ width: parent.width height: m_row_height id: pollution_cb diff --git a/qml/ui/widgets/WindWidget.qml b/qml/ui/widgets/WindWidget.qml index f093534ab..5eed74071 100644 --- a/qml/ui/widgets/WindWidget.qml +++ b/qml/ui/widgets/WindWidget.qml @@ -8,7 +8,6 @@ import QtQuick.Shapes 1.0 import OpenHD 1.0 -import "../elements" /* Plane or Copter decides if the widget will use mavlink wind msg (only available for planes) or openhd calculated wind messages which are based on expected tilt vs actual tilt. @@ -52,7 +51,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -73,7 +72,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 diff --git a/qml/ui/widgets/map/MapWidgetForm.ui.qml b/qml/ui/widgets/map/MapWidgetForm.ui.qml index beabfae41..ce5f1ce2b 100644 --- a/qml/ui/widgets/map/MapWidgetForm.ui.qml +++ b/qml/ui/widgets/map/MapWidgetForm.ui.qml @@ -13,8 +13,6 @@ import "../"; import OpenHD 1.0 -import "../../elements" - BaseWidget { id: mapWidget @@ -100,7 +98,7 @@ BaseWidget { verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: mini_zoomSlider orientation: Qt.Horizontal from: 1 @@ -129,7 +127,7 @@ BaseWidget { verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: mini_sizeSlider orientation: Qt.Horizontal from: 0.25 @@ -156,7 +154,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { orientation: Qt.Horizontal from: .1 value: settings.map_opacity_minimized @@ -181,7 +179,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -202,7 +200,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -223,7 +221,7 @@ BaseWidget { anchors.left: parent.left verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { width: 32 height: parent.height anchors.rightMargin: 6 @@ -430,7 +428,7 @@ BaseWidget { spacing: 6 width: settingsVisible ? 488 : 0 - NewComboBox { + ComboBox { id: providerDropdown height: 48 width: parent.width @@ -442,7 +440,7 @@ BaseWidget { } - NewComboBox { + ComboBox { id: variantDropdown height: 48 width: parent.width @@ -465,7 +463,7 @@ BaseWidget { verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { id: zoomSlider orientation: Qt.Horizontal from: 1 @@ -496,7 +494,7 @@ BaseWidget { verticalAlignment: Text.AlignVCenter } - NewSlider { + Slider { orientation: Qt.Horizontal from: .1 value: settings.map_opacity_maximized @@ -525,7 +523,7 @@ BaseWidget { verticalAlignment: Text.AlignVCenter } - NewSwitch { + Switch { id: switch1 width: 32 height: parent.height diff --git a/qml/video/SecondaryVideoGStreamer.qml b/qml/video/SecondaryVideoGStreamer.qml index 00100f54e..46203e77a 100644 --- a/qml/video/SecondaryVideoGStreamer.qml +++ b/qml/video/SecondaryVideoGStreamer.qml @@ -194,7 +194,7 @@ Item { width: 100 text: "Minimized Width (px)" } - NewSpinBox { + SpinBox { stepSize: 1 editable: true from:25 @@ -211,7 +211,7 @@ Item { width: 100 text: "Minimized Height (px)" } - NewSpinBox { + SpinBox { stepSize: 1 editable: true from:25 @@ -228,7 +228,7 @@ Item { width: 100 text: "Maximize factor %" } - NewSpinBox { + SpinBox { stepSize: 1 editable: true from:120