diff options
| author | Ilya Kitaev <mbg033@gmail.com> | 2016-10-04 23:12:58 +0300 |
|---|---|---|
| committer | Ilya Kitaev <mbg033@gmail.com> | 2016-10-10 00:15:17 +0300 |
| commit | 522b0671adf946bb4def414f1bbdbca492cf0cd6 (patch) | |
| tree | 104fef4388b6007527e7d4a42e541842b98f0a24 /components | |
| parent | 9cc92bf9d69652104b28e0907de12d83cfadaa20 (diff) | |
| download | monzero-gui-522b0671adf946bb4def414f1bbdbca492cf0cd6.tar.gz monzero-gui-522b0671adf946bb4def414f1bbdbca492cf0cd6.tar.xz monzero-gui-522b0671adf946bb4def414f1bbdbca492cf0cd6.zip | |
Simple transaction history
Diffstat (limited to 'components')
| -rw-r--r-- | components/HistoryTable.qml | 53 |
1 files changed, 33 insertions, 20 deletions
diff --git a/components/HistoryTable.qml b/components/HistoryTable.qml index 15e3a7d8..13bf3775 100644 --- a/components/HistoryTable.qml +++ b/components/HistoryTable.qml @@ -29,10 +29,12 @@ import QtQuick 2.0 import moneroComponents.Clipboard 1.0 + ListView { id: listView clip: true boundsBehavior: ListView.StopAtBounds + property var previousItem footer: Rectangle { height: 127 @@ -48,7 +50,7 @@ ListView { } } - property var previousItem + delegate: Rectangle { id: delegate height: 114 @@ -63,13 +65,13 @@ ListView { anchors.right: parent.right anchors.top: parent.top anchors.topMargin: 14 - + // -- direction indicator Rectangle { id: dot width: 14 height: width radius: width / 2 - color: out ? "#FF4F41" : "#36B05B" + color: isOut ? "#FF4F41" : "#36B05B" } Item { //separator @@ -77,6 +79,7 @@ ListView { height: 14 } + // -- description aka recepient name from address book (TODO) Text { id: descriptionText width: text.length ? (descriptionArea.containsMouse ? parent.width - x - 12 : 120) : 0 @@ -100,7 +103,7 @@ ListView { height: 14 visible: !descriptionArea.containsMouse } - + // -- address (in case outgoing transaction) - N/A in case of incoming Text { id: addressText anchors.verticalCenter: dot.verticalCenter @@ -109,11 +112,11 @@ ListView { font.family: "Arial" font.pixelSize: 14 color: "#545454" - text: address + text: hash visible: !descriptionArea.containsMouse } } - + // -- "PaymentID" title Text { id: paymentLabel anchors.left: parent.left @@ -128,7 +131,7 @@ ListView { color: "#535353" text: paymentId !== "" ? qsTr("Payment ID:") + translationManager.emptyString : "" } - + // -- "PaymentID" value Text { anchors.bottom: paymentLabel.bottom anchors.left: paymentLabel.right @@ -143,7 +146,7 @@ ListView { color: "#545454" text: paymentId } - + // -- "Date", "Balance" and "Amound" section Row { anchors.left: parent.left anchors.bottom: parent.bottom @@ -155,6 +158,7 @@ ListView { height: 14 } + // -- "Date" column Column { anchors.top: parent.top width: 215 @@ -189,10 +193,13 @@ ListView { } } } - + // -- "Balance" column + // XXX: we don't have a balance + /* Column { anchors.top: parent.top width: 148 + visible: false Text { anchors.left: parent.left @@ -210,7 +217,9 @@ ListView { text: balance } } + */ + // -- "Amount column Column { anchors.top: parent.top width: 148 @@ -230,8 +239,8 @@ ListView { anchors.bottomMargin: 3 font.family: "Arial" font.pixelSize: 16 - color: out ? "#FF4F41" : "#36B05B" - text: out ? "↓" : "↑" + color: isOut ? "#FF4F41" : "#36B05B" + text: isOut ? "↓" : "↑" } Text { @@ -239,22 +248,16 @@ ListView { font.family: "Arial" font.pixelSize: 18 font.letterSpacing: -1 - color: out ? "#FF4F41" : "#36B05B" + color: isOut ? "#FF4F41" : "#36B05B" text: amount } } } } - ListModel { - id: dropModel - ListElement { name: "<b>Copy address to clipboard</b>"; icon: "../images/dropdownCopy.png" } - ListElement { name: "<b>Add to address book</b>"; icon: "../images/dropdownAdd.png" } - ListElement { name: "<b>Send to same destination</b>"; icon: "../images/dropdownSend.png" } - ListElement { name: "<b>Find similar transactions</b>"; icon: "../images/dropdownSearch.png" } - } - Clipboard { id: clipboard } + + TableDropdown { id: dropdown anchors.right: parent.right @@ -283,4 +286,14 @@ ListView { color: "#DBDBDB" } } + + ListModel { + id: dropModel + ListElement { name: "<b>Copy address to clipboard</b>"; icon: "../images/dropdownCopy.png" } + ListElement { name: "<b>Add to address book</b>"; icon: "../images/dropdownAdd.png" } + ListElement { name: "<b>Send to same destination</b>"; icon: "../images/dropdownSend.png" } + ListElement { name: "<b>Find similar transactions</b>"; icon: "../images/dropdownSearch.png" } + } + + Clipboard { id: clipboard } } |
