Skip to content

Commit

Permalink
qml: use NavigationBar2 in Peers
Browse files Browse the repository at this point in the history
  • Loading branch information
promag committed Aug 27, 2023
1 parent be76bac commit 5485cb6
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 16 deletions.
15 changes: 3 additions & 12 deletions src/qml/pages/node/NodeSettings.qml
Original file line number Diff line number Diff line change
Expand Up @@ -197,18 +197,9 @@ Item {
Component {
id: peers_page
Peers {
navLeftDetail: NavButton {
iconSource: "image://images/caret-left"
text: qsTr("Back")
onClicked: {
nodeSettingsView.pop()
peerTableModel.stopAutoRefresh();
}
}
navMiddleDetail: Header {
headerBold: true
headerSize: 18
header: qsTr("Peers")
onBack: {
nodeSettingsView.pop()
peerTableModel.stopAutoRefresh();
}
}
}
Expand Down
18 changes: 14 additions & 4 deletions src/qml/pages/node/Peers.qml
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,22 @@ import "../../controls"
import "../../components"

Page {
signal back

id: root
background: null
property alias navLeftDetail: navbar.leftDetail
property alias navMiddleDetail: navbar.middleDetail

header: NavigationBar {
id: navbar
header: NavigationBar2 {
leftItem: NavButton {
iconSource: "image://images/caret-left"
text: qsTr("Back")
onClicked: root.back()
}
centerItem: Header {
headerBold: true
headerSize: 18
header: qsTr("Peers")
}
}

ListView {
Expand Down

0 comments on commit 5485cb6

Please sign in to comment.