diff --git a/application.qrc b/application.qrc
index 716471d..0332b5f 100644
--- a/application.qrc
+++ b/application.qrc
@@ -48,6 +48,8 @@
res/unknownBlack.png
res/unknownWhite.png
res/dark-01.png
+ res/money-mouth.png
+ res/money-outgoing.png
res/hushdlogo.gif
diff --git a/res/money-mouth.png b/res/money-mouth.png
new file mode 100644
index 0000000..fc262f4
Binary files /dev/null and b/res/money-mouth.png differ
diff --git a/res/money-outgoing.png b/res/money-outgoing.png
new file mode 100644
index 0000000..c40b09b
Binary files /dev/null and b/res/money-outgoing.png differ
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 27c1327..e2dabf3 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -618,6 +618,18 @@ void MainWindow::setAmt(QString amt)
_amt = amt;
}
+QString MainWindow::getMoneyMemo()
+{
+
+ return _moneymemo;
+}
+
+void MainWindow::setMoneyMemo(QString moneymemo)
+{
+
+ _moneymemo = moneymemo;
+}
+
void MainWindow::setupStatusBar() {
// Status Bar
loadingLabel = new QLabel();
@@ -1513,6 +1525,9 @@ void MainWindow::setupchatTab() {
QDialog transactionDialog(this);
transaction.setupUi(&transactionDialog);
Settings::saveRestore(&transactionDialog);
+ transaction.requestHush->setEnabled(false);
+ transaction.requestHush->setVisible(false);
+ transaction.amountChat->setValidator(this->getAmountValidator());
@@ -1529,12 +1544,16 @@ void MainWindow::setupchatTab() {
transaction.contactName->setUniformItemSizes(true);
transaction.contactName->setDragDropMode(QAbstractItemView::DropOnly);
transaction.contactName->show();
+
}
QObject::connect(transaction.sendHush, &QPushButton::clicked, [&] (){
+
QString amt = transaction.amountChat->text();
- this->setAmt(amt);
+ QString memo = transaction.MemoMoney->text();
+ this->setAmt(amt);
+ this->setMoneyMemo(memo);
transactionDialog.close();
});
@@ -1599,9 +1618,10 @@ Tx MainWindow::createTxFromSendChatPage() {
QString myAddr = c.getMyAddress();
QString type = "Money";
QString addr = c.getPartnerAddress();
+ QString moneymemo = this->getMoneyMemo();
/////////User input for chatmemos
- QString memoplain = QString("You have received/sent ") + amtStr + QString(" HUSH") ;
+ QString memoplain = QString("Money transaction of : ") + amtStr + QString(" HUSH") + QString("\n") + QString("\n") + moneymemo;
/////////We convert the user input from QString to unsigned char*, so we can encrypt it later
int lengthmemo = memoplain.length();
diff --git a/src/mainwindow.h b/src/mainwindow.h
index 2cdf9ce..3867de6 100644
--- a/src/mainwindow.h
+++ b/src/mainwindow.h
@@ -53,11 +53,13 @@ public:
QString doSendRequestTxValidations(Tx tx);
QString getCid();
QString getAmt();
+ QString getMoneyMemo();
QString getPassword();
std::map pubkeyMap;
QString getPubkeyByAddress(QString requestZaddr);
void setPassword(QString Password);
void setAmt(QString Amt);
+ void setMoneyMemo(QString MoneyMemo);
void addPubkey(QString requestZaddr, QString pubkey);
@@ -115,6 +117,7 @@ private:
void closeEventpw(QCloseEvent* event);
QString _password;
QString _amt;
+ QString _moneymemo;
void setupSendTab();
diff --git a/src/sendHushTransactionChat.ui b/src/sendHushTransactionChat.ui
index 1d403c6..64b1e1d 100644
--- a/src/sendHushTransactionChat.ui
+++ b/src/sendHushTransactionChat.ui
@@ -6,48 +6,22 @@
0
0
- 530
- 377
+ 216
+ 384
- Dialog
+ Send or Request Hush
-
-
-
-
- 16777215
- 20
-
-
-
- <html><head/><body><p align="center"><span style=" font-weight:600;">Send or Request some Hush</span></p></body></html>
-
-
-
- -
To :
- -
-
-
- Qt::Vertical
-
-
-
- 20
- 65
-
-
-
-
- -
+
-
QLayout::SetFixedSize
@@ -88,23 +62,31 @@
- -
-
-
- Qt::Vertical
+
-
+
+
+ QLayout::SetFixedSize
-
-
- 20
- 79
-
+
+ 6
+
+
+ 6
+
+
+ 6
+
+
+ 6
-
-
- -
-
-
+
+
+ 80
+ 16777215
+
+
Amount:
@@ -112,12 +94,21 @@
-
+
+
+ 80
+ 16777215
+
+
200
0
+
+ 9
+
Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter
@@ -126,9 +117,61 @@
+ -
+
+
+
+ 35
+ 16777215
+
+
+
+ Hush
+
+
+
- -
+
-
+
+
+ Memo :
+
+
+
+ -
+
+
+ Qt::Vertical
+
+
+
+ 20
+ 40
+
+
+
+
+ -
+
+
+
+ 0
+ 41
+
+
+
+
+ 16777215
+ 41
+
+
+
+ 100
+
+
+
+ -
Qt::Vertical
@@ -136,12 +179,12 @@
20
- 64
+ 39
- -
+
-
QLayout::SetFixedSize
@@ -180,7 +223,7 @@
- -
+
-
Qt::Horizontal
@@ -190,13 +233,6 @@
- -
-
-
- Hush
-
-
-