display more info in the about section

This commit is contained in:
Iuri Matias 2020-06-17 17:05:59 -04:00
parent 22721f3c47
commit 965e71e45d
5 changed files with 78 additions and 1 deletions

View File

@ -63,3 +63,6 @@ QtObject:
proc logout*(self: ProfileView) {.slot.} =
self.status.profile.logout()
proc nodeVersion*(self: ProfileView): string {.slot.} =
self.status.getNodeVersion()

View File

@ -9,3 +9,6 @@ proc saveSettings*(key: string, value: string): string =
proc getSettings*(): string =
callPrivateRPC("settings_getSettings")
# TODO: return an Table/Object instead of string
proc getWeb3ClientVersion*(): string =
parseJson(callPrivateRPC("web3_clientVersion"))["result"].getStr

View File

@ -2,6 +2,7 @@ import eventemitter
import libstatus/accounts as libstatus_accounts
import libstatus/core as libstatus_core
import libstatus/settings as libstatus_settings
import chat as chat
import accounts as accounts
@ -50,3 +51,6 @@ proc reset*(self: Status) =
# NOT NEEDED self.profile.reset()
# TODO: add all resets here
proc getNodeVersion*(self: Status): string =
libstatus_settings.getWeb3ClientVersion()

View File

@ -202,8 +202,9 @@ Rectangle {
TabButton {
id: helpTabButton
width: profileInfoContainer.w
height: profileTabBar.btnheight
height: 0 //profileTabBar.btnheight
text: ""
visible: false
anchors.left: parent.left
anchors.leftMargin: 0
anchors.top: advancedTabButton.bottom

View File

@ -20,4 +20,70 @@ Item {
font.weight: Font.Bold
font.pixelSize: 20
}
Text {
id: element10
text: qsTr("Status Desktop")
anchors.left: parent.left
anchors.leftMargin: 24
anchors.top: element9.top
anchors.topMargin: 58
font.weight: Font.Bold
font.pixelSize: 14
}
Text {
id: element11
text: qsTr("Version: 1.0")
anchors.left: parent.left
anchors.leftMargin: 24
anchors.top: element10.top
anchors.topMargin: 58
font.weight: Font.Bold
font.pixelSize: 14
}
Text {
id: element12
text: qsTr("Node Version: %1").arg(profileModel.nodeVersion())
anchors.left: parent.left
anchors.leftMargin: 24
anchors.top: element11.top
anchors.topMargin: 58
font.weight: Font.Bold
font.pixelSize: 14
}
Text {
id: privacyPolicyLink
text: "<a href='https://www.iubenda.com/privacy-policy/45710059'>Privacy Policy</a>"
anchors.left: parent.left
anchors.leftMargin: 24
anchors.top: element12.top
anchors.topMargin: 58
onLinkActivated: Qt.openUrlExternally(link)
MouseArea {
anchors.fill: parent
acceptedButtons: Qt.NoButton // we don't want to eat clicks on the Text
cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.ArrowCursor
}
}
Text {
text: "<a href='https://status.im/docs/FAQs.html'>Frequently asked questions</a>"
anchors.left: parent.left
anchors.leftMargin: 24
anchors.top: privacyPolicyLink.top
anchors.topMargin: 58
onLinkActivated: Qt.openUrlExternally(link)
MouseArea {
anchors.fill: parent
acceptedButtons: Qt.NoButton // we don't want to eat clicks on the Text
cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.ArrowCursor
}
}
}
/*##^##
Designer {
D{i:0;height:600;width:800}
}
##^##*/