Files
tustu/app_qml/DiagnosticsView.qml
johndoe6345789 741702cedf feat: Add Offline Activation Dialog and Registration Dialog
- Implemented OfflineActivationDialog.qml for offline activation process with detailed instructions and file handling.
- Created RegistrationDialog.qml for user registration with manual input and email parsing options.
- Added new components: RoundGauge.qml, ScalarEditor.qml, Table2DEditor.qml, Table3DEditor.qml, TableEditorPanel.qml, and TableEditorView.qml for enhanced table editing features.
- Updated main.py to include clipboard operations and file handling for saving/loading activation requests and codes.
- Enhanced README.md to document new features and file structure.
2026-01-11 03:11:28 +00:00

108 lines
3.1 KiB
QML

import QtQuick
import QtQuick.Controls
import QtQuick.Layouts
Item {
id: diagnosticsView
ColumnLayout {
anchors.fill: parent
anchors.margins: 10
spacing: 10
Label {
text: "ECU Diagnostics"
font.pixelSize: 18
font.bold: true
}
GroupBox {
Layout.fillWidth: true
title: "Connection Status"
GridLayout {
anchors.fill: parent
columns: 2
rowSpacing: 8
columnSpacing: 15
Label { text: "Connection:" }
Label {
text: "Not Connected"
color: "#e74c3c"
font.bold: true
}
Label { text: "Port:" }
Label { text: "N/A" }
Label { text: "Baud Rate:" }
Label { text: "115200" }
Label { text: "ECU Type:" }
Label { text: "MegaSquirt-II" }
Label { text: "Firmware:" }
Label { text: "v3.4.2" }
}
}
GroupBox {
Layout.fillWidth: true
title: "Error Codes"
ScrollView {
anchors.fill: parent
implicitHeight: 200
ListView {
model: ListModel {
ListElement { code: "P0301"; description: "Cylinder 1 Misfire Detected" }
ListElement { code: "P0171"; description: "System Too Lean (Bank 1)" }
ListElement { code: "P0420"; description: "Catalyst System Efficiency Below Threshold" }
}
delegate: ItemDelegate {
width: ListView.view.width
RowLayout {
anchors.fill: parent
spacing: 10
Label {
text: code
font.bold: true
color: "#e74c3c"
}
Label {
text: description
Layout.fillWidth: true
}
}
}
}
}
}
RowLayout {
Layout.fillWidth: true
spacing: 10
Button {
text: "Clear Codes"
onClicked: console.log("Clear error codes")
}
Button {
text: "Refresh"
onClicked: console.log("Refresh diagnostics")
}
Item { Layout.fillWidth: true }
}
Item { Layout.fillHeight: true }
}
}