mirror of
https://github.com/Serial-Studio/Serial-Studio.git
synced 2025-01-15 05:22:53 +08:00
Fix menubar warnings
This commit is contained in:
parent
ead69544f2
commit
4a01acabde
@ -222,8 +222,8 @@ Item {
|
||||
textEdit.forceActiveFocus()
|
||||
}
|
||||
|
||||
onClicked: {
|
||||
if (mouse.button == Qt.RightButton) {
|
||||
onClicked: (mouse) => {
|
||||
if (mouse.button === Qt.RightButton) {
|
||||
contextMenu.popup()
|
||||
mouse.accepted = true
|
||||
}
|
||||
|
@ -42,7 +42,7 @@ MenuItem {
|
||||
opacity: root.enabled ? 1 : 0.5
|
||||
|
||||
Item {
|
||||
width: root.indicatorVisible ? root.indicator.width + 4 : 0
|
||||
width: root.indicatorVisible ? 18 : 0
|
||||
}
|
||||
|
||||
Label {
|
||||
|
@ -91,14 +91,14 @@ MenuBar {
|
||||
MenuSeparator {}
|
||||
|
||||
DecentMenuItem {
|
||||
sequence: StandardKey.Print
|
||||
sequence: "ctrl+p"
|
||||
text: qsTr("Print") + "..."
|
||||
enabled: Cpp_IO_Console.saveAvailable
|
||||
onTriggered: Cpp_IO_Console.print(app.monoFont)
|
||||
}
|
||||
|
||||
DecentMenuItem {
|
||||
sequence: StandardKey.Save
|
||||
sequence: "ctrl+s"
|
||||
onClicked: Cpp_IO_Console.save()
|
||||
enabled: Cpp_IO_Console.saveAvailable
|
||||
text: qsTr("Export console output") + "..."
|
||||
@ -109,7 +109,7 @@ MenuBar {
|
||||
DecentMenuItem {
|
||||
text: qsTr("Quit")
|
||||
onTriggered: Qt.quit()
|
||||
sequence: StandardKey.Quit
|
||||
sequence: "ctrl+q"
|
||||
}
|
||||
}
|
||||
|
||||
@ -121,18 +121,18 @@ MenuBar {
|
||||
|
||||
DecentMenuItem {
|
||||
text: qsTr("Copy")
|
||||
sequence: StandardKey.Copy
|
||||
sequence: "ctrl+c"
|
||||
onTriggered: mw.consoleCopy()
|
||||
}
|
||||
|
||||
DecentMenuItem {
|
||||
sequence: StandardKey.SelectAll
|
||||
sequence: "ctrl+a"
|
||||
text: qsTr("Select all") + "..."
|
||||
onTriggered: mw.consoleSelectAll()
|
||||
}
|
||||
|
||||
DecentMenuItem {
|
||||
sequence: StandardKey.Delete
|
||||
sequence: "ctrl+d"
|
||||
onTriggered: mw.consoleClear()
|
||||
text: qsTr("Clear console output")
|
||||
}
|
||||
@ -211,7 +211,7 @@ MenuBar {
|
||||
MenuSeparator {}
|
||||
|
||||
DecentMenuItem {
|
||||
sequence: StandardKey.FullScreen
|
||||
sequence: "f11"
|
||||
onTriggered: mw.toggleFullscreen()
|
||||
text: mw.fullScreen ? qsTr("Exit full screen") :
|
||||
qsTr("Enter full screen")
|
||||
@ -350,7 +350,7 @@ MenuBar {
|
||||
}
|
||||
|
||||
DecentMenuItem {
|
||||
sequence: StandardKey.HelpContents
|
||||
sequence: "f1"
|
||||
text: qsTr("Documentation/wiki") + "..."
|
||||
onTriggered: Qt.openUrlExternally("https://github.com/Serial-Studio/Serial-Studio/wiki")
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user