From 50e7c082cd1c3946f34350c1ab10e75cbb69aeff Mon Sep 17 00:00:00 2001 From: Sander van Grieken Date: Mon, 4 Apr 2022 12:04:32 +0200 Subject: [PATCH] request dialog improve, icons --- electrum/gui/icons/copy_bw.png | Bin 0 -> 880 bytes electrum/gui/icons/delete.png | Bin 0 -> 453 bytes electrum/gui/icons/share.png | Bin 0 -> 3325 bytes electrum/gui/qml/components/RequestDialog.qml | 233 +++++++++--------- 4 files changed, 119 insertions(+), 114 deletions(-) create mode 100644 electrum/gui/icons/copy_bw.png create mode 100644 electrum/gui/icons/delete.png create mode 100644 electrum/gui/icons/share.png diff --git a/electrum/gui/icons/copy_bw.png b/electrum/gui/icons/copy_bw.png new file mode 100644 index 0000000000000000000000000000000000000000..739edbecb2f70ec848b3291ca5f30e0d044b8b0a GIT binary patch literal 880 zcmeAS@N?(olHy`uVBq!ia0vp^&w%(c2OE%_dN+S5kYY>nc6VX;4}uH!E}sk(;Vkfo zEM{Qf76xHPhFNnYfP(BLp1!W^kJ)%Q#8`StRz6~2VEXIn;uunK>+M}bBUML+;}8Gm z>~%>oHgfSg!n>ofh^g-Z+qwh1CsN*UPLqC<=G6CqMS0?)E$hthe%`mCFJH!o z_M68V_dJ$Zpu3-kkwaKO4H+x=2&lpEg-J(Q=2y;qa^OPwTbq;ihYi*ne4i{M^=sW) zX(sPTkUEDM$hg74afU;urd*OdSO0HeYpE=2|C`J&n-|WGpRx4)-`(Ctk0*teMoBCy zH;+2iWWbonbciL9X=&B3T}Sr6c)i=})9wd5#GTFe8yr`aKYm<~w{fWs%q1IA_UWz6 zw>~*@<<+gvRj#iVdv<5P-c7Hf#JuviiLVTFQxDq0T@BF#ahXAQ+4L>Nb)KIxyu!B5 zOxb>XXIi{lt^vvq55alEF>^IR}DUI1jNPFo$ppCj#RRFXXTQ zu|eU1z>J9?Kf^E?7Ou!JJebbcdVH?R&CHZL^CsO1v)g~LBqwbh?`nx>5fyhn{`Tj7 zXU|z2^Jzywy^s2Sv1ywg$YG7%8LNSjwBPg7jh{PgYd=}<_P&)^e$qVVe2vkK*hf(j zr<$svF^h0L$R~~bIy{c0ORa^kO_Gt^x9Z!p8s65M8!pY|l=l25wQt?}g-dmI9EXM* zBD_Fh_oJ!(#_MX||L@ZxOaCwb$J|!<$*FcTRXisF(YC+Gw(YN}kD73QzW9>w&sksot#qt{a8thbi+_0l zvyUP~mYTbQw@t|CH z*Y@`bzfW!7Rler;DmIhSH7ngr>`PZ%UemT^Psx(go7lGYap=94x@PoY(c?{QX7k_u zU3#}{v()XZ|1b1kZ;ZeCLu~fppTFMtf7>&Uf41vhZLn`uUb0I3^z}I2cc}>EdQVqB Jmvv4FO#loM%#i>9 literal 0 HcmV?d00001 diff --git a/electrum/gui/icons/share.png b/electrum/gui/icons/share.png new file mode 100644 index 0000000000000000000000000000000000000000..d0dc761d4544fc091d2e59a22109fc60ffaa0a61 GIT binary patch literal 3325 zcmZu!cTm&Y68dJZqAM%fplM?oB zd7D9kBYmc+rVL#Fv+`O?QwbRg4|UU*06+!#$3Q?<4l5x^=B=TnLbggoN^uX2q&##5 z0P0u`WkmzO`Tg8LlQcul{&q)Jx9-c}l|937Nic=ZjRUdzOI8*Vt+4;ZdyhD zyc#(_Z)yKMB(s_GPWF6MS@?cxNv7r^#s+L6g#e&HI7NpwSQrgZ|4-P> zuw1R57wB?Y#|p`TtC8L1?s`ovn}f1;biIxnJ*Is!Ha;2K#Ga0I5mLMyrc(ZBv@I*q z6?|jrRwWIlnUm}H@x^o9>J_I=*`n+HJ=gBPsFqgzhJ!`(l0`rW3K%C>b)Qh4j+Wn* zvGE@y{qI-YrGC5vY)KGk2*vWsmSC{`3|l?PZO`?yudI(EDT=lDjmmt zE(=gN$ib-``qJhj0HUt?)wN8G!5dyKFJSEV5vUkLKuMHGHYT8%S`3HhqR5ShCm{*N zbd##X5__lNhr;4Jz7=3rurXN@EpJqUxE}|8Wm1vc2E3Jx4Z(l<8NH(OzBKg#%97|F z1U?#Z7XL8Iq${YJn z-e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9o$vOycUKcWDu9NHwsPfT>#% 0 - text: qsTr('Amount') - } - Label { - visible: modelItem.amount > 0 - text: Config.formatSats(modelItem.amount, false) - font.family: FixedFont - font.pixelSize: constants.fontSizeLarge - } - Label { - visible: modelItem.amount > 0 - Layout.fillWidth: true - text: Config.baseUnit - color: Material.accentColor - font.pixelSize: constants.fontSizeLarge - } + Rectangle { + height: 1 + Layout.fillWidth: true + Layout.columnSpan: 3 + color: Material.accentColor + } - Label { - text: qsTr('Address') - } - Label { - Layout.fillWidth: true - font.family: FixedFont - font.pixelSize: constants.fontSizeLarge - wrapMode: Text.WrapAnywhere - text: modelItem.address - } - ToolButton { - icon.source: '../../icons/copy.png' - icon.color: 'transparent' - onClicked: { - AppController.textToClipboard(modelItem.address) + RowLayout { + Layout.columnSpan: 3 + Layout.alignment: Qt.AlignHCenter + Button { + icon.source: '../../icons/delete.png' + text: qsTr('Delete') + onClicked: { + Daemon.currentWallet.delete_request(modelItem.key) + dialog.close() + } + } + Button { + icon.source: '../../icons/copy_bw.png' + icon.color: 'transparent' + text: 'Copy' + enabled: false + } + Button { + icon.source: '../../icons/share.png' + text: 'Share' + enabled: false + } + } + Label { + visible: modelItem.message != '' + text: qsTr('Description') + } + Label { + visible: modelItem.message != '' + Layout.columnSpan: 2 + Layout.fillWidth: true + wrapMode: Text.WordWrap + text: modelItem.message + font.pixelSize: constants.fontSizeLarge } - } - Label { - text: qsTr('Status') - } - Label { - Layout.columnSpan: 2 - Layout.fillWidth: true - font.pixelSize: constants.fontSizeLarge - text: modelItem.status - } + Label { + visible: modelItem.amount > 0 + text: qsTr('Amount') + } + Label { + visible: modelItem.amount > 0 + text: Config.formatSats(modelItem.amount, false) + font.family: FixedFont + font.pixelSize: constants.fontSizeLarge + } + Label { + visible: modelItem.amount > 0 + Layout.fillWidth: true + text: Config.baseUnit + color: Material.accentColor + font.pixelSize: constants.fontSizeLarge + } - RowLayout { - Layout.columnSpan: 3 - Layout.fillHeight: true - Layout.alignment: Qt.AlignHCenter - Button { - text: 'Delete' + Label { + text: qsTr('Address') + } + Label { + Layout.fillWidth: true + font.family: FixedFont + font.pixelSize: constants.fontSizeLarge + wrapMode: Text.WrapAnywhere + text: modelItem.address + } + ToolButton { + icon.source: '../../icons/copy_bw.png' onClicked: { - Daemon.currentWallet.delete_request(modelItem.key) - dialog.close() + AppController.textToClipboard(modelItem.address) } } - Button { - text: 'Copy' - enabled: false + + Label { + text: qsTr('Status') } - Button { - text: 'Share' - enabled: false + Label { + Layout.columnSpan: 2 + Layout.fillWidth: true + font.pixelSize: constants.fontSizeLarge + text: modelItem.status } + } }