forked from Public/monero-gui
Merge pull request #834
f7c883aSettings: add wallet creation height and log file paths (Jaquee)31f318aadd wallet creation height getter (Jaquee)94c92baadd daemon/wallet log path getters (Jaquee)8480c70add textBlock component (Jaquee)
This commit is contained in:
7
components/TextBlock.qml
Normal file
7
components/TextBlock.qml
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
import QtQuick 2.0
|
||||||
|
|
||||||
|
TextEdit {
|
||||||
|
wrapMode: Text.Wrap
|
||||||
|
readOnly: true
|
||||||
|
selectByMouse: true
|
||||||
|
}
|
||||||
@@ -473,7 +473,7 @@ Rectangle {
|
|||||||
RowLayout {
|
RowLayout {
|
||||||
Label {
|
Label {
|
||||||
color: "#4A4949"
|
color: "#4A4949"
|
||||||
text: qsTr("Version") + translationManager.emptyString
|
text: qsTr("Debug info") + translationManager.emptyString
|
||||||
fontSize: 16
|
fontSize: 16
|
||||||
anchors.topMargin: 30
|
anchors.topMargin: 30
|
||||||
Layout.topMargin: 30
|
Layout.topMargin: 30
|
||||||
@@ -485,19 +485,28 @@ Rectangle {
|
|||||||
color: "#DEDEDE"
|
color: "#DEDEDE"
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
TextBlock {
|
||||||
id: guiVersion
|
|
||||||
Layout.topMargin: 8
|
Layout.topMargin: 8
|
||||||
color: "#4A4949"
|
Layout.fillWidth: true
|
||||||
text: qsTr("GUI version: ") + Version.GUI_VERSION + translationManager.emptyString
|
text: qsTr("GUI version: ") + Version.GUI_VERSION + translationManager.emptyString
|
||||||
fontSize: 16
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
TextBlock {
|
||||||
id: guiMoneroVersion
|
id: guiMoneroVersion
|
||||||
color: "#4A4949"
|
Layout.fillWidth: true
|
||||||
text: qsTr("Embedded Monero version: ") + Version.GUI_MONERO_VERSION + translationManager.emptyString
|
text: qsTr("Embedded Monero version: ") + Version.GUI_MONERO_VERSION + translationManager.emptyString
|
||||||
fontSize: 16
|
}
|
||||||
|
TextBlock {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
text: (typeof currentWallet == "undefined") ? "" : qsTr("Wallet creation height: ") + currentWallet.walletCreationHeight + translationManager.emptyString
|
||||||
|
}
|
||||||
|
TextBlock {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
text: (typeof currentWallet == "undefined") ? "" : qsTr("Wallet log path: ") + currentWallet.walletLogPath + translationManager.emptyString
|
||||||
|
}
|
||||||
|
TextBlock {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
text: (typeof currentWallet == "undefined") ? "" : qsTr("Daemon log path: ") + currentWallet.daemonLogPath + translationManager.emptyString
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
1
qml.qrc
1
qml.qrc
@@ -141,5 +141,6 @@
|
|||||||
<file>components/QRCodeScanner.qml</file>
|
<file>components/QRCodeScanner.qml</file>
|
||||||
<file>components/Notifier.qml</file>
|
<file>components/Notifier.qml</file>
|
||||||
<file>components/MobileHeader.qml</file>
|
<file>components/MobileHeader.qml</file>
|
||||||
|
<file>components/TextBlock.qml</file>
|
||||||
</qresource>
|
</qresource>
|
||||||
</RCC>
|
</RCC>
|
||||||
|
|||||||
@@ -599,6 +599,16 @@ bool Wallet::useForkRules(quint8 required_version, quint64 earlyBlocks) const
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QString Wallet::getDaemonLogPath() const
|
||||||
|
{
|
||||||
|
return QString::fromStdString(m_walletImpl->getDefaultDataDir()) + "/bitmonero.log";
|
||||||
|
}
|
||||||
|
|
||||||
|
QString Wallet::getWalletLogPath() const
|
||||||
|
{
|
||||||
|
return QCoreApplication::applicationDirPath() + "/monero-wallet-gui.log";
|
||||||
|
}
|
||||||
|
|
||||||
Wallet::Wallet(Monero::Wallet *w, QObject *parent)
|
Wallet::Wallet(Monero::Wallet *w, QObject *parent)
|
||||||
: QObject(parent)
|
: QObject(parent)
|
||||||
, m_walletImpl(w)
|
, m_walletImpl(w)
|
||||||
|
|||||||
@@ -45,6 +45,9 @@ class Wallet : public QObject
|
|||||||
Q_PROPERTY(QString publicViewKey READ getPublicViewKey)
|
Q_PROPERTY(QString publicViewKey READ getPublicViewKey)
|
||||||
Q_PROPERTY(QString secretSpendKey READ getSecretSpendKey)
|
Q_PROPERTY(QString secretSpendKey READ getSecretSpendKey)
|
||||||
Q_PROPERTY(QString publicSpendKey READ getPublicSpendKey)
|
Q_PROPERTY(QString publicSpendKey READ getPublicSpendKey)
|
||||||
|
Q_PROPERTY(QString daemonLogPath READ getDaemonLogPath CONSTANT)
|
||||||
|
Q_PROPERTY(QString walletLogPath READ getWalletLogPath CONSTANT)
|
||||||
|
Q_PROPERTY(quint64 walletCreationHeight READ getWalletCreationHeight CONSTANT)
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
@@ -241,6 +244,10 @@ public:
|
|||||||
QString getSecretSpendKey() const {return QString::fromStdString(m_walletImpl->secretSpendKey());}
|
QString getSecretSpendKey() const {return QString::fromStdString(m_walletImpl->secretSpendKey());}
|
||||||
QString getPublicSpendKey() const {return QString::fromStdString(m_walletImpl->publicSpendKey());}
|
QString getPublicSpendKey() const {return QString::fromStdString(m_walletImpl->publicSpendKey());}
|
||||||
|
|
||||||
|
quint64 getWalletCreationHeight() const {return m_walletImpl->getRefreshFromBlockHeight();}
|
||||||
|
QString getDaemonLogPath() const;
|
||||||
|
QString getWalletLogPath() const;
|
||||||
|
|
||||||
// TODO: setListenter() when it implemented in API
|
// TODO: setListenter() when it implemented in API
|
||||||
signals:
|
signals:
|
||||||
// emitted on every event happened with wallet
|
// emitted on every event happened with wallet
|
||||||
|
|||||||
Reference in New Issue
Block a user