Compare commits
1116 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b59de2fb0e | ||
|
|
09c0aac7ab | ||
|
|
72b71e6a4f | ||
|
|
7fa55b49fe | ||
|
|
ba8d2913be | ||
|
|
f17c407100 | ||
|
|
7a3855700e | ||
|
|
ca7c0e0c55 | ||
|
|
d6ef609236 | ||
|
|
3f3fd67f14 | ||
|
|
ad88e60394 | ||
|
|
f75086ca28 | ||
|
|
e7c73164a6 | ||
|
|
6ca3c1a23e | ||
|
|
f86bcc61c5 | ||
|
|
77f0e9b912 | ||
|
|
ead8dc27d0 | ||
|
|
ca29d7e1be | ||
|
|
e21f8903ee | ||
|
|
b4e0dd107c | ||
|
|
cae90e8287 | ||
|
|
bee64abe2e | ||
|
|
c3f84d6de4 | ||
|
|
b9f2e372d0 | ||
|
|
bdb1251cfa | ||
|
|
3e9df9d975 | ||
|
|
cf321fa8f3 | ||
|
|
da02e4df42 | ||
|
|
de8e80a9bd | ||
|
|
f0cd704fad | ||
|
|
cd87af1415 | ||
|
|
6693fc7449 | ||
|
|
c14df12ce6 | ||
|
|
271650cfbe | ||
|
|
d523b16c5b | ||
|
|
1455ca8cbf | ||
|
|
b859854fbf | ||
|
|
3cda2b663a | ||
|
|
8599aa4e32 | ||
|
|
a1410b444b | ||
|
|
34b06c1a0f | ||
|
|
e0cbf43947 | ||
|
|
4934f77c6f | ||
|
|
8d28d0f842 | ||
|
|
5671a450c8 | ||
|
|
61ce53f47e | ||
|
|
5cb02b9e01 | ||
|
|
703e499d52 | ||
|
|
361ff60f11 | ||
|
|
b68ac66237 | ||
|
|
928966188b | ||
|
|
65a8e5e4aa | ||
|
|
66d99324dd | ||
|
|
c09806d560 | ||
|
|
0fdd75be59 | ||
|
|
4359fe706e | ||
|
|
a636a04f0a | ||
|
|
0d3cb9f6e4 | ||
|
|
c8d3b55741 | ||
|
|
d80b0a39a8 | ||
|
|
b2c264ea59 | ||
|
|
2e5012f55b | ||
|
|
3f5d55d224 | ||
|
|
5a1ca8578b | ||
|
|
851571c7f6 | ||
|
|
6760d5edf9 | ||
|
|
80954c3979 | ||
|
|
64d0bd91ef | ||
|
|
1df05202e9 | ||
|
|
324cb8aa0d | ||
|
|
6400c885cc | ||
|
|
2ac690ce20 | ||
|
|
ab382dc604 | ||
|
|
ac0e9f7fb7 | ||
|
|
78a003c161 | ||
|
|
ed607e6e95 | ||
|
|
088b343d2f | ||
|
|
9d24649d61 | ||
|
|
24992f144e | ||
|
|
56c593fd67 | ||
|
|
af2af06165 | ||
|
|
4d56befb85 | ||
|
|
a6efacdd8f | ||
|
|
ea4728afde | ||
|
|
1109f9cec9 | ||
|
|
aa9b6df0c4 | ||
|
|
59a63e7725 | ||
|
|
af0f58f727 | ||
|
|
3bc4d6a10f | ||
|
|
3fd37b96a0 | ||
|
|
c46b5c82cd | ||
|
|
77a2ebc2c4 | ||
|
|
0c3f39ee0d | ||
|
|
b31c04e148 | ||
|
|
94e3d98452 | ||
|
|
ccb1f36083 | ||
|
|
b585e7b498 | ||
|
|
6f73948846 | ||
|
|
567bc07627 | ||
|
|
2aa37133fe | ||
|
|
fb1e39bbad | ||
|
|
134422cb65 | ||
|
|
d03c8959c8 | ||
|
|
9e50dfc3ce | ||
|
|
9bb6a25f31 | ||
|
|
4b5c985349 | ||
|
|
8115632db5 | ||
|
|
a04576d4c3 | ||
|
|
a1e7134433 | ||
|
|
241ebc9388 | ||
|
|
d53a335abc | ||
|
|
a60b05d40d | ||
|
|
c3f41ae003 | ||
|
|
3483b8dbec | ||
|
|
034f83bfb3 | ||
|
|
0a3d75d197 | ||
|
|
39f2b99c7b | ||
|
|
0fed21d6de | ||
|
|
a9fa808dd1 | ||
|
|
5e3a8958f3 | ||
|
|
d5e27ff07d | ||
|
|
8eee948f07 | ||
|
|
3d7090bdba | ||
|
|
eef3f8a3ac | ||
|
|
2671cd926c | ||
|
|
666203bd0e | ||
|
|
46ee2e9cc8 | ||
|
|
756ea882c9 | ||
|
|
d5b48aab07 | ||
|
|
eece475fb8 | ||
|
|
dda2390983 | ||
|
|
496332a878 | ||
|
|
b43a268873 | ||
|
|
f156acda72 | ||
|
|
8076e71109 | ||
|
|
51e0f442d6 | ||
|
|
e1e55807bc | ||
|
|
4cc30a8cd6 | ||
|
|
3c9b5b71df | ||
|
|
06bbda0c99 | ||
|
|
a9bea84086 | ||
|
|
fb8ba824f6 | ||
|
|
bacad3733d | ||
|
|
d2ee1845e1 | ||
|
|
5e4bc36fc3 | ||
|
|
f3891ffe04 | ||
|
|
2842c33759 | ||
|
|
045189553e | ||
|
|
0218312055 | ||
|
|
7d1bbeef10 | ||
|
|
9e9aa31df2 | ||
|
|
951be246b7 | ||
|
|
9872689abe | ||
|
|
6be5e5731e | ||
|
|
eb457019dd | ||
|
|
b7dbb83294 | ||
|
|
28bd9a72d2 | ||
|
|
9019fa8baa | ||
|
|
1257eb642a | ||
|
|
140b7634ff | ||
|
|
48da5a3dba | ||
|
|
58f1e3c8a9 | ||
|
|
da27e1c78b | ||
|
|
4f4d969416 | ||
|
|
15c5269e35 | ||
|
|
06899c937c | ||
|
|
1107daab98 | ||
|
|
292c11ee06 | ||
|
|
d554c7809d | ||
|
|
527b48278a | ||
|
|
9331f2cff1 | ||
|
|
2633419c8e | ||
|
|
5d0854491a | ||
|
|
1fe61f2bc7 | ||
|
|
fb32dda5a1 | ||
|
|
ceef6c8b6d | ||
|
|
c029dc8a5e | ||
|
|
b78d9d0c03 | ||
|
|
8161cf3acb | ||
|
|
b9fcd8f60b | ||
|
|
07a4dd26a5 | ||
|
|
ceda53d8d2 | ||
|
|
9662ef5a7c | ||
|
|
7a629a5b37 | ||
|
|
33c195d01d | ||
|
|
28069f7fb6 | ||
|
|
716366c54f | ||
|
|
030ff0994d | ||
|
|
0295641aeb | ||
|
|
0e4fa41c63 | ||
|
|
6e08eb1c56 | ||
|
|
855d95909a | ||
|
|
53c3151a23 | ||
|
|
c1dd25a77e | ||
|
|
f1f0109621 | ||
|
|
f258ae4b60 | ||
|
|
abccad8771 | ||
|
|
eb26b37b86 | ||
|
|
f7bbdd3044 | ||
|
|
b5253f03db | ||
|
|
ac8e88ee53 | ||
|
|
7116001f5c | ||
|
|
254553f90e | ||
|
|
cd46edb23f | ||
|
|
9d43cf3b44 | ||
|
|
08f61e25de | ||
|
|
acaf0f525d | ||
|
|
08c424cbc8 | ||
|
|
fa560ad0a0 | ||
|
|
ccec187ed6 | ||
|
|
ddb51583d3 | ||
|
|
fec309b907 | ||
|
|
e91552ab3c | ||
|
|
8efddfbb77 | ||
|
|
d89ff0fea1 | ||
|
|
ba39119aab | ||
|
|
834e617736 | ||
|
|
f63b098b61 | ||
|
|
35bf427159 | ||
|
|
a11eab5bb7 | ||
|
|
d06a16f7da | ||
|
|
122ed15e11 | ||
|
|
c691fc1915 | ||
|
|
82c9a02447 | ||
|
|
f4e58f1aad | ||
|
|
cc32479662 | ||
|
|
9272767e4e | ||
|
|
3102118e38 | ||
|
|
5b725a4f20 | ||
|
|
82d925a1d8 | ||
|
|
520a4f4260 | ||
|
|
5732245dac | ||
|
|
ee6bcdb7d0 | ||
|
|
2cb8f9fd2e | ||
|
|
9ca81e6413 | ||
|
|
56d6e38f85 | ||
|
|
562f711e64 | ||
|
|
ed64160716 | ||
|
|
ca0978e094 | ||
|
|
fdfd387e80 | ||
|
|
6df6ad636c | ||
|
|
275c3df302 | ||
|
|
f6beb48f5e | ||
|
|
427b161606 | ||
|
|
25426c5430 | ||
|
|
92240564bc | ||
|
|
3314dbd79f | ||
|
|
253944186b | ||
|
|
fa0e444db0 | ||
|
|
5ba724b7fa | ||
|
|
6e3f2f6777 | ||
|
|
da93fc4a86 | ||
|
|
fd03f083bd | ||
|
|
8c5b403b7c | ||
|
|
7dab8e509f | ||
|
|
290339a22d | ||
|
|
63478b1c48 | ||
|
|
7db6695768 | ||
|
|
a9fe150778 | ||
|
|
f37efc48a0 | ||
|
|
e551454fea | ||
|
|
bcbf50a5bf | ||
|
|
d003b255b9 | ||
|
|
06fdf27be2 | ||
|
|
78e0ae1a4e | ||
|
|
b6a7836447 | ||
|
|
4954491273 | ||
|
|
4c2640d4b3 | ||
|
|
adc1db585a | ||
|
|
f4ddb6faf9 | ||
|
|
da014b07a9 | ||
|
|
ecf4839f01 | ||
|
|
5730c4a29e | ||
|
|
fe811e2ec2 | ||
|
|
2bbd5c6814 | ||
|
|
4a8545c99f | ||
|
|
34b9a04af5 | ||
|
|
01dcfe01bb | ||
|
|
31ef55d838 | ||
|
|
bde1d472d3 | ||
|
|
6729ae7380 | ||
|
|
827c80d4d8 | ||
|
|
15155f2db8 | ||
|
|
7283fe41c2 | ||
|
|
c9daab71bf | ||
|
|
92582a9785 | ||
|
|
341ac18f1a | ||
|
|
adb47adf9b | ||
|
|
8ace0628a1 | ||
|
|
a7e99dc08a | ||
|
|
4f7a4a4f70 | ||
|
|
b56074bef1 | ||
|
|
ff3987ccab | ||
|
|
6de8e70004 | ||
|
|
d69176e936 | ||
|
|
70492cc169 | ||
|
|
26aabd2226 | ||
|
|
48b9aa450d | ||
|
|
bff27010f3 | ||
|
|
3e5f5f3245 | ||
|
|
bfbe00e11c | ||
|
|
178be387bb | ||
|
|
1541d87122 | ||
|
|
d6427a1efb | ||
|
|
229fba2de9 | ||
|
|
dc1d5e9e0a | ||
|
|
9018ae3afe | ||
|
|
5487383068 | ||
|
|
0e49e4ad37 | ||
|
|
6ff273fd32 | ||
|
|
cb94523747 | ||
|
|
44ad8a3be1 | ||
|
|
5a1952f7ac | ||
|
|
894b10eeb4 | ||
|
|
6147d81cc5 | ||
|
|
d8606ea917 | ||
|
|
7cea134352 | ||
|
|
08e5154535 | ||
|
|
aa74e9e026 | ||
|
|
3c45dcca7a | ||
|
|
1eaedb3e8e | ||
|
|
7418a10d28 | ||
|
|
fe53cddd03 | ||
|
|
ec640dcd1b | ||
|
|
2d697187ff | ||
|
|
c40944144a | ||
|
|
610682c2be | ||
|
|
199aedf60a | ||
|
|
170ddf1f6f | ||
|
|
b8466739f9 | ||
|
|
9f0d771f40 | ||
|
|
dbcd11563f | ||
|
|
19ac2aeb19 | ||
|
|
37bceb7897 | ||
|
|
679d18166f | ||
|
|
1deef73237 | ||
|
|
73d93c3c23 | ||
|
|
59a4afef3c | ||
|
|
75ccc7a31b | ||
|
|
7fe9d71eb3 | ||
|
|
4d56ed9e27 | ||
|
|
47f9a1765a | ||
|
|
acefb96520 | ||
|
|
7d8d477a19 | ||
|
|
74233bf459 | ||
|
|
1b07cdad1c | ||
|
|
ffeecb6234 | ||
|
|
400c385a5c | ||
|
|
e1359ace86 | ||
|
|
df3e5de3f1 | ||
|
|
1e8f8bf3cd | ||
|
|
3635b2f001 | ||
|
|
60cefb3820 | ||
|
|
d2f90be148 | ||
|
|
8532b240be | ||
|
|
1956f5896d | ||
|
|
366534a295 | ||
|
|
631560c95a | ||
|
|
eed500560d | ||
|
|
0988f54bd2 | ||
|
|
cfc6abcfdc | ||
|
|
5a5d92e6f6 | ||
|
|
d248e45563 | ||
|
|
dba28580e9 | ||
|
|
b75eedde0a | ||
|
|
2c73ca216e | ||
|
|
c13b4cb7bd | ||
|
|
d5b8ce4bec | ||
|
|
85aa323a2d | ||
|
|
b0f54f6d1d | ||
|
|
acb76b867e | ||
|
|
977d9873a7 | ||
|
|
ee328592e9 | ||
|
|
431feea267 | ||
|
|
4f62745207 | ||
|
|
05bb8beb71 | ||
|
|
ab42e7b23a | ||
|
|
b4a54eb047 | ||
|
|
5279971bd7 | ||
|
|
f86360faf4 | ||
|
|
57d8ec5e32 | ||
|
|
68898636a4 | ||
|
|
b38729fc0e | ||
|
|
544b872ada | ||
|
|
25e5b3528e | ||
|
|
72541b6d51 | ||
|
|
a7a954bb22 | ||
|
|
d72e9873d1 | ||
|
|
46dc634a5c | ||
|
|
9b8badc00c | ||
|
|
7251254d8f | ||
|
|
9c4425295b | ||
|
|
f04a9e07e1 | ||
|
|
66f29831e1 | ||
|
|
251db80609 | ||
|
|
791c26734f | ||
|
|
d074854aae | ||
|
|
28fb9fa2be | ||
|
|
67e9109c14 | ||
|
|
5109cb7b33 | ||
|
|
b4353a31ac | ||
|
|
a15f088e8b | ||
|
|
3034348ac8 | ||
|
|
4927d9c29e | ||
|
|
d71c35ab22 | ||
|
|
11e3380ab1 | ||
|
|
3d00c4ae30 | ||
|
|
8db58b42af | ||
|
|
8d5690c834 | ||
|
|
a8e545891c | ||
|
|
6ba65d4caa | ||
|
|
a9331a757f | ||
|
|
cd4418dc45 | ||
|
|
4a96678580 | ||
|
|
1378ae45c3 | ||
|
|
3b76636d6b | ||
|
|
6ca0713739 | ||
|
|
39ca338f96 | ||
|
|
0e92a8f723 | ||
|
|
6ef2a8e21d | ||
|
|
ffd49c1777 | ||
|
|
84fad36282 | ||
|
|
9393529613 | ||
|
|
76a105261e | ||
|
|
199ed44aae | ||
|
|
4e6a4213ff | ||
|
|
fbe5ba8317 | ||
|
|
12aa815c5a | ||
|
|
2a8d6f192a | ||
|
|
abe0ae9304 | ||
|
|
4fc34f6886 | ||
|
|
afd624d0c0 | ||
|
|
f06ee51f05 | ||
|
|
be0b04c54e | ||
|
|
ed358e6e16 | ||
|
|
9f58e29f1c | ||
|
|
f6fb6df48c | ||
|
|
86746a1563 | ||
|
|
47dc499413 | ||
|
|
a7594d64a2 | ||
|
|
a229f7006f | ||
|
|
34b6bcf504 | ||
|
|
0ef429fdac | ||
|
|
a090c724f8 | ||
|
|
4cfa813cd5 | ||
|
|
2bd8e2feda | ||
|
|
a272427423 | ||
|
|
e638ed0272 | ||
|
|
90818efe5e | ||
|
|
77648e71e9 | ||
|
|
959c2fcc32 | ||
|
|
79c946367f | ||
|
|
b32b308332 | ||
|
|
011e301324 | ||
|
|
fb6b467dcb | ||
|
|
d98221ac56 | ||
|
|
6e503cd0e2 | ||
|
|
408878290e | ||
|
|
d2d6e3ad66 | ||
|
|
0b7966f625 | ||
|
|
9afaa7cf0f | ||
|
|
b35d60db2d | ||
|
|
1d34d21a60 | ||
|
|
da2c6e8bc8 | ||
|
|
0bfff8844e | ||
|
|
3c24044736 | ||
|
|
3d4eb7a5f5 | ||
|
|
06bda869e0 | ||
|
|
c001e31241 | ||
|
|
3f9926487d | ||
|
|
84e6461248 | ||
|
|
60f64a30ad | ||
|
|
28608e4ce0 | ||
|
|
2d7ef434be | ||
|
|
7e8915966b | ||
|
|
625b92318f | ||
|
|
b38ee48e59 | ||
|
|
72a7fac467 | ||
|
|
916c7acbb7 | ||
|
|
6e794e3c50 | ||
|
|
7c0f704fbd | ||
|
|
f544d9ac78 | ||
|
|
8f368b9b3b | ||
|
|
5213daad77 | ||
|
|
57c0477fc6 | ||
|
|
70983136bc | ||
|
|
09935ba4b0 | ||
|
|
3ba4224b69 | ||
|
|
69b4d56fdd | ||
|
|
bbc16e36dd | ||
|
|
499419a23c | ||
|
|
30bf765b75 | ||
|
|
bb9e4ee0b9 | ||
|
|
57a9508849 | ||
|
|
4977049425 | ||
|
|
53b5b7a5c7 | ||
|
|
a128581ae5 | ||
|
|
6677a185f8 | ||
|
|
a9b6a70d15 | ||
|
|
cf2791a246 | ||
|
|
c28d2daf20 | ||
|
|
4f3bf839f7 | ||
|
|
129562594d | ||
|
|
676d976e53 | ||
|
|
e339034082 | ||
|
|
5a36aa7fce | ||
|
|
f262ce5209 | ||
|
|
be9cb8931c | ||
|
|
0477af1b0d | ||
|
|
0b9e89691d | ||
|
|
d654ec1647 | ||
|
|
a1cdb572e2 | ||
|
|
e5357c8a0b | ||
|
|
de3fd183d8 | ||
|
|
328eb32a24 | ||
|
|
f48cd1b82b | ||
|
|
948669edbc | ||
|
|
868fbe2f2d | ||
|
|
22792df5cd | ||
|
|
af9e4e86f0 | ||
|
|
5028491ab3 | ||
|
|
5cd38c5aa7 | ||
|
|
3d5fee0a2f | ||
|
|
8295b9dffd | ||
|
|
8c44c4c842 | ||
|
|
df21e36f5b | ||
|
|
d77e045f5d | ||
|
|
fb40d137f8 | ||
|
|
bfd2a63aca | ||
|
|
01f7b6cbfb | ||
|
|
3d65a5d90d | ||
|
|
b09dfc2511 | ||
|
|
02380fbf1a | ||
|
|
6d31c48522 | ||
|
|
901e77e6f1 | ||
|
|
a07fd46718 | ||
|
|
98479c4dc4 | ||
|
|
c3e1b51ac4 | ||
|
|
6d21b9919d | ||
|
|
36ac2ee86d | ||
|
|
63132dc1db | ||
|
|
82553b0df2 | ||
|
|
dc445edaae | ||
|
|
2e89f86b9f | ||
|
|
bb836dae38 | ||
|
|
8fbd8b99d7 | ||
|
|
9f0874ee06 | ||
|
|
e62fab767a | ||
|
|
f9e264ca0a | ||
|
|
2629c767a8 | ||
|
|
af7ad482c2 | ||
|
|
f6f26af7cb | ||
|
|
f15d6f5197 | ||
|
|
e7eb3bdfef | ||
|
|
5360d2c231 | ||
|
|
9462899e97 | ||
|
|
9819e63fcc | ||
|
|
50eafab5dc | ||
|
|
229bade38c | ||
|
|
5fdc9d894e | ||
|
|
ad68107e1b | ||
|
|
f14dc70663 | ||
|
|
b34432c6ac | ||
|
|
5be04964a3 | ||
|
|
9347e8d936 | ||
|
|
f6dc84a26a | ||
|
|
ed95c4f4bf | ||
|
|
4c432000cb | ||
|
|
f51cf35935 | ||
|
|
3b4d7ba93e | ||
|
|
8a3490a300 | ||
|
|
c64977a7db | ||
|
|
f362953afc | ||
|
|
2067cbec31 | ||
|
|
018ada3433 | ||
|
|
f49ad844b8 | ||
|
|
f68ca5d76e | ||
|
|
2556f24b8f | ||
|
|
d03f94da46 | ||
|
|
9943ceaf0e | ||
|
|
bf8b8f4512 | ||
|
|
71fe3e4ae4 | ||
|
|
d5e3835bbf | ||
|
|
e877d83023 | ||
|
|
00e34f7846 | ||
|
|
22a1114501 | ||
|
|
65ea07af61 | ||
|
|
fb33f35e45 | ||
|
|
fdaf557b99 | ||
|
|
33634d1ffe | ||
|
|
3934ba32ec | ||
|
|
e4d75c6680 | ||
|
|
278458bb64 | ||
|
|
def4434909 | ||
|
|
e39ea7119f | ||
|
|
9247609009 | ||
|
|
40f34ecc9e | ||
|
|
808743da94 | ||
|
|
ee6dd2ec56 | ||
|
|
c72ffb4212 | ||
|
|
b1a5ebacf3 | ||
|
|
da0155e260 | ||
|
|
d253991ecb | ||
|
|
37cb0061ee | ||
|
|
9038bb3803 | ||
|
|
0aa32694ef | ||
|
|
c8f0cf3543 | ||
|
|
f182a72d19 | ||
|
|
c5363da1e8 | ||
|
|
a8ba815fb3 | ||
|
|
587e6e8c24 | ||
|
|
f12d47386f | ||
|
|
8ba5e9a164 | ||
|
|
3c6625a506 | ||
|
|
0096765676 | ||
|
|
8241991e8a | ||
|
|
5f11583915 | ||
|
|
56f6c0a48b | ||
|
|
77cccf3836 | ||
|
|
84e345e655 | ||
|
|
92a62da383 | ||
|
|
39db876fee | ||
|
|
6ca78702f0 | ||
|
|
d13705749a | ||
|
|
5af989fa29 | ||
|
|
689123fa95 | ||
|
|
fd5e3dcecb | ||
|
|
d6e03df7de | ||
|
|
a0a60eba69 | ||
|
|
c0ffe5b96a | ||
|
|
d399528078 | ||
|
|
5d2d6adfaf | ||
|
|
7db2c0c9f7 | ||
|
|
87e8b09065 | ||
|
|
df2b8d3c8d | ||
|
|
ff46368783 | ||
|
|
18b36d5593 | ||
|
|
17c36025a0 | ||
|
|
ce8913b5bf | ||
|
|
7c9ba196c9 | ||
|
|
be986cf599 | ||
|
|
e6eef867dc | ||
|
|
4479026649 | ||
|
|
2deff0611d | ||
|
|
7dae6a1ff0 | ||
|
|
767a9b3042 | ||
|
|
94760e550e | ||
|
|
168a187f51 | ||
|
|
09455a7bd7 | ||
|
|
9b27a3de69 | ||
|
|
1983f1bee0 | ||
|
|
efab83fa46 | ||
|
|
ecbfaffae7 | ||
|
|
59e653b458 | ||
|
|
c85388815b | ||
|
|
10f8407a0d | ||
|
|
f45b0a7d25 | ||
|
|
22de9db4e1 | ||
|
|
986275c42c | ||
|
|
8b97eed79c | ||
|
|
a44d15a7e9 | ||
|
|
1f29558526 | ||
|
|
b49b8bffa1 | ||
|
|
d6395eab06 | ||
|
|
7d29ac861b | ||
|
|
70d42ee328 | ||
|
|
5e974f8845 | ||
|
|
cdb2d17a2e | ||
|
|
491c1d26bf | ||
|
|
86bd96e063 | ||
|
|
a5820bfd9a | ||
|
|
d07e415733 | ||
|
|
c096be427e | ||
|
|
ca00bf8b62 | ||
|
|
2e4b084ebf | ||
|
|
b1b8239722 | ||
|
|
9da4dc4899 | ||
|
|
014caff418 | ||
|
|
6399a4281f | ||
|
|
746f3adb6e | ||
|
|
f826c3fe65 | ||
|
|
7f6c4aa4c8 | ||
|
|
9cf2ba7b03 | ||
|
|
2b4402e0d4 | ||
|
|
5db9185409 | ||
|
|
bd173c9fc3 | ||
|
|
084c1c84f3 | ||
|
|
591a7c9662 | ||
|
|
76636ef992 | ||
|
|
45544c723f | ||
|
|
4bed8fab02 | ||
|
|
1cd4f0e8e3 | ||
|
|
7765205fe2 | ||
|
|
4360d9b67b | ||
|
|
a9753578d7 | ||
|
|
1f64326321 | ||
|
|
6fc8cfc827 | ||
|
|
cf14d744ee | ||
|
|
08beb71cca | ||
|
|
c1389a2f94 | ||
|
|
50fb2ddf69 | ||
|
|
fd1f4bf628 | ||
|
|
af882e87f5 | ||
|
|
89ec822ba5 | ||
|
|
5c664685da | ||
|
|
2061bc5212 | ||
|
|
5adc39915e | ||
|
|
2d47554741 | ||
|
|
1ad20a1fb3 | ||
|
|
53d2cd4ea7 | ||
|
|
b9757fe837 | ||
|
|
bed05a484c | ||
|
|
629f460eb6 | ||
|
|
ef6a6ed651 | ||
|
|
74b20236d6 | ||
|
|
4c9e2c1f1a | ||
|
|
b137f73440 | ||
|
|
84d3639991 | ||
|
|
c483c9c532 | ||
|
|
a6a7b56d73 | ||
|
|
cee0474e37 | ||
|
|
3b069ec049 | ||
|
|
d52486dfab | ||
|
|
fdd528b99e | ||
|
|
f378035836 | ||
|
|
7c1ecc0950 | ||
|
|
da2ea50616 | ||
|
|
ba8ddb23da | ||
|
|
bdb99725a0 | ||
|
|
4189900e86 | ||
|
|
fc131bd465 | ||
|
|
5268199679 | ||
|
|
cf488f4406 | ||
|
|
cec206ec8d | ||
|
|
b5c936c496 | ||
|
|
6c2fd8e431 | ||
|
|
13358cf0a3 | ||
|
|
533b1ea283 | ||
|
|
6ec32c5056 | ||
|
|
4f0e67a8be | ||
|
|
618d6cf3c0 | ||
|
|
ac509ed798 | ||
|
|
c6fd3ece1a | ||
|
|
e3663d054e | ||
|
|
9b1aac45fa | ||
|
|
d46000f77c | ||
|
|
c2a1a7bfb3 | ||
|
|
9c1d20737e | ||
|
|
3ad64eef66 | ||
|
|
860946c146 | ||
|
|
62b6a37483 | ||
|
|
c50eb93c3d | ||
|
|
33c4950757 | ||
|
|
30af56d392 | ||
|
|
dab4d5a8d7 | ||
|
|
0ece8a968e | ||
|
|
158d50e5fa | ||
|
|
83efc3893b | ||
|
|
c3208785cf | ||
|
|
addee255ff | ||
|
|
64ce0e62e2 | ||
|
|
48f7102e39 | ||
|
|
4982d23738 | ||
|
|
7f336b884b | ||
|
|
4ba2672d84 | ||
|
|
339da86683 | ||
|
|
93565d996c | ||
|
|
1d71429b74 | ||
|
|
d71c31e1bf | ||
|
|
f9447fa4a1 | ||
|
|
fbd508781e | ||
|
|
d253b1da9e | ||
|
|
1b5b78ab25 | ||
|
|
745b40acad | ||
|
|
b73bcdf4b9 | ||
|
|
b8e5230d7d | ||
|
|
c8dd6632a7 | ||
|
|
4617a09af9 | ||
|
|
bdffc7d12b | ||
|
|
da3216156d | ||
|
|
9d22b6ab4d | ||
|
|
4299c79828 | ||
|
|
c09041f7f0 | ||
|
|
7e801642c2 | ||
|
|
3b23446c31 | ||
|
|
850fc25b6d | ||
|
|
e3fde20f74 | ||
|
|
a77aed0ded | ||
|
|
fd2003e71f | ||
|
|
65a3474a80 | ||
|
|
c5d28ba9c0 | ||
|
|
4d2f5864c1 | ||
|
|
9cdfad3512 | ||
|
|
77bcdf9434 | ||
|
|
c1187241db | ||
|
|
a116427567 | ||
|
|
1f51d4b52d | ||
|
|
85434298d9 | ||
|
|
934f53817c | ||
|
|
7ba6eac43a | ||
|
|
c1ac91d926 | ||
|
|
eda9ea15c6 | ||
|
|
3757dc27f1 | ||
|
|
5cda1f5ac1 | ||
|
|
d9d2050f29 | ||
|
|
bbf9b4b258 | ||
|
|
21a9bfb5e4 | ||
|
|
d8f3a52378 | ||
|
|
aacf1814aa | ||
|
|
4f0fee1a18 | ||
|
|
ca71131463 | ||
|
|
2dfc8d6324 | ||
|
|
549034dfce | ||
|
|
1353a47447 | ||
|
|
8e1f1dbf05 | ||
|
|
2147803d45 | ||
|
|
d79fe0f457 | ||
|
|
da020fd0be | ||
|
|
8956a35aae | ||
|
|
aa432e5e44 | ||
|
|
ebfebe795a | ||
|
|
d5d59b5dc6 | ||
|
|
c349b5d248 | ||
|
|
1ada4f8826 | ||
|
|
476b727db1 | ||
|
|
11f3e6f8e7 | ||
|
|
c441697594 | ||
|
|
67ecb6a85d | ||
|
|
a01bb509ea | ||
|
|
6b0e6ed84b | ||
|
|
60f4dcc106 | ||
|
|
c58dfa913b | ||
|
|
ceeb9b667f | ||
|
|
3c67b9ee62 | ||
|
|
a8e19b8fb6 | ||
|
|
15ea9ec748 | ||
|
|
4775a5b74d | ||
|
|
bfafd7b279 | ||
|
|
09461397a8 | ||
|
|
2d357b6c12 | ||
|
|
a72a76d3e6 | ||
|
|
394b20ee36 | ||
|
|
2170f6a46d | ||
|
|
e6ada22611 | ||
|
|
4b871306e4 | ||
|
|
e324e160da | ||
|
|
44b72eaff2 | ||
|
|
b8f38f29ae | ||
|
|
3d21b1168f | ||
|
|
b9152286ec | ||
|
|
72d220462a | ||
|
|
58030c67c8 | ||
|
|
aded122465 | ||
|
|
d834fb419c | ||
|
|
c1c6d9ee6d | ||
|
|
aec65db8c3 | ||
|
|
1c7f529141 | ||
|
|
d437b98a12 | ||
|
|
027ed0e328 | ||
|
|
b82a17aa97 | ||
|
|
31675f4c16 | ||
|
|
30fde8d7fd | ||
|
|
e3eab0c667 | ||
|
|
e0e69b35bd | ||
|
|
f605793cfc | ||
|
|
b6f268d3a5 | ||
|
|
ab44064fcc | ||
|
|
4dc0d36b98 | ||
|
|
9e0db8f4ff | ||
|
|
66bb3fe7ac | ||
|
|
5e877c7939 | ||
|
|
806f496faf | ||
|
|
418e4816d4 | ||
|
|
a6606a3330 | ||
|
|
4e8c7d95ad | ||
|
|
01899f04f5 | ||
|
|
44079aab37 | ||
|
|
a57da2f0cd | ||
|
|
316ddf1c05 | ||
|
|
855f2068f2 | ||
|
|
603c1e7ee9 | ||
|
|
abd5f50713 | ||
|
|
085dfe114a | ||
|
|
0e6028aacf | ||
|
|
bcb7bcffdb | ||
|
|
b205acc51b | ||
|
|
a3088b1eeb | ||
|
|
bbcb780cfa | ||
|
|
91953f1a3a | ||
|
|
7af8383caf | ||
|
|
c72207c2e2 | ||
|
|
8553771f89 | ||
|
|
d78f9f5e70 | ||
|
|
77335b300a | ||
|
|
6f95f8a754 | ||
|
|
05844b0a29 | ||
|
|
1e4e8ae59a | ||
|
|
6f14fde89c | ||
|
|
d8ebafaec0 | ||
|
|
7340371cc9 | ||
|
|
cc17b75a54 | ||
|
|
8f73bac95c | ||
|
|
e4177bb365 | ||
|
|
80a058c954 | ||
|
|
ff1780aeaa | ||
|
|
f1b70d08c6 | ||
|
|
0ae04fde4b | ||
|
|
c64321ebe9 | ||
|
|
34e7eb4e6b | ||
|
|
b888396ab4 | ||
|
|
508546c7c8 | ||
|
|
794c146c49 | ||
|
|
80618c83fd | ||
|
|
0d991b3792 | ||
|
|
61e8ac5b95 | ||
|
|
aac7fc613a | ||
|
|
e0d99cb1bb | ||
|
|
188eb064f4 | ||
|
|
84d09c85de | ||
|
|
913ef54c22 | ||
|
|
b853380db6 | ||
|
|
ea49e84215 | ||
|
|
23d1d4a958 | ||
|
|
f52990c8e4 | ||
|
|
d69519f0aa | ||
|
|
605f81314a | ||
|
|
5dc180393f | ||
|
|
8ba9b0e7c7 | ||
|
|
8b94bd80c9 | ||
|
|
1f1d51d8e1 | ||
|
|
11df558f8e | ||
|
|
3c46d6d1bd | ||
|
|
c712444e17 | ||
|
|
4066cb22ea | ||
|
|
78e3cd4a63 | ||
|
|
7941f88e53 | ||
|
|
8750cc2c13 | ||
|
|
f932d7a245 | ||
|
|
6d0847c39f | ||
|
|
ba9a99a4c6 | ||
|
|
b1675ab1cd | ||
|
|
327cbd086f | ||
|
|
a681878344 | ||
|
|
9b835599b8 | ||
|
|
5767ad9cd5 | ||
|
|
4c75fe47f9 | ||
|
|
56868c06b5 | ||
|
|
3df70ff98c | ||
|
|
83ea363932 | ||
|
|
6d09555cd4 | ||
|
|
4d9d10013b | ||
|
|
ece743e22a | ||
|
|
86e9f3811b | ||
|
|
2bc86d1d9f | ||
|
|
fc576a8680 | ||
|
|
b8da85d0a4 | ||
|
|
3d0a571cc7 | ||
|
|
7c366ddf04 | ||
|
|
d0f3194574 | ||
|
|
98f768d2a6 | ||
|
|
77cd5a7a62 | ||
|
|
0d1b709def | ||
|
|
5f052964a9 | ||
|
|
39facceee6 | ||
|
|
c84abc7224 | ||
|
|
649f81954e | ||
|
|
1a156b8840 | ||
|
|
f7c883a6c3 | ||
|
|
31f318aaea | ||
|
|
94c92ba73c | ||
|
|
8480c70571 | ||
|
|
ee2b0fa713 | ||
|
|
9f4f2b582b | ||
|
|
d670f6d321 | ||
|
|
4ca5e82fca | ||
|
|
c29ccc13ae | ||
|
|
c04417d37b | ||
|
|
7521472325 | ||
|
|
73ba192a58 | ||
|
|
0fdc21e7fd | ||
|
|
ba0796b9ca | ||
|
|
1ce573afe2 | ||
|
|
234fd1bcda | ||
|
|
3adb29bc16 | ||
|
|
3f7e3ba3c4 | ||
|
|
a7f52db613 | ||
|
|
7f4fec7777 | ||
|
|
995a5e0046 | ||
|
|
13a65505a5 | ||
|
|
105336ba08 | ||
|
|
c39875de44 | ||
|
|
3e90c3d825 | ||
|
|
5339fbde8b | ||
|
|
47927e4822 | ||
|
|
c68c317776 | ||
|
|
b2cd48ceaf | ||
|
|
0eaebb01c4 | ||
|
|
c321147e36 | ||
|
|
27349d111d | ||
|
|
602a393d59 | ||
|
|
e9b6c510f4 | ||
|
|
5d78941712 | ||
|
|
fa27982650 | ||
|
|
f3eca6eadb | ||
|
|
009994b212 | ||
|
|
57a282c72a | ||
|
|
96808441cd | ||
|
|
6730b63018 | ||
|
|
7cc924d478 | ||
|
|
8a14e367d8 | ||
|
|
a0e38aafb2 | ||
|
|
4bac8fdb57 | ||
|
|
b41c981454 | ||
|
|
c65ee4e71c | ||
|
|
7d66cc5b25 | ||
|
|
e43b719b19 | ||
|
|
03af06718c | ||
|
|
b4ce56a994 | ||
|
|
92c0e00b12 | ||
|
|
e8bd548219 | ||
|
|
ed17399b74 | ||
|
|
04869f0aac | ||
|
|
16122d6e17 | ||
|
|
73895f5a7b | ||
|
|
535f1fc446 | ||
|
|
5d4f519a40 | ||
|
|
ff9d79da7a | ||
|
|
b8a4dab9b2 | ||
|
|
a492cb9f7e | ||
|
|
5043250a2a | ||
|
|
fe78f20c7c | ||
|
|
ecaa1a8e23 | ||
|
|
9e121fb676 | ||
|
|
62e1dc490f | ||
|
|
9037eed805 | ||
|
|
443eb47824 | ||
|
|
13753052bc | ||
|
|
08b54f69a5 | ||
|
|
037fa32c41 | ||
|
|
8e986b3a2d | ||
|
|
0cb6900295 | ||
|
|
affbb454fa | ||
|
|
a6f13f7ba2 | ||
|
|
8e14b8bc3e | ||
|
|
5cd05a51d4 | ||
|
|
c2c5f0c13d | ||
|
|
f11d2bc702 | ||
|
|
77448a6b73 | ||
|
|
50b9281865 | ||
|
|
a3e0589a5e | ||
|
|
41b2c282bd | ||
|
|
127790e4a1 | ||
|
|
9dc8879e2c | ||
|
|
72a7f1348f | ||
|
|
cfa2f816a5 | ||
|
|
de4ff2992e | ||
|
|
6beadba9cc | ||
|
|
6a0ed3ceae | ||
|
|
a046163477 | ||
|
|
5ec575b376 | ||
|
|
009362451d | ||
|
|
f6e7b79e81 | ||
|
|
d744d393f9 | ||
|
|
25852b4676 | ||
|
|
336726e82f | ||
|
|
afac71383b | ||
|
|
2ac9e8eabb | ||
|
|
fff5c716c8 | ||
|
|
2e53c524a1 | ||
|
|
da6aad33a4 | ||
|
|
f5450f9205 | ||
|
|
1f23df7e66 | ||
|
|
27e37f153f | ||
|
|
58f24efd39 | ||
|
|
24bd3010bf | ||
|
|
87ea145047 | ||
|
|
310df0befa | ||
|
|
a4a44d7c99 | ||
|
|
f00a181843 | ||
|
|
98b040670c | ||
|
|
f31b27d3fd | ||
|
|
8cd6f3f5b6 | ||
|
|
af1edc0c95 | ||
|
|
45106e5150 | ||
|
|
3a51c4b963 | ||
|
|
8da7c972db | ||
|
|
1c1d15821e | ||
|
|
ef4c2927b4 | ||
|
|
dd7732ce0c | ||
|
|
c750ca9507 | ||
|
|
feabe6713c | ||
|
|
a550c03a0b | ||
|
|
1336055e80 | ||
|
|
115102624e | ||
|
|
5a0adb18d3 | ||
|
|
a055293b52 | ||
|
|
a00c083ece | ||
|
|
22a769341a | ||
|
|
91757b8039 | ||
|
|
74da45766e | ||
|
|
949d85288d | ||
|
|
798b273888 | ||
|
|
e2bfe25b9d | ||
|
|
7f12d4869e | ||
|
|
b2f7058fcf | ||
|
|
06e01e3771 | ||
|
|
cbc9dd07c8 | ||
|
|
6633d309b5 | ||
|
|
1e7fbe5cb0 | ||
|
|
05084422a5 | ||
|
|
57ab7daa03 | ||
|
|
fc0a44cabc | ||
|
|
30e403fe58 | ||
|
|
5297b23248 | ||
|
|
96c8df23a4 | ||
|
|
06b12d167b |
8
.gitignore
vendored
@@ -3,3 +3,11 @@
|
||||
translations/*.qm
|
||||
build
|
||||
version.js
|
||||
# IOS stuff below
|
||||
moc_*
|
||||
*.o
|
||||
*.mak
|
||||
*.build
|
||||
*.xcodeproj
|
||||
monero-wallet-gui_plugin_import.cpp
|
||||
monero-wallet-gui_qml_plugin_import.cpp
|
||||
|
||||
2
.gitmodules
vendored
@@ -1,4 +1,4 @@
|
||||
[submodule "monero"]
|
||||
path = monero
|
||||
url = https://github.com/monero-project/monero
|
||||
ignore = dirty
|
||||
ignore = all
|
||||
|
||||
177
BasicPanel.qml
@@ -1,177 +0,0 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtGraphicalEffects 1.0
|
||||
import "components"
|
||||
import "pages"
|
||||
|
||||
// mbg033 @ 2016-10-08: Not used anymore, to be deleted
|
||||
|
||||
Rectangle {
|
||||
id: root
|
||||
width: 470
|
||||
// height: paymentId.y + paymentId.height + 12
|
||||
height: header.height + header.anchors.topMargin + transferBasic.height
|
||||
color: "#F0EEEE"
|
||||
|
||||
border.width: 1
|
||||
border.color: "#DBDBDB"
|
||||
|
||||
property alias balanceText : balanceText.text;
|
||||
property alias unlockedBalanceText : availableBalanceText.text;
|
||||
// repeating signal to the outside world
|
||||
signal paymentClicked(string address, string paymentId, string amount, int mixinCount,
|
||||
int priority, string description)
|
||||
|
||||
Connections {
|
||||
target: transferBasic
|
||||
onPaymentClicked: {
|
||||
console.log("BasicPanel: paymentClicked")
|
||||
root.paymentClicked(address, paymentId, amount, mixinCount, priority, description)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Rectangle {
|
||||
id: header
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.leftMargin: 1
|
||||
anchors.rightMargin: 1
|
||||
anchors.topMargin: 30
|
||||
height: 64
|
||||
color: "#FFFFFF"
|
||||
|
||||
Image {
|
||||
id: logo
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.verticalCenterOffset: -5
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 20
|
||||
source: "images/moneroLogo2.png"
|
||||
}
|
||||
|
||||
Grid {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
width: 256
|
||||
columns: 3
|
||||
|
||||
Text {
|
||||
|
||||
width: 116
|
||||
height: 20
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#535353"
|
||||
text: qsTr("Locked Balance:")
|
||||
}
|
||||
|
||||
Text {
|
||||
id: balanceText
|
||||
width: 110
|
||||
height: 20
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#000000"
|
||||
text: qsTr("78.9239845")
|
||||
}
|
||||
|
||||
Item {
|
||||
height: 20
|
||||
width: 20
|
||||
|
||||
Image {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
source: "images/lockIcon.png"
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
width: 116
|
||||
height: 20
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#535353"
|
||||
text: qsTr("Available Balance:")
|
||||
}
|
||||
|
||||
Text {
|
||||
id: availableBalanceText
|
||||
width: 110
|
||||
height: 20
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 14
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#000000"
|
||||
text: qsTr("2324.9239845")
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
}
|
||||
Item {
|
||||
anchors.top: header.bottom
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
Transfer {
|
||||
id : transferBasic
|
||||
anchors.fill: parent
|
||||
}
|
||||
}
|
||||
|
||||
// indicate disabled state
|
||||
// Desaturate {
|
||||
// anchors.fill: parent
|
||||
// source: parent
|
||||
// desaturation: root.enabled ? 0.0 : 1.0
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
2
LICENSE
@@ -1,4 +1,4 @@
|
||||
Copyright (c) 2014-2015, The Monero Project
|
||||
Copyright (c) 2014-2018, The Monero Project
|
||||
|
||||
All rights reserved.
|
||||
|
||||
|
||||
408
LeftPanel.qml
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -27,29 +27,37 @@
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtGraphicalEffects 1.0
|
||||
import moneroComponents.Wallet 1.0
|
||||
import moneroComponents.NetworkType 1.0
|
||||
import "components"
|
||||
|
||||
Rectangle {
|
||||
id: panel
|
||||
|
||||
property alias unlockedBalanceText: unlockedBalanceText.text
|
||||
property alias unlockedBalanceVisible: unlockedBalanceText.visible
|
||||
property alias unlockedBalanceLabelVisible: unlockedBalanceLabel.visible
|
||||
property alias balanceLabelText: balanceLabel.text
|
||||
property alias balanceText: balanceText.text
|
||||
property alias networkStatus : networkStatus
|
||||
property alias progressBar : progressBar
|
||||
property alias daemonProgressBar : daemonProgressBar
|
||||
property alias minutesToUnlockTxt: unlockedBalanceLabel.text
|
||||
property int titleBarHeight: 50
|
||||
|
||||
signal dashboardClicked()
|
||||
signal historyClicked()
|
||||
signal transferClicked()
|
||||
signal receiveClicked()
|
||||
signal txkeyClicked()
|
||||
signal sharedringdbClicked()
|
||||
signal settingsClicked()
|
||||
signal addressBookClicked()
|
||||
signal miningClicked()
|
||||
signal signClicked()
|
||||
signal keysClicked()
|
||||
|
||||
function selectItem(pos) {
|
||||
menuColumn.previousButton.checked = false
|
||||
@@ -60,171 +68,205 @@ Rectangle {
|
||||
else if(pos === "AddressBook") menuColumn.previousButton = addressBookButton
|
||||
else if(pos === "Mining") menuColumn.previousButton = miningButton
|
||||
else if(pos === "TxKey") menuColumn.previousButton = txkeyButton
|
||||
else if(pos === "SharedRingDB") menuColumn.previousButton = sharedringdbButton
|
||||
else if(pos === "Sign") menuColumn.previousButton = signButton
|
||||
else if(pos === "Settings") menuColumn.previousButton = settingsButton
|
||||
else if(pos === "Advanced") menuColumn.previousButton = advancedButton
|
||||
else if(pos === "Keys") menuColumn.previousButton = keysButton
|
||||
|
||||
menuColumn.previousButton.checked = true
|
||||
}
|
||||
|
||||
width: 260
|
||||
color: "#FFFFFF"
|
||||
width: (isMobile)? appWindow.width : 300
|
||||
color: "transparent"
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.top: parent.top
|
||||
|
||||
// Item with monero logo
|
||||
Item {
|
||||
id: logoItem
|
||||
Image {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: (persistentSettings.customDecorations)? 66 : 36
|
||||
height: logo.implicitHeight
|
||||
|
||||
Image {
|
||||
id: logo
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 50
|
||||
source: "images/moneroLogo.png"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: testnetLabel
|
||||
visible: persistentSettings.testnet
|
||||
text: qsTr("Testnet") + translationManager.emptyString
|
||||
anchors.top: logo.bottom
|
||||
anchors.topMargin: 5
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 50
|
||||
font.bold: true
|
||||
color: "red"
|
||||
}
|
||||
|
||||
/* Disable twitter/news panel
|
||||
Image {
|
||||
anchors.left: parent.left
|
||||
anchors.verticalCenter: logo.verticalCenter
|
||||
anchors.leftMargin: 19
|
||||
source: appWindow.rightPanelExpanded ? "images/expandRightPanel.png" :
|
||||
"images/collapseRightPanel.png"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: appWindow.rightPanelExpanded = !appWindow.rightPanelExpanded
|
||||
}
|
||||
*/
|
||||
height: panel.height
|
||||
source: "images/leftPanelBg.jpg"
|
||||
z: 1
|
||||
}
|
||||
|
||||
|
||||
// card with monero logo
|
||||
Column {
|
||||
visible: true
|
||||
z: 2
|
||||
id: column1
|
||||
height: 200
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: logoItem.bottom
|
||||
anchors.topMargin: 26
|
||||
spacing: 5
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: (persistentSettings.customDecorations)? 50 : 0
|
||||
|
||||
Label {
|
||||
id: balanceLabel
|
||||
text: qsTr("Balance") + translationManager.emptyString
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 50
|
||||
tipText: qsTr("Test tip 1<br/><br/>line 2") + translationManager.emptyString
|
||||
}
|
||||
|
||||
Row {
|
||||
RowLayout {
|
||||
visible: true
|
||||
Item {
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 20
|
||||
anchors.leftMargin: 20
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
height: 26
|
||||
width: 50
|
||||
height: 490 * scaleRatio
|
||||
width: 259 * scaleRatio
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: "images/lockIcon.png"
|
||||
width: 259; height: 170
|
||||
fillMode: Image.PreserveAspectFit
|
||||
source: "images/card-background.png"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: testnetLabel
|
||||
visible: persistentSettings.nettype != NetworkType.MAINNET
|
||||
text: (persistentSettings.nettype == NetworkType.TESTNET ? qsTr("Testnet") : qsTr("Stagenet")) + translationManager.emptyString
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 8
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 192
|
||||
font.bold: true
|
||||
font.pixelSize: 12
|
||||
color: "#f33434"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: viewOnlyLabel
|
||||
visible: viewOnly
|
||||
text: qsTr("View Only") + translationManager.emptyString
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 8
|
||||
anchors.right: testnetLabel.visible ? testnetLabel.left : parent.right
|
||||
anchors.rightMargin: 8
|
||||
font.pixelSize: 12
|
||||
font.bold: true
|
||||
color: "#ff9323"
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
id: balanceText
|
||||
Item {
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 20
|
||||
anchors.leftMargin: 20
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
font.family: "Arial"
|
||||
color: "#000000"
|
||||
text: "N/A"
|
||||
// dynamically adjust text size
|
||||
font.pixelSize: {
|
||||
var digits = text.split('.')[0].length
|
||||
var defaultSize = 25;
|
||||
if(digits > 2) {
|
||||
return defaultSize - 1.1*digits
|
||||
height: 490 * scaleRatio
|
||||
width: 50 * scaleRatio
|
||||
|
||||
Text {
|
||||
visible: !isMobile
|
||||
id: balanceText
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 20
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 76
|
||||
font.family: "Arial"
|
||||
color: "#FFFFFF"
|
||||
text: "N/A"
|
||||
// dynamically adjust text size
|
||||
font.pixelSize: {
|
||||
var digits = text.split('.')[0].length
|
||||
var defaultSize = 22;
|
||||
if(digits > 2) {
|
||||
return defaultSize - 1.1*digits
|
||||
}
|
||||
return defaultSize;
|
||||
}
|
||||
return defaultSize;
|
||||
}
|
||||
|
||||
Text {
|
||||
id: unlockedBalanceText
|
||||
visible: true
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 20
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 126
|
||||
font.family: "Arial"
|
||||
color: "#FFFFFF"
|
||||
text: "N/A"
|
||||
// dynamically adjust text size
|
||||
font.pixelSize: {
|
||||
var digits = text.split('.')[0].length
|
||||
var defaultSize = 20;
|
||||
if(digits > 3) {
|
||||
return defaultSize - 0.6*digits
|
||||
}
|
||||
return defaultSize;
|
||||
}
|
||||
}
|
||||
|
||||
Label {
|
||||
id: unlockedBalanceLabel
|
||||
visible: true
|
||||
text: qsTr("Unlocked balance") + translationManager.emptyString
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 20
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 110
|
||||
}
|
||||
|
||||
Label {
|
||||
visible: !isMobile
|
||||
id: balanceLabel
|
||||
text: qsTr("Balance") + translationManager.emptyString
|
||||
fontSize: 14
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 20
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 60
|
||||
}
|
||||
Item { //separator
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: 1
|
||||
}
|
||||
/* Disable twitter/news panel
|
||||
Image {
|
||||
anchors.left: parent.left
|
||||
anchors.verticalCenter: logo.verticalCenter
|
||||
anchors.leftMargin: 19
|
||||
source: appWindow.rightPanelExpanded ? "images/expandRightPanel.png" :
|
||||
"images/collapseRightPanel.png"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: appWindow.rightPanelExpanded = !appWindow.rightPanelExpanded
|
||||
}
|
||||
*/
|
||||
}
|
||||
}
|
||||
|
||||
Item { //separator
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: 1
|
||||
}
|
||||
|
||||
Label {
|
||||
id: unlockedBalanceLabel
|
||||
text: qsTr("Unlocked balance") + translationManager.emptyString
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 50
|
||||
tipText: qsTr("Test tip 2<br/><br/>line 2") + translationManager.emptyString
|
||||
}
|
||||
|
||||
Text {
|
||||
id: unlockedBalanceText
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 50
|
||||
font.family: "Arial"
|
||||
color: "#000000"
|
||||
text: "N/A"
|
||||
// dynamically adjust text size
|
||||
font.pixelSize: {
|
||||
var digits = text.split('.')[0].length
|
||||
var defaultSize = 18;
|
||||
if(digits > 3) {
|
||||
return defaultSize - 0.6*digits
|
||||
}
|
||||
return defaultSize;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
anchors.bottom: menuRect.top
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: menuRect
|
||||
z: 2
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.top: column1.bottom
|
||||
anchors.topMargin: 25
|
||||
color: "#1C1C1C"
|
||||
anchors.top: (isMobile)? parent.top : column1.bottom
|
||||
anchors.topMargin: (isMobile)? 0 : 32
|
||||
color: "transparent"
|
||||
|
||||
|
||||
Flickable {
|
||||
id:flicker
|
||||
contentHeight: (progressBar.visible)? menuColumn.height + separator.height +
|
||||
networkStatus.height + progressBar.height + daemonProgressBar.height :
|
||||
menuColumn.height + separator.height + networkStatus.height
|
||||
anchors.fill: parent
|
||||
clip: true
|
||||
|
||||
|
||||
Column {
|
||||
|
||||
id: menuColumn
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
|
||||
clip: true
|
||||
property var previousButton: transferButton
|
||||
|
||||
// ------------- Dashboard tab ---------------
|
||||
@@ -250,11 +292,19 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: dashboardButton.checked || transferButton.checked ? "#1C1C1C" : "#505050"
|
||||
color: dashboardButton.checked || transferButton.checked ? "#1C1C1C" : "#313131"
|
||||
height: 1
|
||||
}
|
||||
*/
|
||||
|
||||
// top border
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
|
||||
// ------------- Transfer tab ---------------
|
||||
MenuButton {
|
||||
@@ -276,7 +326,7 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#505050"
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
|
||||
@@ -302,7 +352,7 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#505050"
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
|
||||
@@ -325,7 +375,7 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#505050"
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
|
||||
@@ -349,7 +399,7 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#505050"
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
|
||||
@@ -371,13 +421,14 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#505050"
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
|
||||
// ------------- Mining tab ---------------
|
||||
MenuButton {
|
||||
id: miningButton
|
||||
visible: !isAndroid && !isIOS
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
text: qsTr("Mining") + translationManager.emptyString
|
||||
@@ -396,7 +447,7 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: miningButton.checked || settingsButton.checked ? "#1C1C1C" : "#505050"
|
||||
color: miningButton.checked || settingsButton.checked ? "#1C1C1C" : "#313131"
|
||||
height: 1
|
||||
}
|
||||
// ------------- TxKey tab ---------------
|
||||
@@ -404,7 +455,7 @@ Rectangle {
|
||||
id: txkeyButton
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
text: qsTr("Check payment") + translationManager.emptyString
|
||||
text: qsTr("Prove/check") + translationManager.emptyString
|
||||
symbol: qsTr("K") + translationManager.emptyString
|
||||
dotColor: "#FFD781"
|
||||
under: advancedButton
|
||||
@@ -419,9 +470,33 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#505050"
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
// ------------- Shared RingDB tab ---------------
|
||||
MenuButton {
|
||||
id: sharedringdbButton
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
text: qsTr("Shared RingDB") + translationManager.emptyString
|
||||
symbol: qsTr("G") + translationManager.emptyString
|
||||
dotColor: "#FFD781"
|
||||
under: advancedButton
|
||||
onClicked: {
|
||||
parent.previousButton.checked = false
|
||||
parent.previousButton = sharedringdbButton
|
||||
panel.sharedringdbClicked()
|
||||
}
|
||||
}
|
||||
Rectangle {
|
||||
visible: sharedringdbButton.present
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
|
||||
|
||||
// ------------- Sign/verify tab ---------------
|
||||
MenuButton {
|
||||
@@ -443,7 +518,7 @@ Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#505050"
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
// ------------- Settings tab ---------------
|
||||
@@ -460,24 +535,87 @@ Rectangle {
|
||||
panel.settingsClicked()
|
||||
}
|
||||
}
|
||||
Rectangle {
|
||||
visible: settingsButton.present
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
// ------------- Sign/verify tab ---------------
|
||||
MenuButton {
|
||||
id: keysButton
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
text: qsTr("Seed & Keys") + translationManager.emptyString
|
||||
symbol: qsTr("Y") + translationManager.emptyString
|
||||
dotColor: "#FFD781"
|
||||
under: settingsButton
|
||||
onClicked: {
|
||||
parent.previousButton.checked = false
|
||||
parent.previousButton = keysButton
|
||||
panel.keysClicked()
|
||||
}
|
||||
}
|
||||
Rectangle {
|
||||
visible: settingsButton.present
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 16
|
||||
color: "#313131"
|
||||
height: 1
|
||||
}
|
||||
|
||||
} // Column
|
||||
|
||||
} // Flickable
|
||||
|
||||
Rectangle {
|
||||
id: separator
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 0
|
||||
anchors.rightMargin: 0
|
||||
anchors.bottom: networkStatus.top;
|
||||
height: 10 * scaleRatio
|
||||
color: "transparent"
|
||||
}
|
||||
|
||||
NetworkStatusItem {
|
||||
id: networkStatus
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 0
|
||||
anchors.rightMargin: 0
|
||||
anchors.bottom: (progressBar.visible)? progressBar.top : parent.bottom;
|
||||
connected: Wallet.ConnectionStatus_Disconnected
|
||||
height: 48 * scaleRatio
|
||||
}
|
||||
|
||||
ProgressBar {
|
||||
id: progressBar
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.bottom: daemonProgressBar.top
|
||||
height: 48 * scaleRatio
|
||||
syncType: qsTr("Wallet")
|
||||
visible: networkStatus.connected
|
||||
}
|
||||
}
|
||||
|
||||
ProgressBar {
|
||||
id: daemonProgressBar
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
syncType: qsTr("Daemon")
|
||||
visible: networkStatus.connected
|
||||
height: 62 * scaleRatio
|
||||
}
|
||||
} // menuRect
|
||||
|
||||
|
||||
|
||||
// indicate disabled state
|
||||
// Desaturate {
|
||||
// anchors.fill: parent
|
||||
|
||||
49
Logger.cpp
Normal file
@@ -0,0 +1,49 @@
|
||||
#include <QCoreApplication>
|
||||
#include <QStandardPaths>
|
||||
#include <QFileInfo>
|
||||
#include <QString>
|
||||
|
||||
#include "Logger.h"
|
||||
#include "wallet/api/wallet2_api.h"
|
||||
|
||||
// default log path by OS (should be writable)
|
||||
static const QString default_name = "monero-wallet-gui.log";
|
||||
#if defined(Q_OS_ANDROID) || defined(Q_OS_IOS)
|
||||
static const QString osPath = QStandardPaths::standardLocations(QStandardPaths::AppDataLocation).at(0);
|
||||
#elif defined(Q_OS_WIN)
|
||||
static const QString osPath = QCoreApplication::applicationDirPath();
|
||||
#elif defined(Q_OS_MAC)
|
||||
static const QString osPath = QStandardPaths::standardLocations(QStandardPaths::HomeLocation).at(0) + "/Library/Logs";
|
||||
#else // linux + bsd
|
||||
static const QString osPath = QStandardPaths::standardLocations(QStandardPaths::HomeLocation).at(0);
|
||||
#endif
|
||||
|
||||
|
||||
// return the absolute path of the logfile
|
||||
const QString getLogPath(const QString logPath)
|
||||
{
|
||||
const QFileInfo fi(logPath);
|
||||
|
||||
if(!logPath.isEmpty() && !fi.isDir())
|
||||
return fi.absoluteFilePath();
|
||||
else
|
||||
return osPath + "/" + default_name;
|
||||
}
|
||||
|
||||
|
||||
// custom messageHandler that foward all messages to easylogging
|
||||
void messageHandler(QtMsgType type, const QMessageLogContext &context, const QString &message)
|
||||
{
|
||||
(void) context; // context isn't used in release builds
|
||||
const std::string cat = "frontend"; // category displayed in the log
|
||||
const std::string msg = message.toStdString();
|
||||
switch(type)
|
||||
{
|
||||
case QtDebugMsg: Monero::Wallet::debug(cat, msg); break;
|
||||
case QtInfoMsg: Monero::Wallet::info(cat, msg); break;
|
||||
case QtWarningMsg: Monero::Wallet::warning(cat, msg); break;
|
||||
case QtCriticalMsg: Monero::Wallet::error(cat, msg); break;
|
||||
case QtFatalMsg: Monero::Wallet::error(cat, msg); break;
|
||||
}
|
||||
}
|
||||
|
||||
8
Logger.h
Normal file
@@ -0,0 +1,8 @@
|
||||
#ifndef LOGGER_H
|
||||
#define LOGGER_H
|
||||
|
||||
const QString getLogPath(const QString logPath);
|
||||
void messageHandler(QtMsgType type, const QMessageLogContext &context, const QString &message);
|
||||
|
||||
#endif // LOGGER_H
|
||||
|
||||
254
MiddlePanel.qml
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -29,40 +29,56 @@
|
||||
|
||||
import QtQml 2.0
|
||||
import QtQuick 2.2
|
||||
// QtQuick.Controls 2.0 isn't stable enough yet. Needs more testing.
|
||||
//import QtQuick.Controls 2.0
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtGraphicalEffects 1.0
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
||||
import "./pages"
|
||||
import "./pages/settings"
|
||||
|
||||
Rectangle {
|
||||
id: root
|
||||
|
||||
property Item currentView
|
||||
property Item previousView
|
||||
property bool basicMode : false
|
||||
property bool basicMode : isMobile
|
||||
property string balanceLabelText: qsTr("Balance") + translationManager.emptyString
|
||||
property string balanceText
|
||||
property string unlockedBalanceLabelText: qsTr("Unlocked Balance") + translationManager.emptyString
|
||||
property string unlockedBalanceText
|
||||
property int minHeight: (appWindow.height > 800) ? appWindow.height : 800 * scaleRatio
|
||||
property alias contentHeight: mainFlickable.contentHeight
|
||||
property alias flickable: mainFlickable
|
||||
// property int headerHeight: header.height
|
||||
|
||||
property Transfer transferView: Transfer { }
|
||||
property Receive receiveView: Receive { }
|
||||
property TxKey txkeyView: TxKey { }
|
||||
property SharedRingDB sharedringdbView: SharedRingDB { }
|
||||
property History historyView: History { }
|
||||
property Sign signView: Sign { }
|
||||
property Settings settingsView: Settings { }
|
||||
property Mining miningView: Mining { }
|
||||
property AddressBook addressBookView: AddressBook { }
|
||||
property Keys keysView: Keys { }
|
||||
|
||||
|
||||
signal paymentClicked(string address, string paymentId, string amount, int mixinCount, int priority, string description)
|
||||
signal sweepUnmixableClicked()
|
||||
signal generatePaymentIdInvoked()
|
||||
signal checkPaymentClicked(string address, string txid, string txkey);
|
||||
signal getProofClicked(string txid, string address, string message);
|
||||
signal checkProofClicked(string txid, string address, string message, string signature);
|
||||
|
||||
color: "#F0EEEE"
|
||||
Image {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
source: "../images/middlePanelBg.jpg"
|
||||
}
|
||||
|
||||
onCurrentViewChanged: {
|
||||
if (previousView) {
|
||||
@@ -73,7 +89,6 @@ Rectangle {
|
||||
previousView = currentView
|
||||
if (currentView) {
|
||||
stackView.replace(currentView)
|
||||
|
||||
// Component.onCompleted is called before wallet is initilized
|
||||
if (typeof currentView.onPageCompleted === "function") {
|
||||
currentView.onPageCompleted();
|
||||
@@ -91,33 +106,6 @@ Rectangle {
|
||||
transferView.sendTo(address, paymentId, description);
|
||||
}
|
||||
|
||||
|
||||
// XXX: just for memo, to be removed
|
||||
// states: [
|
||||
// State {
|
||||
// name: "Dashboard"
|
||||
// PropertyChanges { target: loader; source: "pages/Dashboard.qml" }
|
||||
// }, State {
|
||||
// name: "History"
|
||||
// PropertyChanges { target: loader; source: "pages/History.qml" }
|
||||
// }, State {
|
||||
// name: "Transfer"
|
||||
// PropertyChanges { target: loader; source: "pages/Transfer.qml" }
|
||||
// }, State {
|
||||
// name: "Receive"
|
||||
// PropertyChanges { target: loader; source: "pages/Receive.qml" }
|
||||
// }, State {
|
||||
// name: "AddressBook"
|
||||
// PropertyChanges { target: loader; source: "pages/AddressBook.qml" }
|
||||
// }, State {
|
||||
// name: "Settings"
|
||||
// PropertyChanges { target: loader; source: "pages/Settings.qml" }
|
||||
// }, State {
|
||||
// name: "Mining"
|
||||
// PropertyChanges { target: loader; source: "pages/Mining.qml" }
|
||||
// }
|
||||
// ]
|
||||
|
||||
states: [
|
||||
State {
|
||||
name: "Dashboard"
|
||||
@@ -126,27 +114,43 @@ Rectangle {
|
||||
name: "History"
|
||||
PropertyChanges { target: root; currentView: historyView }
|
||||
PropertyChanges { target: historyView; model: appWindow.currentWallet ? appWindow.currentWallet.historyModel : null }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: historyView.tableHeight + 220 * scaleRatio }
|
||||
}, State {
|
||||
name: "Transfer"
|
||||
PropertyChanges { target: root; currentView: transferView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: 1000 * scaleRatio }
|
||||
}, State {
|
||||
name: "Receive"
|
||||
PropertyChanges { target: root; currentView: receiveView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: receiveView.receiveHeight + 100 }
|
||||
}, State {
|
||||
name: "TxKey"
|
||||
PropertyChanges { target: root; currentView: txkeyView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: 1200 * scaleRatio }
|
||||
}, State {
|
||||
name: "SharedRingDB"
|
||||
PropertyChanges { target: root; currentView: sharedringdbView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: sharedringdbView.panelHeight + 100 }
|
||||
}, State {
|
||||
name: "AddressBook"
|
||||
PropertyChanges { target: root; currentView: addressBookView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: minHeight }
|
||||
}, State {
|
||||
name: "Sign"
|
||||
PropertyChanges { target: root; currentView: signView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: 1200 * scaleRatio }
|
||||
}, State {
|
||||
name: "Settings"
|
||||
PropertyChanges { target: root; currentView: settingsView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: settingsView.settingsHeight }
|
||||
}, State {
|
||||
name: "Mining"
|
||||
PropertyChanges { target: root; currentView: miningView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: minHeight }
|
||||
}, State {
|
||||
name: "Keys"
|
||||
PropertyChanges { target: root; currentView: keysView }
|
||||
PropertyChanges { target: mainFlickable; contentHeight: minHeight + 200 * scaleRatio }
|
||||
}
|
||||
]
|
||||
|
||||
@@ -168,165 +172,63 @@ Rectangle {
|
||||
|
||||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
anchors.margins: 2
|
||||
anchors.topMargin: appWindow.persistentSettings.customDecorations ? 30 : 0
|
||||
anchors.margins: 18
|
||||
anchors.topMargin: appWindow.persistentSettings.customDecorations ? 50 : 0
|
||||
spacing: 0
|
||||
|
||||
|
||||
// BasicPanel header
|
||||
Rectangle {
|
||||
id: header
|
||||
anchors.leftMargin: 1
|
||||
anchors.rightMargin: 1
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: 64
|
||||
color: "#FFFFFF"
|
||||
visible: basicMode
|
||||
|
||||
Image {
|
||||
id: logo
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.verticalCenterOffset: -5
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: appWindow.persistentSettings.customDecorations ? 20 : 40
|
||||
source: "images/moneroLogo2.png"
|
||||
}
|
||||
|
||||
Grid {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
anchors.topMargin: 10
|
||||
width: 256
|
||||
columns: 3
|
||||
|
||||
Text {
|
||||
id: balanceLabel
|
||||
width: 116
|
||||
height: 20
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#535353"
|
||||
text: root.balanceLabelText + ":"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: balanceText
|
||||
width: 110
|
||||
height: 20
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#000000"
|
||||
text: root.balanceText
|
||||
}
|
||||
|
||||
Item {
|
||||
height: 20
|
||||
width: 20
|
||||
|
||||
Image {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
source: "images/lockIcon.png"
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
id: availableBalanceLabel
|
||||
width: 116
|
||||
height: 20
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#535353"
|
||||
text: root.unlockedBalanceLabelText + ":"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: availableBalanceText
|
||||
width: 110
|
||||
height: 20
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 14
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#000000"
|
||||
text: root.unlockedBalanceText
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
}
|
||||
|
||||
// Views container
|
||||
StackView {
|
||||
id: stackView
|
||||
initialItem: transferView
|
||||
anchors.topMargin: 30
|
||||
Flickable {
|
||||
id: mainFlickable
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
anchors.margins: 4
|
||||
clip: true // otherwise animation will affect left panel
|
||||
clip: true
|
||||
|
||||
delegate: StackViewDelegate {
|
||||
pushTransition: StackViewTransition {
|
||||
PropertyAnimation {
|
||||
target: enterItem
|
||||
property: "x"
|
||||
from: 0 - target.width
|
||||
to: 0
|
||||
duration: 300
|
||||
}
|
||||
PropertyAnimation {
|
||||
target: exitItem
|
||||
property: "x"
|
||||
from: 0
|
||||
to: target.width
|
||||
duration: 300
|
||||
onFlickingChanged: {
|
||||
releaseFocus();
|
||||
}
|
||||
|
||||
// Disabled scrollbars, gives crash on startup on windows
|
||||
// ScrollIndicator.vertical: ScrollIndicator { }
|
||||
// ScrollBar.vertical: ScrollBar { } // uncomment to test
|
||||
|
||||
// Views container
|
||||
StackView {
|
||||
id: stackView
|
||||
initialItem: transferView
|
||||
anchors.fill:parent
|
||||
clip: true // otherwise animation will affect left panel
|
||||
|
||||
delegate: StackViewDelegate {
|
||||
pushTransition: StackViewTransition {
|
||||
PropertyAnimation {
|
||||
target: enterItem
|
||||
property: "x"
|
||||
from: 0 - target.width
|
||||
to: 0
|
||||
duration: 300
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
PropertyAnimation {
|
||||
target: exitItem
|
||||
property: "x"
|
||||
from: 0
|
||||
to: target.width
|
||||
duration: 300
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}// flickable
|
||||
}
|
||||
|
||||
// border
|
||||
Rectangle {
|
||||
anchors.top: styledRow.bottom
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.top: styledRow.bottom
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.left: parent.left
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
|
||||
color: "#313131"
|
||||
}
|
||||
|
||||
/* connect "payment" click */
|
||||
|
||||
182
README.md
@@ -1,15 +1,20 @@
|
||||
# Monero GUI
|
||||
|
||||
Copyright (c) 2014-2017, The Monero Project
|
||||
Copyright (c) 2014-2018, The Monero Project
|
||||
|
||||
## Development Resources
|
||||
## Development resources
|
||||
|
||||
- Web: [getmonero.org](https://getmonero.org)
|
||||
- Forum: [forum.getmonero.org](https://forum.getmonero.org)
|
||||
- Mail: [dev@getmonero.org](mailto:dev@getmonero.org)
|
||||
- Github: [https://github.com/monero-project/monero-core](https://github.com/monero-project/monero-core)
|
||||
- Github: [https://github.com/monero-project/monero-gui](https://github.com/monero-project/monero-gui)
|
||||
- IRC: [#monero-dev on Freenode](irc://chat.freenode.net/#monero-dev)
|
||||
|
||||
## Vulnerability response
|
||||
|
||||
- Our [Vulnerability Response Process](https://github.com/monero-project/meta/blob/master/VULNERABILITY_RESPONSE_PROCESS.md) encourages responsible disclosure
|
||||
- We are also available via [HackerOne](https://hackerone.com/monero)
|
||||
|
||||
## Introduction
|
||||
|
||||
Monero is a private, secure, untraceable, decentralised digital currency. You are your bank, you control your funds, and nobody can trace your transfers unless you allow them to do so.
|
||||
@@ -20,23 +25,21 @@ Monero is a private, secure, untraceable, decentralised digital currency. You ar
|
||||
|
||||
**Untraceability:** By taking advantage of ring signatures, a special property of a certain type of cryptography, Monero is able to ensure that transactions are not only untraceable, but have an optional measure of ambiguity that ensures that transactions cannot easily be tied back to an individual user or computer.
|
||||
|
||||
## About this Project
|
||||
## About this project
|
||||
|
||||
This is the GUI for the [core Monero implementation](https://github.com/monero-project/monero). It is open source and completely free to use without restrictions, except for those specified in the license agreement below. There are no restrictions on anyone creating an alternative implementation of Monero that uses the protocol and network in a compatible manner.
|
||||
|
||||
As with many development projects, the repository on Github is considered to be the "staging" area for the latest changes. Before changes are merged into that branch on the main repository, they are tested by individual developers in their own branches, submitted as a pull request, and then subsequently tested by contributors who focus on testing and code reviews. That having been said, the repository should be carefully considered before using it in a production environment, unless there is a patch in the repository for a particular show-stopping issue you are experiencing. It is generally a better idea to use a tagged release for stability.
|
||||
|
||||
## Supporting the Project
|
||||
## Supporting the project
|
||||
|
||||
Monero development can be supported directly through donations.
|
||||
|
||||
Both Monero and Bitcoin donations can be made to donate.getmonero.org if using a client that supports the [OpenAlias](https://openalias.org) standard
|
||||
Monero is a 100% community-sponsored endeavor. If you want to join our efforts, the easiest thing you can do is support the project financially. Both Monero and Bitcoin donations can be made to **donate.getmonero.org** if using a client that supports the [OpenAlias](https://openalias.org) standard.
|
||||
|
||||
The Monero donation address is: `44AFFq5kSiGBoZ4NMDwYtN18obc8AemS33DBLWs3H7otXft3XjrpDtQGv7SqSsaBYBb98uNbr2VBBEt7f2wfn3RVGQBEP3A` (viewkey: `f359631075708155cc3d92a32b75a7d02a5dcf27756707b47a2b31b21c389501`)
|
||||
|
||||
The Bitcoin donation address is: `1KTexdemPdxSBcG55heUuTjDRYqbC5ZL8H`
|
||||
|
||||
Core development funding and/or some supporting services are also graciously provided by sponsors:
|
||||
GUI development funding and/or some supporting services are also graciously provided by sponsors:
|
||||
|
||||
[<img width="80" src="https://static.getmonero.org/images/sponsors/mymonero.png"/>](https://mymonero.com)
|
||||
[<img width="150" src="https://static.getmonero.org/images/sponsors/kitware.png?1"/>](http://kitware.com)
|
||||
@@ -52,67 +55,76 @@ There are also several mining pools that kindly donate a portion of their fees,
|
||||
|
||||
See [LICENSE](LICENSE).
|
||||
|
||||
## Installing Monero Core from a Package
|
||||
## Installing the Monero GUI from a package
|
||||
|
||||
Packages are available for
|
||||
|
||||
* Arch Linux via AUR: [monero-core-git](https://aur.archlinux.org/packages/monero-core-git/)
|
||||
* Arch Linux via AUR: [monero-wallet-qt](https://aur.archlinux.org/packages/monero-wallet-qt/)
|
||||
* Void Linux: xbps-install -S monero-core
|
||||
* GuixSD: guix package -i monero-core
|
||||
|
||||
Packaging for your favorite distribution would be a welcome contribution!
|
||||
|
||||
## Compiling Monero Core from Source
|
||||
## Compiling the Monero GUI from source
|
||||
|
||||
### On Linux:
|
||||
|
||||
(Tested on Ubuntu 16.04 x86, 16.10 x64 and Linux Mint 18 "Sarah" - Cinnamon x64)
|
||||
(Tested on Ubuntu 17.10 x64, Ubuntu 18.04 x64 and Gentoo x64)
|
||||
|
||||
1. Install Monero dependencies.
|
||||
1. Install Monero dependencies
|
||||
|
||||
`sudo apt install build-essential cmake libboost-all-dev miniupnpc libunbound-dev graphviz doxygen libunwind8-dev pkg-config libssl-dev`
|
||||
- For Debian distributions (Debian, Ubuntu, Mint, Tails...)
|
||||
|
||||
2. Grab an up-to-date copy of the monero-core repository.
|
||||
`sudo apt install build-essential cmake libboost-all-dev miniupnpc libunbound-dev graphviz doxygen libunwind8-dev pkg-config libssl-dev libzmq3-dev libsodium-dev`
|
||||
|
||||
`git clone https://github.com/monero-project/monero-core.git`
|
||||
- For Gentoo
|
||||
|
||||
3. Go into the repository.
|
||||
`sudo emerge app-arch/xz-utils app-doc/doxygen dev-cpp/gtest dev-libs/boost dev-libs/expat dev-libs/openssl dev-util/cmake media-gfx/graphviz net-dns/unbound net-libs/ldns net-libs/miniupnpc net-libs/zeromq sys-libs/libunwind dev-libs/libsodium`
|
||||
|
||||
`cd monero-core`
|
||||
2. Install Qt:
|
||||
|
||||
4. Use the script to compile the Monero libs necessary to run the GUI.
|
||||
*Note*: Qt 5.7 is the minimum version required to build the GUI. This makes **some** distributions (mostly based on debian, like Ubuntu 16.x or Linux Mint 18.x) obsolete. You can still build the GUI if you install an [official Qt release](https://wiki.qt.io/Install_Qt_5_on_Ubuntu), but this is not officially supported.
|
||||
|
||||
`./get_libwallet_api.sh`
|
||||
- For Ubuntu 17.10+
|
||||
|
||||
`sudo apt install qtbase5-dev qt5-default qtdeclarative5-dev qml-module-qtquick-controls qml-module-qtquick-controls2 qml-module-qtquick-dialogs qml-module-qtquick-xmllistmodel qml-module-qt-labs-settings qml-module-qt-labs-folderlistmodel qttools5-dev-tools`
|
||||
|
||||
5. Install the GUI dependencies.
|
||||
- For Gentoo
|
||||
|
||||
- For Ubuntu 16.04 x86
|
||||
|
||||
`sudo apt-get install qtbase5-dev qt5-default qtdeclarative5-dev qml-module-qtquick-controls qml-module-qtquick-xmllistmodel qttools5-dev-tools qml-module-qtquick-dialogs`
|
||||
|
||||
- For Ubuntu 16.04+ x64
|
||||
|
||||
`sudo apt-get install qtbase5-dev qt5-default qtdeclarative5-dev qml-module-qtquick-controls qml-module-qtquick-xmllistmodel qttools5-dev-tools qml-module-qtquick-dialogs qml-module-qt-labs-settings libqt5qml-graphicaleffects`
|
||||
|
||||
- For Linux Mint 18 "Sarah" - Cinnamon x64
|
||||
|
||||
`sudo apt install qml-module-qt-labs-settings qml-module-qtgraphicaleffects`
|
||||
`sudo emerge dev-qt/qtcore:5 dev-qt/qtdeclarative:5 dev-qt/qtquickcontrols:5 dev-qt/qtquickcontrols2:5 dev-qt/qtgraphicaleffects:5`
|
||||
|
||||
- Optional : To build the flag `WITH_SCANNER`
|
||||
|
||||
`sudo apt install qtmultimedia5-dev qml-module-qtmultimedia libzbar-dev`
|
||||
- For Ubuntu
|
||||
|
||||
6. Build the GUI.
|
||||
`sudo apt install qtmultimedia5-dev qml-module-qtmultimedia libzbar-dev`
|
||||
|
||||
`./build.sh`
|
||||
- For Gentoo
|
||||
|
||||
7. Run the GUI client.
|
||||
The *qml* USE flag must be enabled.
|
||||
|
||||
`./build/release/bin/monero-wallet-gui`
|
||||
`emerge dev-qt/qtmultimedia:5 media-gfx/zbar`
|
||||
|
||||
|
||||
3. Clone repository
|
||||
|
||||
`git clone https://github.com/monero-project/monero-gui.git`
|
||||
|
||||
4. Build
|
||||
|
||||
```
|
||||
cd monero-gui
|
||||
QT_SELECT=5 ./build.sh
|
||||
```
|
||||
|
||||
The executable can be found in the build/release/bin folder.
|
||||
|
||||
### On OS X:
|
||||
|
||||
1. Install Xcode from AppStore
|
||||
|
||||
2. Install [homebrew](http://brew.sh/)
|
||||
|
||||
3. Install [monero](https://github.com/monero-project/monero) dependencies:
|
||||
|
||||
`brew install boost --c++11`
|
||||
@@ -123,36 +135,33 @@ Packaging for your favorite distribution would be a welcome contribution!
|
||||
|
||||
`brew install cmake`
|
||||
|
||||
`brew install zeromq`
|
||||
|
||||
*Note*: If cmake can not find zmq.hpp file on OS X, installing `zmq.hpp` from https://github.com/zeromq/cppzmq to `/usr/local/include` should fix that error.
|
||||
|
||||
4. Install Qt:
|
||||
|
||||
`brew install qt5` (or download QT 5.8+ from [qt.io](https://www.qt.io/download-open-source/))
|
||||
|
||||
If you have an older version of Qt installed via homebrew, you can force it to use 5.x like so:
|
||||
|
||||
`brew link --force --overwrite qt5`
|
||||
|
||||
4. Install latest Qt using official installer from [qt.io](https://www.qt.io/download-open-source/) (homebrew version might be outdated).
|
||||
5. Add Qt bin dir to your path (check first if directory exists; 5.8 is the current version)
|
||||
5. Add the Qt bin directory to your path
|
||||
|
||||
`export PATH=$PATH:$HOME/Qt/5.8/clang_64/bin`
|
||||
Example: `export PATH=$PATH:$HOME/Qt/5.8/clang_64/bin`
|
||||
|
||||
5. Add Qt bin dir to your path. Example:
|
||||
This is the directory where Qt 5.x is installed on **your** system
|
||||
|
||||
`export PATH=$PATH:/usr/local/opt/qt5/bin`
|
||||
6. Grab an up-to-date copy of the monero-gui repository
|
||||
|
||||
make sure this is where Qt 5.x is installed on **your** system eg `$HOME/Qt/5.8/clang_64/bin` if you downloaded from qt.io.
|
||||
`git clone https://github.com/monero-project/monero-gui.git`
|
||||
|
||||
6. Grab an up-to-date copy of the monero-core repository.
|
||||
7. Go into the repository
|
||||
|
||||
`git clone https://github.com/monero-project/monero-core.git`
|
||||
`cd monero-gui`
|
||||
|
||||
7. Go into the repository.
|
||||
|
||||
`cd monero-core`
|
||||
|
||||
8. Build libwallet
|
||||
|
||||
`./get_libwallet_api.sh`
|
||||
|
||||
9. Start the build:
|
||||
8. Start the build
|
||||
|
||||
`./build.sh`
|
||||
|
||||
@@ -160,7 +169,7 @@ The executable can be found in the `build/release/bin` folder.
|
||||
|
||||
**Note:** Workaround for "ERROR: Xcode not set up properly"
|
||||
|
||||
Edit `$HOME/Qt/5.7/clang_64/mkspecs/features/mac/default_pre.prf`
|
||||
Edit `$HOME/Qt/5.8/clang_64/mkspecs/features/mac/default_pre.prf`
|
||||
|
||||
replace
|
||||
`isEmpty($$list($$system("/usr/bin/xcrun -find xcrun 2>/dev/null")))`
|
||||
@@ -173,56 +182,47 @@ More info: http://stackoverflow.com/a/35098040/1683164
|
||||
|
||||
### On Windows:
|
||||
|
||||
1. Install [msys2](http://msys2.github.io/), follow the instructions on that page on how to update packages to the latest versions
|
||||
The Monero GUI on Windows is 64 bits only; 32-bit Windows GUI builds are not officially supported anymore.
|
||||
|
||||
2. Install monero dependencies as described in [monero documentation](https://github.com/monero-project/monero) into msys2 environment.
|
||||
**As we only build application for x86, install only dependencies for x86 architecture (i686 in package name)**
|
||||
```
|
||||
pacman -S mingw-w64-i686-toolchain make mingw-w64-i686-cmake mingw-w64-i686-boost
|
||||
1. Install [MSYS2](https://www.msys2.org/), follow the instructions on that page on how to update system and packages to the latest versions
|
||||
|
||||
```
|
||||
2. Open an 64-bit MSYS2 shell: Use the *MSYS2 MinGW 64-bit* shortcut, or use the `msys2_shell.cmd` batch file with a `-mingw64` parameter
|
||||
|
||||
3. Install git into msys2 environment:
|
||||
3. Install MSYS2 packages for Monero dependencies; the needed 64-bit packages have `x86_64` in their names
|
||||
|
||||
```
|
||||
pacman -S mingw-w64-x86_64-toolchain make mingw-w64-x86_64-cmake mingw-w64-x86_64-boost mingw-w64-x86_64-openssl mingw-w64-x86_64-zeromq mingw-w64-x86_64-libsodium mingw-w64-x86_64-hidapi
|
||||
```
|
||||
|
||||
You find more details about those dependencies in the [Monero documentation](https://github.com/monero-project/monero). Note that that there is no more need to compile Boost from source; like everything else, you can install it now with a MSYS2 package.
|
||||
|
||||
4. Install Qt5
|
||||
|
||||
```
|
||||
pacman -S mingw-w64-x86_64-qt5
|
||||
```
|
||||
|
||||
There is no more need to download some special installer from the Qt website, the standard MSYS2 package for Qt will do in almost all circumstances.
|
||||
|
||||
5. Install git
|
||||
|
||||
```
|
||||
pacman -S git
|
||||
```
|
||||
|
||||
4. Install Qt5 from [official site](https://www.qt.io/download-open-source/).
|
||||
- download unified installer, run and select following options:
|
||||
- Qt > Qt 5.7 > MinGW 5.3.0 32 bit
|
||||
- Tools > MinGW 5.3.0
|
||||
- continue with installation
|
||||
6. Clone repository
|
||||
|
||||
5. Open ```MinGW-w64 Win32 Shell``` shell:
|
||||
|
||||
```%MSYS_ROOT%\msys2_shell.cmd -mingw32```
|
||||
|
||||
Where ```%MSYS_ROOT%``` will be ```c:\msys32``` if your host OS is x86-based or ```c:\msys64``` if your host OS
|
||||
is x64-based
|
||||
|
||||
6. Install the latest version of boost, specificly the required static libraries:
|
||||
```
|
||||
cd
|
||||
wget http://sourceforge.net/projects/boost/files/boost/1.63.0/boost_1_63_0.tar.bz2
|
||||
tar xjf boost_1_63_0.tar.bz2
|
||||
cd boost_1_63_0
|
||||
./bootstrap.sh mingw
|
||||
./b2 --prefix=/mingw32/boost --layout=tagged --without-mpi --without-python toolset=gcc address-model=32 variant=debug,release link=static threading=multi runtime-link=static -j$(nproc) install
|
||||
git clone https://github.com/monero-project/monero-gui.git
|
||||
```
|
||||
|
||||
7. Clone repository:
|
||||
```
|
||||
cd
|
||||
git clone https://github.com/monero-project/monero-core.git
|
||||
```
|
||||
7. Build
|
||||
|
||||
8. Build the GUI:
|
||||
```
|
||||
cd monero-core
|
||||
export PATH=$(ls -rd /c/Qt/5.[6,7,8]/mingw53_32/bin | head -1):$PATH
|
||||
cd monero-gui
|
||||
./build.sh
|
||||
cd build
|
||||
make deploy
|
||||
```
|
||||
The resulting executable can be found in ```.\release\bin```
|
||||
|
||||
The executable can be found in the `.\release\bin` directory.
|
||||
|
||||
119
RightPanel.qml
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -38,121 +38,4 @@ Rectangle {
|
||||
id: root
|
||||
width: 330
|
||||
color: "#FFFFFF"
|
||||
|
||||
function updateTweets() {
|
||||
tabView.twitter.item.updateTweets()
|
||||
}
|
||||
|
||||
|
||||
TabView {
|
||||
id: tabView
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: styledRow.top
|
||||
anchors.leftMargin: 14
|
||||
anchors.rightMargin: 14
|
||||
anchors.topMargin: 40
|
||||
property alias twitter: twitter
|
||||
|
||||
|
||||
|
||||
|
||||
Tab { id: twitter; title: qsTr("Twitter"); source: "tabs/Twitter.qml" }
|
||||
Tab { title: qsTr("News") + translationManager.emptyString }
|
||||
Tab { title: qsTr("Help") + translationManager.emptyString }
|
||||
Tab { title: qsTr("About") + translationManager.emptyString }
|
||||
|
||||
|
||||
|
||||
style: TabViewStyle {
|
||||
frameOverlap: 0
|
||||
tabOverlap: 0
|
||||
|
||||
tab: Rectangle {
|
||||
implicitHeight: 31
|
||||
implicitWidth: styleData.index === tabView.count - 1 ? tabView.width - (tabView.count - 1) * 68 : 68
|
||||
|
||||
Text {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.leftMargin: 12
|
||||
anchors.rightMargin: 12
|
||||
elide: Text.ElideRight
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 14
|
||||
color: styleData.selected ? "#FF4E40" : "#4A4646"
|
||||
text: styleData.title
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
visible: styleData.index !== tabView.count - 1
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.bottomMargin: -1
|
||||
height: 1
|
||||
color: styleData.selected ? "#FFFFFF" : "#DBDBDB"
|
||||
}
|
||||
}
|
||||
|
||||
frame: Rectangle {
|
||||
color: "#FFFFFF"
|
||||
anchors.fill: parent
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
//anchors.topMargin: 1
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Row {
|
||||
id: styledRow
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
|
||||
Rectangle { height: 8; width: parent.width / 5; color: "#FFE00A" }
|
||||
Rectangle { height: 8; width: parent.width / 5; color: "#6B0072" }
|
||||
Rectangle { height: 8; width: parent.width / 5; color: "#FF6C3C" }
|
||||
Rectangle { height: 8; width: parent.width / 5; color: "#FFD781" }
|
||||
Rectangle { height: 8; width: parent.width / 5 - 30; color: "#FF4F41" }
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
|
||||
// indicate disabled state
|
||||
// Desaturate {
|
||||
// anchors.fill: parent
|
||||
// source: parent
|
||||
// desaturation: root.enabled ? 0.0 : 1.0
|
||||
// }
|
||||
}
|
||||
|
||||
@@ -25,19 +25,12 @@ bool TranslationManager::setLanguage(const QString &language)
|
||||
return true;
|
||||
}
|
||||
|
||||
// translations are compiled into app binary
|
||||
#ifdef Q_OS_MACX
|
||||
QString dir = qApp->applicationDirPath() + "/../Resources/translations";
|
||||
#else
|
||||
QString dir = qApp->applicationDirPath() + "/translations";
|
||||
#endif
|
||||
|
||||
QString filename = "monero-core_" + language;
|
||||
|
||||
qDebug("%s: loading translation file '%s' from '%s",
|
||||
qDebug("%s: loading translation file '%s' from '%s'",
|
||||
__FUNCTION__, qPrintable(filename), qPrintable(dir));
|
||||
|
||||
|
||||
if (m_translator->load(filename, dir)) {
|
||||
qDebug("%s: translation for language '%s' loaded successfully",
|
||||
__FUNCTION__, qPrintable(language));
|
||||
@@ -45,11 +38,24 @@ bool TranslationManager::setLanguage(const QString &language)
|
||||
qApp->installTranslator(m_translator);
|
||||
emit languageChanged();
|
||||
return true;
|
||||
} else {
|
||||
qCritical("%s: error loading translation for language '%s'",
|
||||
__FUNCTION__, qPrintable(language));
|
||||
return false;
|
||||
}
|
||||
|
||||
qDebug("%s: couldn't load translation file '%s' from '%s'",
|
||||
__FUNCTION__, qPrintable(filename), qPrintable(dir));
|
||||
qDebug("%s: loading embedded translation file '%s'",
|
||||
__FUNCTION__, qPrintable(filename));
|
||||
|
||||
if (m_translator->load(filename, ":")) {
|
||||
qDebug("%s: embedded translation for language '%s' loaded successfully",
|
||||
__FUNCTION__, qPrintable(language));
|
||||
qApp->installTranslator(m_translator);
|
||||
emit languageChanged();
|
||||
return true;
|
||||
}
|
||||
|
||||
qCritical("%s: error loading translation for language '%s'",
|
||||
__FUNCTION__, qPrintable(language));
|
||||
return false;
|
||||
}
|
||||
|
||||
TranslationManager *TranslationManager::instance()
|
||||
|
||||
53
android/README.md
Normal file
@@ -0,0 +1,53 @@
|
||||
Copyright (c) 2014-2018, The Monero Project
|
||||
|
||||
|
||||
## Current status : ALPHA
|
||||
|
||||
- Minimum Android 5.0 (api level 21)
|
||||
- Modal dialogs can appear in background giving the feeling that the application is frozen (Work around : turn screen off/on or switch to another app and back)
|
||||
|
||||
## Build using Docker
|
||||
|
||||
# Base environnement
|
||||
|
||||
cd monero/utils/build_scripts
|
||||
docker build -f android32.Dockerfile -t monero-android .
|
||||
cd ..
|
||||
|
||||
# Build GUI
|
||||
|
||||
cd android/docker
|
||||
docker build -t monero-gui-android .
|
||||
docker create -it --name monero-gui-android monero-gui-android bash
|
||||
|
||||
# Get the apk
|
||||
|
||||
docker cp monero-gui-android:/opt/android/monero-gui/build/release/bin/bin/QtApp-debug.apk .
|
||||
|
||||
## Deployment
|
||||
|
||||
- Using ADB (Android debugger bridge) :
|
||||
|
||||
First, see section [Enable adb debugging on your device](https://developer.android.com/studio/command-line/adb.html#Enabling)
|
||||
The only place where we are allowed to play is `/data/local/tmp`. So :
|
||||
|
||||
adb push /opt/android/monero-gui/build/release/bin/bin/QtApp-debug.apk /data/local/tmp
|
||||
adb shell pm install -r /data/local/tmp/QtApp-debug.apk
|
||||
|
||||
- Troubleshooting:
|
||||
|
||||
adb devices -l
|
||||
adb logcat
|
||||
|
||||
if using adb inside docker, make sure you did "docker run -v /dev/bus/usb:/dev/bus/usb --privileged"
|
||||
|
||||
- Using a web server
|
||||
|
||||
mkdir /usr/tmp
|
||||
cp QtApp-debug.apk /usr/tmp
|
||||
docker run -d -v /usr/tmp:/usr/share/nginx/html:ro -p 8080:80 nginx
|
||||
|
||||
Now it should be accessible through a web browser at
|
||||
|
||||
http://<your.local.ip>:8080/QtApp-debug.apk
|
||||
|
||||
107
android/docker/Dockerfile
Normal file
@@ -0,0 +1,107 @@
|
||||
FROM monero-android
|
||||
|
||||
#INSTALL JAVA
|
||||
RUN echo "deb http://ftp.fr.debian.org/debian/ jessie-backports main contrib non-free" >> /etc/apt/sources.list
|
||||
RUN dpkg --add-architecture i386 \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y libc6:i386 libncurses5:i386 libstdc++6:i386 libz1:i386 \
|
||||
&& apt-get install -y -t jessie-backports ca-certificates-java openjdk-8-jdk-headless openjdk-8-jre-headless ant
|
||||
ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64
|
||||
ENV PATH $JAVA_HOME/bin:$PATH
|
||||
|
||||
#Get Qt
|
||||
ENV QT_VERSION 5.8
|
||||
|
||||
RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} \
|
||||
&& cd qt5 \
|
||||
&& perl init-repository
|
||||
|
||||
## Note: Need to use libc++ but Qt does not provide mkspec for libc++.
|
||||
## Their support of it is quite recent and they claim they don't use it by default
|
||||
## [only because it produces bigger binary objects](https://bugreports.qt.io/browse/QTBUG-50724).
|
||||
|
||||
#Create new mkspec for clang + libc++
|
||||
RUN cp -r qt5/qtbase/mkspecs/android-clang qt5/qtbase/mkspecs/android-clang-libc \
|
||||
&& cd qt5/qtbase/mkspecs/android-clang-libc \
|
||||
&& sed -i '16i ANDROID_SOURCES_CXX_STL_LIBDIR = $$NDK_ROOT/sources/cxx-stl/llvm-libc++/libs/$$ANDROID_TARGET_ARCH' qmake.conf \
|
||||
&& sed -i '17i ANDROID_SOURCES_CXX_STL_INCDIR = $$NDK_ROOT/sources/cxx-stl/llvm-libc++/include' qmake.conf \
|
||||
&& echo "QMAKE_LIBS_PRIVATE = -lc++_shared -llog -lz -lm -ldl -lc -lgcc " >> qmake.conf \
|
||||
&& echo "QMAKE_CFLAGS -= -mfpu=vfp " >> qmake.conf \
|
||||
&& echo "QMAKE_CXXFLAGS -= -mfpu=vfp " >> qmake.conf \
|
||||
&& echo "QMAKE_CFLAGS += -mfpu=vfp4 " >> qmake.conf \
|
||||
&& echo "QMAKE_CXXFLAGS += -mfpu=vfp4 " >> qmake.conf
|
||||
|
||||
ENV ANDROID_API android-21
|
||||
|
||||
#ANDROID SDK TOOLS
|
||||
RUN echo y | $ANDROID_SDK_ROOT/tools/android update sdk --no-ui --all --filter platform-tools
|
||||
RUN echo y | $ANDROID_SDK_ROOT/tools/android update sdk --no-ui --all --filter ${ANDROID_API}
|
||||
RUN echo y | $ANDROID_SDK_ROOT/tools/android update sdk --no-ui --all --filter build-tools-25.0.1
|
||||
|
||||
ENV CLEAN_PATH $JAVA_HOME/bin:/usr/cmake-3.6.3-Linux-x86_64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||
|
||||
#build Qt
|
||||
RUN cd qt5 && PATH=${CLEAN_PATH} ./configure -developer-build -release \
|
||||
-xplatform android-clang-libc \
|
||||
-android-ndk-platform ${ANDROID_API} \
|
||||
-android-ndk $ANDROID_NDK_ROOT \
|
||||
-android-sdk $ANDROID_SDK_ROOT \
|
||||
-opensource -confirm-license \
|
||||
-prefix ${WORKDIR}/Qt-${QT_VERSION} \
|
||||
-nomake tests -nomake examples \
|
||||
-skip qtserialport \
|
||||
-skip qtconnectivity \
|
||||
-skip qttranslations \
|
||||
-skip qtgamepad -skip qtscript -skip qtdoc
|
||||
|
||||
# build Qt tools : gnustl_shared.so is hard-coded in androiddeployqt
|
||||
# replace it with libc++_shared.so
|
||||
COPY androiddeployqt.patch qt5/qttools/androiddeployqt.patch
|
||||
RUN cd qt5/qttools \
|
||||
&& git apply androiddeployqt.patch \
|
||||
&& cd .. \
|
||||
&& PATH=${CLEAN_PATH} make -j4 \
|
||||
&& PATH=${CLEAN_PATH} make install
|
||||
|
||||
# Get iconv and ZBar
|
||||
ENV ICONV_VERSION 1.14
|
||||
RUN git clone https://github.com/ZBar/ZBar.git \
|
||||
&& curl -s -O http://ftp.gnu.org/pub/gnu/libiconv/libiconv-${ICONV_VERSION}.tar.gz \
|
||||
&& tar -xzf libiconv-${ICONV_VERSION}.tar.gz \
|
||||
&& cd libiconv-${ICONV_VERSION} \
|
||||
&& CC=arm-linux-androideabi-clang CXX=arm-linux-androideabi-clang++ ./configure --build=x86_64-linux-gnu --host=arm-eabi --prefix=${WORKDIR}/libiconv --disable-rpath
|
||||
|
||||
ENV PATH $ANDROID_SDK_ROOT/tools:$ANDROID_SDK_ROOT/platform-tools:${WORKDIR}/Qt-${QT_VERSION}/bin:$PATH
|
||||
|
||||
#Build libiconv.a and libzbarjni.a
|
||||
COPY android.mk.patch ZBar/android.mk.patch
|
||||
RUN cd ZBar \
|
||||
&& git apply android.mk.patch \
|
||||
&& echo \
|
||||
"APP_ABI := armeabi-v7a \n\
|
||||
APP_STL := c++_shared \n\
|
||||
TARGET_PLATFORM := ${ANDROID_API} \n\
|
||||
TARGET_ARCH_ABI := armeabi-v7a \n\
|
||||
APP_CFLAGS += -target armv7-none-linux-androideabi -fexceptions -fstack-protector-strong -fno-limit-debug-info -mfloat-abi=softfp -mfpu=vfp -fno-builtin-memmove -fno-omit-frame-pointer -fno-stack-protector\n"\
|
||||
>> android/jni/Application.mk \
|
||||
&& cd android \
|
||||
&& android update project --path . -t "${ANDROID_API}" \
|
||||
&& CC=arm-linux-androideabi-clang CXX=arm-linux-androideabi-clang++ ant -Dndk.dir=${ANDROID_NDK_ROOT} -Diconv.src=${WORKDIR}/libiconv-${ICONV_VERSION} zbar-clean zbar-ndk-build
|
||||
|
||||
RUN cp openssl/lib* ${ANDROID_NDK_ROOT}/platforms/${ANDROID_API}/arch-arm/usr/lib
|
||||
RUN cp boost_${BOOST_VERSION}/android32/lib/lib* ${ANDROID_NDK_ROOT}/platforms/${ANDROID_API}/arch-arm/usr/lib
|
||||
RUN cp ZBar/android/obj/local/armeabi-v7a/lib* ${ANDROID_NDK_ROOT}/platforms/${ANDROID_API}/arch-arm/usr/lib
|
||||
|
||||
RUN git clone https://github.com/monero-project/monero-gui.git \
|
||||
&& cd monero-gui \
|
||||
&& git submodule update \
|
||||
&& CC=arm-linux-androideabi-clang CXX=arm-linux-androideabi-clang++ BOOST_ROOT=/opt/android/boost_1_62_0 \
|
||||
BOOST_LIBRARYDIR=${WORKDIR}/boost_${BOOST_VERSION}/android32/lib/ \
|
||||
OPENSSL_ROOT_DIR=${WORKDIR}/openssl/ \
|
||||
CMAKE_INCLUDE_PATH=${WORKDIR}/cppzmq/ \
|
||||
CMAKE_LIBRARY_PATH=${WORKDIR}/zeromq4-1/.libs \
|
||||
CXXFLAGS="-I ${WORKDIR}/zeromq4-1/include/" \
|
||||
./build.sh release-android \
|
||||
&& cd build \
|
||||
&& make deploy
|
||||
|
||||
61
android/docker/android.mk.patch
Normal file
@@ -0,0 +1,61 @@
|
||||
diff --git a/android/jni/Android.mk b/android/jni/Android.mk
|
||||
index e442b07..158afd5 100644
|
||||
--- a/android/jni/Android.mk
|
||||
+++ b/android/jni/Android.mk
|
||||
@@ -12,14 +12,18 @@ LOCAL_PATH := $(ICONV_SRC)
|
||||
|
||||
LOCAL_MODULE := libiconv
|
||||
|
||||
+LOCAL_ARM_MODE := arm
|
||||
+LOCAL_CPP_FEATURES := exceptions rtti features
|
||||
LOCAL_CFLAGS := \
|
||||
-Wno-multichar \
|
||||
-D_ANDROID \
|
||||
- -DLIBDIR="c" \
|
||||
+ -DLIBDIR="\".\"" \
|
||||
-DBUILDING_LIBICONV \
|
||||
-DBUILDING_LIBCHARSET \
|
||||
-DIN_LIBRARY
|
||||
|
||||
+LOCAL_CFLAGS += -fno-stack-protector
|
||||
+
|
||||
LOCAL_SRC_FILES := \
|
||||
lib/iconv.c \
|
||||
libcharset/lib/localcharset.c \
|
||||
@@ -30,13 +34,14 @@ LOCAL_C_INCLUDES := \
|
||||
$(ICONV_SRC)/libcharset \
|
||||
$(ICONV_SRC)/libcharset/include
|
||||
|
||||
-include $(BUILD_SHARED_LIBRARY)
|
||||
+include $(BUILD_STATIC_LIBRARY)
|
||||
|
||||
LOCAL_LDLIBS := -llog -lcharset
|
||||
|
||||
# libzbarjni
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
+
|
||||
LOCAL_PATH := $(MY_LOCAL_PATH)
|
||||
LOCAL_MODULE := zbarjni
|
||||
LOCAL_SRC_FILES := ../../java/zbarjni.c \
|
||||
@@ -71,6 +76,17 @@ LOCAL_C_INCLUDES := ../include \
|
||||
../zbar \
|
||||
$(ICONV_SRC)/include
|
||||
|
||||
-LOCAL_SHARED_LIBRARIES := libiconv
|
||||
+LOCAL_STATIC_LIBRARIES := libiconv
|
||||
+LOCAL_ARM_MODE := arm
|
||||
+LOCAL_CPP_FEATURES := exceptions rtti features
|
||||
+
|
||||
+LOCAL_CFLAGS := \
|
||||
+ -Wno-multichar \
|
||||
+ -D_ANDROID \
|
||||
+ -DLIBDIR="\".\"" \
|
||||
+ -DBUILDING_LIBICONV \
|
||||
+ -DBUILDING_LIBCHARSET \
|
||||
+ -DIN_LIBRARY
|
||||
+
|
||||
|
||||
-include $(BUILD_SHARED_LIBRARY)
|
||||
\ No newline at end of file
|
||||
+include $(BUILD_STATIC_LIBRARY)
|
||||
62
android/docker/androiddeployqt.patch
Normal file
@@ -0,0 +1,62 @@
|
||||
diff --git a/src/androiddeployqt/main.cpp b/src/androiddeployqt/main.cpp
|
||||
index 8a8e591..71d693e 100644
|
||||
--- a/src/androiddeployqt/main.cpp
|
||||
+++ b/src/androiddeployqt/main.cpp
|
||||
@@ -1122,7 +1122,7 @@ bool updateLibsXml(const Options &options)
|
||||
|
||||
QString libsPath = QLatin1String("libs/") + options.architecture + QLatin1Char('/');
|
||||
|
||||
- QString qtLibs = QLatin1String("<item>gnustl_shared</item>\n");
|
||||
+ QString qtLibs = QLatin1String("<item>c++_shared</item>\n");
|
||||
QString bundledInLibs;
|
||||
QString bundledInAssets;
|
||||
foreach (Options::BundledFile bundledFile, options.bundledFiles) {
|
||||
@@ -2519,6 +2519,39 @@ bool installApk(const Options &options)
|
||||
return true;
|
||||
}
|
||||
|
||||
+bool copyStl(Options *options)
|
||||
+{
|
||||
+ if (options->deploymentMechanism == Options::Debug && !options->installApk)
|
||||
+ return true;
|
||||
+
|
||||
+ if (options->verbose)
|
||||
+ fprintf(stdout, "Copying LIBC++ STL library\n");
|
||||
+
|
||||
+ QString filePath = options->ndkPath
|
||||
+ + QLatin1String("/sources/cxx-stl/llvm-libc++")
|
||||
+ + QLatin1String("/libs/")
|
||||
+ + options->architecture
|
||||
+ + QLatin1String("/libc++_shared.so");
|
||||
+ if (!QFile::exists(filePath)) {
|
||||
+ fprintf(stderr, "LIBC STL library does not exist at %s\n", qPrintable(filePath));
|
||||
+ return false;
|
||||
+ }
|
||||
+
|
||||
+ QString destinationDirectory =
|
||||
+ options->deploymentMechanism == Options::Debug
|
||||
+ ? options->temporaryDirectoryName + QLatin1String("/lib")
|
||||
+ : options->outputDirectory + QLatin1String("/libs/") + options->architecture;
|
||||
+
|
||||
+ if (!copyFileIfNewer(filePath, destinationDirectory
|
||||
+ + QLatin1String("/libc++_shared.so"), options->verbose)) {
|
||||
+ return false;
|
||||
+ }
|
||||
+
|
||||
+ if (options->deploymentMechanism == Options::Debug && !deployToLocalTmp(options, QLatin1String("/lib/libc++_shared.so")))
|
||||
+ return false;
|
||||
+
|
||||
+ return true;
|
||||
+}
|
||||
bool copyGnuStl(Options *options)
|
||||
{
|
||||
if (options->deploymentMechanism == Options::Debug && !options->installApk)
|
||||
@@ -2870,7 +2903,7 @@ int main(int argc, char *argv[])
|
||||
if (Q_UNLIKELY(options.timing))
|
||||
fprintf(stdout, "[TIMING] %d ms: Read dependencies\n", options.timer.elapsed());
|
||||
|
||||
- if (options.deploymentMechanism != Options::Ministro && !copyGnuStl(&options))
|
||||
+ if (options.deploymentMechanism != Options::Ministro && !copyStl(&options))
|
||||
return CannotCopyGnuStl;
|
||||
|
||||
if (Q_UNLIKELY(options.timing))
|
||||
42
build.sh
@@ -8,6 +8,22 @@ if [ -z $BUILD_TYPE ]; then
|
||||
BUILD_TYPE=release
|
||||
fi
|
||||
|
||||
# Return 0 if the command exists, 1 if it does not.
|
||||
exists() {
|
||||
command -v "$1" &>/dev/null
|
||||
}
|
||||
|
||||
# Return the first value in $@ that's a runnable command.
|
||||
find_command() {
|
||||
for arg in "$@"; do
|
||||
if exists "$arg"; then
|
||||
echo "$arg"
|
||||
return 0
|
||||
fi
|
||||
done
|
||||
return 1
|
||||
}
|
||||
|
||||
if [ "$BUILD_TYPE" == "release" ]; then
|
||||
echo "Building release"
|
||||
CONFIG="CONFIG+=release";
|
||||
@@ -24,14 +40,16 @@ elif [ "$BUILD_TYPE" == "release-static" ]; then
|
||||
BIN_PATH=release/bin
|
||||
elif [ "$BUILD_TYPE" == "release-android" ]; then
|
||||
echo "Building release for ANDROID"
|
||||
CONFIG="CONFIG+=release static WITH_SCANNER";
|
||||
CONFIG="CONFIG+=release static WITH_SCANNER DISABLE_PASS_STRENGTH_METER";
|
||||
ANDROID=true
|
||||
BIN_PATH=release/bin
|
||||
DISABLE_PASS_STRENGTH_METER=true
|
||||
elif [ "$BUILD_TYPE" == "debug-android" ]; then
|
||||
echo "Building debug for ANDROID : ultra INSECURE !!"
|
||||
CONFIG="CONFIG+=debug qml_debug WITH_SCANNER";
|
||||
CONFIG="CONFIG+=debug qml_debug WITH_SCANNER DISABLE_PASS_STRENGTH_METER";
|
||||
ANDROID=true
|
||||
BIN_PATH=debug/bin
|
||||
DISABLE_PASS_STRENGTH_METER=true
|
||||
elif [ "$BUILD_TYPE" == "debug" ]; then
|
||||
echo "Building debug"
|
||||
CONFIG="CONFIG+=debug"
|
||||
@@ -54,18 +72,20 @@ if [[ $platform == *bsd* ]]; then
|
||||
fi
|
||||
|
||||
# build libwallet
|
||||
$SHELL get_libwallet_api.sh $BUILD_TYPE
|
||||
./get_libwallet_api.sh $BUILD_TYPE
|
||||
|
||||
# build zxcvbn
|
||||
$MAKE -C src/zxcvbn-c || exit
|
||||
if [ "$DISABLE_PASS_STRENGTH_METER" != true ]; then
|
||||
$MAKE -C src/zxcvbn-c || exit
|
||||
fi
|
||||
|
||||
if [ ! -d build ]; then mkdir build; fi
|
||||
|
||||
|
||||
# Platform indepenent settings
|
||||
if [ "$ANDROID" != true ] && ([ "$platform" == "linux32" ] || [ "$platform" == "linux64" ]); then
|
||||
distro=$(lsb_release -is)
|
||||
if [ "$distro" == "Ubuntu" ]; then
|
||||
exists lsb_release && distro="$(lsb_release -is)"
|
||||
if [ "$distro" = "Ubuntu" ] || [ "$distro" = "Fedora" ] || test -f /etc/fedora-release; then
|
||||
CONFIG="$CONFIG libunwind_off"
|
||||
fi
|
||||
fi
|
||||
@@ -78,14 +98,18 @@ fi
|
||||
|
||||
# force version update
|
||||
get_tag
|
||||
echo "var GUI_VERSION = \"$VERSIONTAG\"" > version.js
|
||||
echo "var GUI_VERSION = \"$TAGNAME\"" > version.js
|
||||
pushd "$MONERO_DIR"
|
||||
get_tag
|
||||
popd
|
||||
echo "var GUI_MONERO_VERSION = \"$VERSIONTAG\"" >> version.js
|
||||
echo "var GUI_MONERO_VERSION = \"$TAGNAME\"" >> version.js
|
||||
|
||||
cd build
|
||||
qmake ../monero-wallet-gui.pro "$CONFIG" || exit
|
||||
if ! QMAKE=$(find_command qmake qmake-qt5); then
|
||||
echo "Failed to find suitable qmake command."
|
||||
exit 1
|
||||
fi
|
||||
$QMAKE ../monero-wallet-gui.pro "$CONFIG" || exit
|
||||
$MAKE || exit
|
||||
|
||||
# Copy monerod to bin folder
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
|
||||
# MONERO_URL=https://github.com/monero-project/monero.git
|
||||
# MONERO_BRANCH=master
|
||||
CPU_CORE_COUNT=$(grep -c ^processor /proc/cpuinfo 2>/dev/null || sysctl -n hw.ncpu)
|
||||
pushd $(pwd)
|
||||
ROOT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
|
||||
source $ROOT_DIR/utils.sh
|
||||
|
||||
|
||||
INSTALL_DIR=$ROOT_DIR/wallet
|
||||
MONERO_DIR=$ROOT_DIR/monero
|
||||
|
||||
|
||||
mkdir -p $MONERO_DIR/build/release
|
||||
pushd $MONERO_DIR/build/release
|
||||
|
||||
# reusing function from "utils.sh"
|
||||
platform=$(get_platform)
|
||||
|
||||
pushd $MONERO_DIR/build/release/src/wallet
|
||||
make -j$CPU_CORE_COUNT
|
||||
make install -j$CPU_CORE_COUNT
|
||||
popd
|
||||
|
||||
# unbound is one more dependency. can't be merged to the wallet_merged
|
||||
# since filename conflict (random.c.obj)
|
||||
# for Linux, we use libunbound shipped with the system, so we don't need to build it
|
||||
|
||||
if [ "$platform" != "linux" ]; then
|
||||
echo "Building libunbound..."
|
||||
pushd $MONERO_DIR/build/release/external/unbound
|
||||
# no need to make, it was already built as dependency for libwallet
|
||||
# make -j$CPU_CORE_COUNT
|
||||
make install -j$CPU_CORE_COUNT
|
||||
popd
|
||||
fi
|
||||
|
||||
popd
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -37,13 +37,13 @@ ListView {
|
||||
footer: Rectangle {
|
||||
height: 127
|
||||
width: listView.width
|
||||
color: "#FFFFFF"
|
||||
color: "transparent"
|
||||
|
||||
Text {
|
||||
anchors.centerIn: parent
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 14
|
||||
color: "#545454"
|
||||
color: "#808080"
|
||||
text: qsTr("No more results") + translationManager.emptyString
|
||||
}
|
||||
}
|
||||
@@ -53,7 +53,7 @@ ListView {
|
||||
id: delegate
|
||||
height: 64
|
||||
width: listView.width
|
||||
color: index % 2 ? "#F8F8F8" : "#FFFFFF"
|
||||
color: "transparent"
|
||||
z: listView.count - index
|
||||
function collapseDropdown() { dropdown.expanded = false }
|
||||
|
||||
@@ -62,11 +62,11 @@ ListView {
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 12
|
||||
width: text.length ? (descriptionArea.containsMouse ? dropdown.x - x - 12 : 139) : 0
|
||||
width: text.length ? (descriptionArea.containsMouse ? 139 : 139) : 0
|
||||
font.family: "Arial"
|
||||
font.bold: true
|
||||
font.pixelSize: 19
|
||||
color: "#444444"
|
||||
color: "#ffffff"
|
||||
elide: Text.ElideRight
|
||||
text: description
|
||||
|
||||
@@ -87,8 +87,9 @@ ListView {
|
||||
anchors.rightMargin: 40
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 16
|
||||
color: "#545454"
|
||||
color: "#ffffff"
|
||||
text: address
|
||||
readOnly: true
|
||||
}
|
||||
|
||||
Text {
|
||||
@@ -100,7 +101,7 @@ ListView {
|
||||
width: 139
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#535353"
|
||||
color: "#ffffff"
|
||||
text: qsTr("Payment ID:") + translationManager.emptyString
|
||||
}
|
||||
|
||||
@@ -111,7 +112,7 @@ ListView {
|
||||
anchors.leftMargin: 12
|
||||
anchors.rightMargin: 12
|
||||
anchors.right: dropdown.left
|
||||
|
||||
readOnly: true
|
||||
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 13
|
||||
@@ -122,7 +123,7 @@ ListView {
|
||||
ListModel {
|
||||
id: dropModel
|
||||
ListElement { name: "<b>Copy address to clipboard</b>"; icon: "../images/dropdownCopy.png" }
|
||||
ListElement { name: "<b>Send to same destination</b>"; icon: "../images/dropdownSend.png" }
|
||||
ListElement { name: "<b>Send to this address</b>"; icon: "../images/dropdownSend.png" }
|
||||
// ListElement { name: "<b>Find similar transactions</b>"; icon: "../images/dropdownSearch.png" }
|
||||
ListElement { name: "<b>Remove from address book</b>"; icon: "../images/dropdownDel.png" }
|
||||
}
|
||||
@@ -144,8 +145,10 @@ ListView {
|
||||
onOptionClicked: {
|
||||
// Ensure tooltip is closed
|
||||
appWindow.toolTip.visible = false;
|
||||
if(option === 0)
|
||||
if(option === 0) {
|
||||
clipboard.setText(address)
|
||||
appWindow.showStatusMessage(qsTr("Address copied to clipboard"),3)
|
||||
}
|
||||
else if(option === 1){
|
||||
console.log("Sending to: ", address +" "+ paymentId);
|
||||
middlePanel.sendTo(address, paymentId, description);
|
||||
@@ -162,7 +165,7 @@ ListView {
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
color: "#404040"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -29,61 +29,81 @@
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
Item {
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
RowLayout {
|
||||
id: checkBox
|
||||
property alias text: label.text
|
||||
property string checkedIcon
|
||||
property string checkedIcon: "../images/checkedIcon-black.png"
|
||||
property string uncheckedIcon
|
||||
property bool checked: false
|
||||
property alias background: backgroundRect.color
|
||||
property int fontSize: 14
|
||||
property int fontSize: 14 * scaleRatio
|
||||
property alias fontColor: label.color
|
||||
signal clicked()
|
||||
height: 25
|
||||
width: label.x + label.width
|
||||
Layout.minimumWidth: label.x + label.contentWidth
|
||||
clip: true
|
||||
height: 25 * scaleRatio
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
height: parent.height - 1
|
||||
width: 25
|
||||
//radius: 4
|
||||
y: 0
|
||||
color: "#DBDBDB"
|
||||
function toggle(){
|
||||
checkBox.checked = !checkBox.checked
|
||||
checkBox.clicked()
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: backgroundRect
|
||||
anchors.left: parent.left
|
||||
height: parent.height - 1
|
||||
width: 25
|
||||
//radius: 4
|
||||
y: 1
|
||||
color: "#FFFFFF"
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: checkBox.checked ? checkBox.checkedIcon :
|
||||
checkBox.uncheckedIcon
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
width: 25 * scaleRatio
|
||||
height: checkBox.height - 1
|
||||
radius: 3
|
||||
y: 0
|
||||
color: "transparent"
|
||||
border.color:
|
||||
if(checkBox.checked){
|
||||
return MoneroComponents.Style.inputBorderColorActive;
|
||||
} else {
|
||||
return MoneroComponents.Style.inputBorderColorInActive;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
id: label
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 25 + 12
|
||||
font.family: "Arial"
|
||||
font.pixelSize: checkBox.fontSize
|
||||
color: "#525252"
|
||||
}
|
||||
Rectangle {
|
||||
id: backgroundRect
|
||||
anchors.left: parent.left
|
||||
width: 25 * scaleRatio
|
||||
height: checkBox.height - 1
|
||||
y: 1
|
||||
color: "transparent"
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: {
|
||||
checkBox.checked = !checkBox.checked
|
||||
checkBox.clicked()
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: checkBox.checkedIcon
|
||||
visible: checkBox.checked
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
toggle()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
id: label
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: checkBox.fontSize
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
wrapMode: Text.Wrap
|
||||
Layout.fillWidth: true
|
||||
anchors.left: backgroundRect.right
|
||||
anchors.leftMargin: !isMobile ? 10 : 8
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
toggle()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
107
components/CheckBox2.qml
Normal file
@@ -0,0 +1,107 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtGraphicalEffects 1.0
|
||||
import "." 1.0
|
||||
|
||||
RowLayout {
|
||||
id: checkBox
|
||||
property alias text: label.text
|
||||
property string checkedIcon: "../images/checkedIcon-black.png"
|
||||
property string uncheckedIcon
|
||||
property bool checked: false
|
||||
property string background: "backgroundRect.color"
|
||||
property int fontSize: 14 * scaleRatio
|
||||
property alias fontColor: label.color
|
||||
property int textMargin: 8 * scaleRatio
|
||||
property bool darkDropIndicator: false
|
||||
signal clicked()
|
||||
height: 25 * scaleRatio
|
||||
|
||||
function toggle(){
|
||||
checkBox.checked = !checkBox.checked
|
||||
checkBox.clicked()
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
|
||||
Rectangle{
|
||||
height: label.height
|
||||
width: (label.width + indicatorRect.width + checkBox.textMargin)
|
||||
color: "transparent"
|
||||
anchors.left: parent.left
|
||||
|
||||
Text {
|
||||
id: label
|
||||
font.family: Style.fontLight.name
|
||||
font.pixelSize: checkBox.fontSize
|
||||
color: Style.defaultFontColor
|
||||
wrapMode: Text.Wrap
|
||||
Layout.fillWidth: true
|
||||
anchors.left: parent.left
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: indicatorRect
|
||||
width: indicatorImage.width
|
||||
height: label.height
|
||||
anchors.left: label.right
|
||||
anchors.leftMargin: textMargin
|
||||
color: "transparent"
|
||||
rotation: checkBox.checked ? 180 * scaleRatio : 0
|
||||
|
||||
Image {
|
||||
id: indicatorImage
|
||||
anchors.centerIn: parent
|
||||
source: "../images/whiteDropIndicator.png"
|
||||
visible: !darkDropIndicator
|
||||
}
|
||||
ColorOverlay {
|
||||
anchors.fill: indicatorImage
|
||||
source: indicatorImage
|
||||
color: "#FF000000"
|
||||
visible: darkDropIndicator
|
||||
}
|
||||
}
|
||||
|
||||
MouseArea{
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
toggle();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -27,22 +27,23 @@
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Window 2.0
|
||||
import QtQuick.Window 2.2
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import "../js/Windows.js" as Windows
|
||||
import "../js/Utils.js" as Utils
|
||||
|
||||
Window {
|
||||
id: root
|
||||
modality: Qt.ApplicationModal
|
||||
flags: Qt.Window | Qt.FramelessWindowHint
|
||||
property alias title: dialogTitle.text
|
||||
color: "black"
|
||||
flags: Windows.flags
|
||||
property alias text: dialogContent.text
|
||||
property alias content: root.text
|
||||
property alias okVisible: okButton.visible
|
||||
property alias textArea: dialogContent
|
||||
property var icon
|
||||
|
||||
@@ -50,98 +51,166 @@ Window {
|
||||
signal accepted()
|
||||
signal rejected()
|
||||
|
||||
onClosing: {
|
||||
inactiveOverlay.visible = false;
|
||||
}
|
||||
|
||||
function open() {
|
||||
show()
|
||||
inactiveOverlay.visible = true;
|
||||
show();
|
||||
}
|
||||
|
||||
// TODO: implement without hardcoding sizes
|
||||
width: 480
|
||||
height: 280
|
||||
|
||||
// background gradient
|
||||
Image {
|
||||
anchors.fill: parent
|
||||
source: "../images/middlePanelBg.jpg"
|
||||
}
|
||||
|
||||
// Make window draggable
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
property point lastMousePos: Qt.point(0, 0)
|
||||
onPressed: { lastMousePos = Qt.point(mouseX, mouseY); }
|
||||
onMouseXChanged: root.x += (mouseX - lastMousePos.x)
|
||||
onMouseYChanged: root.y += (mouseY - lastMousePos.y)
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
id: mainLayout
|
||||
spacing: 10
|
||||
anchors { fill: parent; margins: 35 }
|
||||
|
||||
anchors.fill: parent
|
||||
anchors.topMargin: 20 * scaleRatio
|
||||
anchors.margins: 35 * scaleRatio
|
||||
spacing: 20 * scaleRatio
|
||||
|
||||
RowLayout {
|
||||
id: column
|
||||
//anchors {fill: parent; margins: 16 }
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
id: content
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
|
||||
Label {
|
||||
id: dialogTitle
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
font.pixelSize: 32
|
||||
font.family: "Arial"
|
||||
color: "#555555"
|
||||
}
|
||||
Flickable {
|
||||
id: flickable
|
||||
anchors.fill: parent
|
||||
|
||||
}
|
||||
TextArea.flickable: TextArea {
|
||||
id : dialogContent
|
||||
textFormat: TextEdit.RichText
|
||||
selectByMouse: true
|
||||
selectByKeyboard: true
|
||||
anchors.fill: parent
|
||||
font.family: "Ariel"
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
selectionColor: MoneroComponents.Style.dimmedFontColor
|
||||
wrapMode: TextEdit.Wrap
|
||||
readOnly: true
|
||||
background: Rectangle {
|
||||
color: "transparent"
|
||||
anchors.fill: parent
|
||||
border.color: Qt.rgba(255, 255, 255, 0.25);
|
||||
border.width: 1
|
||||
radius: 4
|
||||
}
|
||||
function logCommand(msg){
|
||||
msg = log_color(msg, "lime");
|
||||
textArea.append(msg);
|
||||
}
|
||||
function logMessage(msg){
|
||||
msg = msg.trim();
|
||||
var color = "white";
|
||||
if(msg.toLowerCase().indexOf('error') >= 0){
|
||||
color = "red";
|
||||
} else if (msg.toLowerCase().indexOf('warning') >= 0){
|
||||
color = "yellow";
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
TextArea {
|
||||
id : dialogContent
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
font.family: "Arial"
|
||||
textFormat: TextEdit.AutoText
|
||||
readOnly: true
|
||||
font.pixelSize: 12
|
||||
}
|
||||
}
|
||||
// format multi-lines
|
||||
if(msg.split("\n").length >= 2){
|
||||
msg = msg.split("\n").join('<br>');
|
||||
}
|
||||
|
||||
// Ok/Cancel buttons
|
||||
RowLayout {
|
||||
id: buttons
|
||||
spacing: 60
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
log(msg, color);
|
||||
}
|
||||
function log_color(msg, color){
|
||||
return "<span style='color: " + color + ";' >" + msg + "</span>";
|
||||
}
|
||||
function log(msg, color){
|
||||
var timestamp = Utils.formatDate(new Date(), {
|
||||
weekday: undefined,
|
||||
month: "numeric",
|
||||
timeZoneName: undefined
|
||||
});
|
||||
|
||||
MoneroComponents.StandardButton {
|
||||
id: okButton
|
||||
width: 120
|
||||
fontSize: 14
|
||||
shadowReleasedColor: "#FF4304"
|
||||
shadowPressedColor: "#B32D00"
|
||||
releasedColor: "#FF6C3C"
|
||||
pressedColor: "#FF4304"
|
||||
text: qsTr("Close") + translationManager.emptyString
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.accepted()
|
||||
var _timestamp = log_color("[" + timestamp + "]", "#FFFFFF");
|
||||
var _msg = log_color(msg, color);
|
||||
textArea.append(_timestamp + " " + _msg);
|
||||
|
||||
// scroll to bottom
|
||||
//if(flickable.contentHeight > content.height){
|
||||
// flickable.contentY = flickable.contentHeight + 20;
|
||||
//}
|
||||
}
|
||||
}
|
||||
|
||||
ScrollBar.vertical: ScrollBar {
|
||||
// TODO: scrollbar always visible is buggy.
|
||||
// QT 5.9 introduces `policy: ScrollBar.AlwaysOn`
|
||||
contentItem.opacity: 1
|
||||
anchors.top: flickable.top
|
||||
anchors.left: flickable.right
|
||||
anchors.leftMargin: 10 * scaleRatio
|
||||
anchors.bottom: flickable.bottom
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
|
||||
MoneroComponents.LineEdit {
|
||||
id: sendCommandText
|
||||
width: 300
|
||||
Layout.fillWidth: true
|
||||
placeholderText: qsTr("command + enter (e.g help)") + translationManager.emptyString
|
||||
onAccepted: {
|
||||
if(text.length > 0)
|
||||
daemonManager.sendCommand(text,currentWallet.testnet);
|
||||
if(text.length > 0) {
|
||||
textArea.logCommand(">>> " + text)
|
||||
daemonManager.sendCommand(text, currentWallet.nettype);
|
||||
}
|
||||
text = ""
|
||||
}
|
||||
}
|
||||
|
||||
// Status button
|
||||
// MoneroComponents.StandardButton {
|
||||
// id: sendCommandButton
|
||||
// enabled: sendCommandText.text.length > 0
|
||||
// fontSize: 14
|
||||
// shadowReleasedColor: "#FF4304"
|
||||
// shadowPressedColor: "#B32D00"
|
||||
// releasedColor: "#FF6C3C"
|
||||
// pressedColor: "#FF4304"
|
||||
// text: qsTr("Send command")
|
||||
// onClicked: {
|
||||
// daemonManager.sendCommand(sendCommandText.text,currentWallet.testnet);
|
||||
// }
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
// window borders
|
||||
Rectangle {
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
width:1
|
||||
color: "#2F2F2F"
|
||||
z: 2
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
width:1
|
||||
color: "#2F2F2F"
|
||||
z: 2
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
anchors.left: parent.left
|
||||
height:1
|
||||
color: "#2F2F2F"
|
||||
z: 2
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -39,13 +39,13 @@ Window {
|
||||
id: root
|
||||
modality: Qt.ApplicationModal
|
||||
flags: Qt.Window | Qt.FramelessWindowHint
|
||||
property int countDown: 5;
|
||||
property int countDown: 10;
|
||||
signal rejected()
|
||||
signal started();
|
||||
|
||||
function open() {
|
||||
show()
|
||||
countDown = 5;
|
||||
countDown = 10;
|
||||
timer.start();
|
||||
}
|
||||
|
||||
@@ -53,6 +53,15 @@ Window {
|
||||
width: 480
|
||||
height: 200
|
||||
|
||||
// Make window draggable
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
property point lastMousePos: Qt.point(0, 0)
|
||||
onPressed: { lastMousePos = Qt.point(mouseX, mouseY); }
|
||||
onMouseXChanged: root.x += (mouseX - lastMousePos.x)
|
||||
onMouseYChanged: root.y += (mouseY - lastMousePos.y)
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
id: mainLayout
|
||||
spacing: 10
|
||||
@@ -81,7 +90,7 @@ Window {
|
||||
}
|
||||
|
||||
Text {
|
||||
text: qsTr("Starting Monero daemon in %1 seconds").arg(countDown);
|
||||
text: qsTr("Starting local node in %1 seconds").arg(countDown);
|
||||
font.pixelSize: 18
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.fillWidth: true
|
||||
@@ -99,10 +108,6 @@ Window {
|
||||
id: okButton
|
||||
visible:false
|
||||
fontSize: 14
|
||||
shadowReleasedColor: "#FF4304"
|
||||
shadowPressedColor: "#B32D00"
|
||||
releasedColor: "#FF6C3C"
|
||||
pressedColor: "#FF4304"
|
||||
text: qsTr("Start daemon (%1)").arg(countDown)
|
||||
KeyNavigation.tab: cancelButton
|
||||
onClicked: {
|
||||
@@ -116,10 +121,6 @@ Window {
|
||||
MoneroComponents.StandardButton {
|
||||
id: cancelButton
|
||||
fontSize: 14
|
||||
shadowReleasedColor: "#FF4304"
|
||||
shadowPressedColor: "#B32D00"
|
||||
releasedColor: "#FF6C3C"
|
||||
pressedColor: "#FF4304"
|
||||
text: qsTr("Use custom settings")
|
||||
|
||||
onClicked: {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -216,7 +216,7 @@ ListView {
|
||||
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>Send to this address</b>"; icon: "../images/dropdownSend.png" }
|
||||
ListElement { name: "<b>Find similar transactions</b>"; icon: "../images/dropdownSearch.png" }
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -30,17 +30,21 @@ import QtQuick 2.2
|
||||
import QtQuick.Controls 1.2
|
||||
import QtQuick.Controls.Styles 1.2
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: datePicker
|
||||
property bool expanded: false
|
||||
property date currentDate
|
||||
property bool showCurrentDate: true
|
||||
property color backgroundColor : "#FFFFFF"
|
||||
property color errorColor : "#FFDDDD"
|
||||
property color backgroundColor : "#404040"
|
||||
property color errorColor : "red"
|
||||
property bool error: false
|
||||
property alias inputLabel: inputLabel
|
||||
|
||||
height: 37
|
||||
width: 156
|
||||
signal dateChanged();
|
||||
|
||||
height: 50
|
||||
|
||||
onExpandedChanged: if(expanded) appWindow.currentItem = datePicker
|
||||
|
||||
@@ -57,28 +61,49 @@ Item {
|
||||
return true
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: inputLabelRect
|
||||
color: "transparent"
|
||||
height: 22
|
||||
width: parent.width
|
||||
|
||||
Text {
|
||||
id: inputLabel
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 2
|
||||
anchors.left: parent.left
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
font.pixelSize: 14
|
||||
font.bold: false
|
||||
textFormat: Text.RichText
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
acceptedButtons: Qt.NoButton
|
||||
cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.ArrowCursor
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Item {
|
||||
id: head
|
||||
anchors.fill: parent
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: parent.height
|
||||
//radius: 4
|
||||
y: 0
|
||||
color: "#DBDBDB"
|
||||
|
||||
}
|
||||
anchors.top: inputLabelRect.bottom
|
||||
anchors.topMargin: 6 * scaleRatio
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: 28
|
||||
|
||||
Rectangle {
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: parent.height - 1
|
||||
anchors.leftMargin: datePicker.expanded ? 1 : 0
|
||||
anchors.rightMargin: datePicker.expanded ? 1 : 0
|
||||
//radius: 4
|
||||
radius: 4
|
||||
y: 1
|
||||
color: datePicker.error ? datePicker.errorColor : datePicker.backgroundColor
|
||||
color: datePicker.backgroundColor
|
||||
}
|
||||
|
||||
Item {
|
||||
@@ -89,28 +114,18 @@ Item {
|
||||
anchors.margins: 4
|
||||
width: height
|
||||
|
||||
StandardButton {
|
||||
id: button
|
||||
anchors.fill: parent
|
||||
shadowReleasedColor: "#DBDBDB"
|
||||
shadowPressedColor: "#888888"
|
||||
releasedColor: "#F0EEEE"
|
||||
pressedColor: "#DBDBDB"
|
||||
icon: "../images/datePicker.png"
|
||||
visible: !datePicker.expanded
|
||||
onClicked: datePicker.expanded = true
|
||||
}
|
||||
|
||||
Image {
|
||||
id: button
|
||||
anchors.centerIn: parent
|
||||
source: "../images/datePicker.png"
|
||||
visible: datePicker.expanded
|
||||
source: "../images/whiteDropIndicator.png"
|
||||
rotation: datePicker.expanded ? 180 : 0
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
enabled: datePicker.expanded
|
||||
onClicked: datePicker.expanded = false
|
||||
onClicked: datePicker.expanded = !datePicker.expanded
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
}
|
||||
}
|
||||
|
||||
@@ -121,7 +136,7 @@ Item {
|
||||
anchors.rightMargin: 4
|
||||
height: 16
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
color: "#808080"
|
||||
visible: datePicker.expanded
|
||||
}
|
||||
|
||||
@@ -150,9 +165,9 @@ Item {
|
||||
id: dayInput
|
||||
readOnly: true
|
||||
width: 22
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
// color: "#525252"
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14
|
||||
color: datePicker.error ? errorColor : MoneroComponents.Style.defaultFontColor
|
||||
maximumLength: 2
|
||||
horizontalAlignment: TextInput.AlignHCenter
|
||||
validator: IntValidator{bottom: 01; top: 31;}
|
||||
@@ -173,19 +188,19 @@ Item {
|
||||
}
|
||||
|
||||
Text {
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
// color: "#525252"
|
||||
text: "."
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14
|
||||
color: datePicker.error ? errorColor : MoneroComponents.Style.defaultFontColor
|
||||
text: "-"
|
||||
}
|
||||
|
||||
TextInput {
|
||||
id: monthInput
|
||||
readOnly: true
|
||||
width: 22
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
// color: "#525252"
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14
|
||||
color: datePicker.error ? errorColor : MoneroComponents.Style.defaultFontColor
|
||||
maximumLength: 2
|
||||
horizontalAlignment: TextInput.AlignHCenter
|
||||
validator: IntValidator{bottom: 01; top: 12;}
|
||||
@@ -205,18 +220,18 @@ Item {
|
||||
}
|
||||
|
||||
Text {
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
// color: "#525252"
|
||||
text: "."
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14
|
||||
color: datePicker.error ? errorColor : MoneroComponents.Style.defaultFontColor
|
||||
text: "-"
|
||||
}
|
||||
|
||||
TextInput {
|
||||
id: yearInput
|
||||
width: 44
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
/// color: "#525252"
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14
|
||||
color: datePicker.error ? errorColor : MoneroComponents.Style.defaultFontColor
|
||||
maximumLength: 4
|
||||
horizontalAlignment: TextInput.AlignHCenter
|
||||
validator: IntValidator{bottom: 1000; top: 9999;}
|
||||
@@ -272,6 +287,7 @@ Item {
|
||||
gridVisible: false
|
||||
background: Rectangle { color: "transparent" }
|
||||
dayDelegate: Item {
|
||||
z: parent.z + 1
|
||||
implicitHeight: implicitWidth
|
||||
implicitWidth: calendar.width / 7
|
||||
|
||||
@@ -308,6 +324,8 @@ Item {
|
||||
calendar.showNextMonth()
|
||||
else calendar.showPreviousMonth()
|
||||
}
|
||||
|
||||
dateChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -30,6 +30,8 @@ import QtQuick 2.0
|
||||
import moneroComponents.Clipboard 1.0
|
||||
import moneroComponents.AddressBookModel 1.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import "../js/TxUtils.js" as TxUtils
|
||||
|
||||
ListView {
|
||||
id: listView
|
||||
@@ -39,7 +41,7 @@ ListView {
|
||||
property int rowSpacing: 12
|
||||
property var addressBookModel: null
|
||||
|
||||
function buildTxDetailsString(tx_id, paymentId, tx_key,tx_note, destinations) {
|
||||
function buildTxDetailsString(tx_id, paymentId, tx_key,tx_note, destinations, rings) {
|
||||
var trStart = '<tr><td width="85" style="padding-top:5px"><b>',
|
||||
trMiddle = '</b></td><td style="padding-left:10px;padding-top:5px;">',
|
||||
trEnd = "</td></tr>";
|
||||
@@ -50,6 +52,7 @@ ListView {
|
||||
+ (tx_key ? trStart + qsTr("Tx key:") + trMiddle + tx_key + trEnd : "")
|
||||
+ (tx_note ? trStart + qsTr("Tx note:") + trMiddle + tx_note + trEnd : "")
|
||||
+ (destinations ? trStart + qsTr("Destinations:") + trMiddle + destinations + trEnd : "")
|
||||
+ (rings ? trStart + qsTr("Rings:") + trMiddle + rings + trEnd : "")
|
||||
+ "</table>"
|
||||
+ translationManager.emptyString;
|
||||
}
|
||||
@@ -64,11 +67,10 @@ ListView {
|
||||
return addressBookModel.data(idx, AddressBookModel.AddressBookDescriptionRole)
|
||||
}
|
||||
|
||||
|
||||
footer: Rectangle {
|
||||
height: 127
|
||||
height: 127 * scaleRatio
|
||||
width: listView.width
|
||||
color: "#FFFFFF"
|
||||
color: "transparent"
|
||||
|
||||
Text {
|
||||
anchors.centerIn: parent
|
||||
@@ -79,372 +81,403 @@ ListView {
|
||||
}
|
||||
}
|
||||
|
||||
StandardDialog {
|
||||
id: detailsPopup
|
||||
cancelVisible: false
|
||||
okVisible: true
|
||||
width:850
|
||||
}
|
||||
|
||||
|
||||
delegate: Rectangle {
|
||||
id: delegate
|
||||
height: 144
|
||||
property bool collapsed: index ? false : true
|
||||
height: collapsed ? 180 * scaleRatio : 70 * scaleRatio
|
||||
width: listView.width
|
||||
color: index % 2 ? "#F8F8F8" : "#FFFFFF"
|
||||
z: listView.count - index
|
||||
function collapseDropdown() { dropdown.expanded = false }
|
||||
color: "transparent"
|
||||
|
||||
StandardButton {
|
||||
id: detailsButton
|
||||
anchors.right:parent.right
|
||||
anchors.rightMargin: 15
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: parent.height/2 - this.height/2
|
||||
width: 80
|
||||
fontSize: 14
|
||||
shadowReleasedColor: "#FF4304"
|
||||
shadowPressedColor: "#B32D00"
|
||||
releasedColor: "#FF6C3C"
|
||||
pressedColor: "#FF4304"
|
||||
text: qsTr("Details")
|
||||
onClicked: {
|
||||
var tx_key = currentWallet.getTxKey(hash)
|
||||
var tx_note = currentWallet.getUserNote(hash)
|
||||
detailsPopup.title = "Transaction details";
|
||||
detailsPopup.content = buildTxDetailsString(hash,paymentId,tx_key,tx_note,destinations);
|
||||
detailsPopup.open();
|
||||
|
||||
}
|
||||
function collapse(){
|
||||
delegate.height = 180 * scaleRatio;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Row {
|
||||
id: row1
|
||||
anchors.left: parent.left
|
||||
// borders
|
||||
Rectangle{
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 14
|
||||
// -- direction indicator
|
||||
Rectangle {
|
||||
id: dot
|
||||
width: 14
|
||||
height: width
|
||||
radius: width / 2
|
||||
color: isOut ? "#FF4F41" : "#36B05B"
|
||||
}
|
||||
|
||||
Item { //separator
|
||||
width: 12
|
||||
height: 14
|
||||
}
|
||||
|
||||
// -- description aka recepient name from address book (TODO)
|
||||
/*
|
||||
Text {
|
||||
id: descriptionText
|
||||
width: text.length ? (descriptionArea.containsMouse ? parent.width - x - 12 : 120) : 0
|
||||
anchors.verticalCenter: dot.verticalCenter
|
||||
font.family: "Arial"
|
||||
font.bold: true
|
||||
font.pixelSize: 19
|
||||
color: "#444444"
|
||||
elide: Text.ElideRight
|
||||
text: description
|
||||
|
||||
MouseArea {
|
||||
id: descriptionArea
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
}
|
||||
}
|
||||
*/
|
||||
/*
|
||||
Item { //separator
|
||||
width: descriptionText.width ? 12 : 0
|
||||
height: 14
|
||||
visible: !descriptionArea.containsMouse
|
||||
}
|
||||
*/
|
||||
// -- address (in case outgoing transaction) - N/A in case of incoming
|
||||
TextEdit {
|
||||
id: addressText
|
||||
readOnly: true
|
||||
selectByMouse: true
|
||||
anchors.verticalCenter: dot.verticalCenter
|
||||
width: parent.width - x - 12
|
||||
//elide: Text.ElideRight
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 14
|
||||
color: "#545454"
|
||||
text: hash
|
||||
// visible: !descriptionArea.containsMouse
|
||||
}
|
||||
anchors.bottom: parent.bottom
|
||||
width: 1
|
||||
color: "#404040"
|
||||
}
|
||||
|
||||
Row {
|
||||
// - Payment ID
|
||||
id: row2
|
||||
Rectangle{
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 40
|
||||
anchors.leftMargin: 26
|
||||
|
||||
// -- "PaymentID" title
|
||||
Text {
|
||||
id: paymentLabel
|
||||
width: 86
|
||||
anchors.bottom: parent.bottom
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#535353"
|
||||
text: paymentId !== "" ? qsTr("Payment ID:") + translationManager.emptyString : ""
|
||||
}
|
||||
// -- "PaymentID" value
|
||||
TextEdit {
|
||||
readOnly: true
|
||||
selectByMouse: true
|
||||
id: paymentIdValue
|
||||
width: 136
|
||||
anchors.bottom: parent.bottom
|
||||
//elide: Text.ElideRight
|
||||
font.family: "Arial"
|
||||
font.pixelSize:13
|
||||
color: "#545454"
|
||||
text: paymentId
|
||||
|
||||
}
|
||||
// Address book lookup
|
||||
TextEdit {
|
||||
readOnly: true
|
||||
selectByMouse: true
|
||||
id: addressBookLookupValue
|
||||
width: 136
|
||||
anchors.bottom: parent.bottom
|
||||
//elide: Text.ElideRight
|
||||
font.family: "Arial"
|
||||
font.pixelSize:13
|
||||
color: "#545454"
|
||||
text: "(" + lookupPaymentID(paymentId) + ")"
|
||||
visible: text !== "()"
|
||||
}
|
||||
anchors.bottom: parent.bottom
|
||||
width: collapsed ? 2 : 1
|
||||
color: collapsed ? "#BBBBBB" : "#404040"
|
||||
}
|
||||
Row {
|
||||
// block height row
|
||||
id: row3
|
||||
anchors.left: parent.left
|
||||
|
||||
Rectangle{
|
||||
anchors.right: parent.right
|
||||
anchors.top: row2.bottom
|
||||
anchors.topMargin: rowSpacing
|
||||
anchors.leftMargin: 26
|
||||
|
||||
// -- "BlockHeight" title
|
||||
Text {
|
||||
id: blockHeghtTitle
|
||||
anchors.bottom: parent.bottom
|
||||
width: 86
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#535353"
|
||||
text: qsTr("BlockHeight:") + translationManager.emptyString
|
||||
}
|
||||
// -- "BlockHeight" value
|
||||
TextEdit {
|
||||
readOnly: true
|
||||
selectByMouse: true
|
||||
width: 85
|
||||
anchors.bottom: parent.bottom
|
||||
//elide: Text.ElideRight
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 13
|
||||
color: (confirmations < 10)? "#FF6C3C" : "#545454"
|
||||
text: {
|
||||
if (!isPending)
|
||||
if(confirmations < 10)
|
||||
return blockHeight + " " + qsTr("(%1/10 confirmations)").arg(confirmations)
|
||||
else
|
||||
return blockHeight
|
||||
if (!isOut)
|
||||
return qsTr("UNCONFIRMED") + translationManager.emptyString
|
||||
return qsTr("PENDING") + translationManager.emptyString
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// -- "Date", "Balance" and "Amound" section
|
||||
Row {
|
||||
id: row4
|
||||
anchors.top: row3.bottom
|
||||
anchors.bottom: parent.top
|
||||
anchors.left: parent.left
|
||||
spacing: 12
|
||||
anchors.topMargin: rowSpacing
|
||||
|
||||
Item { //separator
|
||||
width: 14
|
||||
height: 14
|
||||
}
|
||||
|
||||
// -- "Date" column
|
||||
Column {
|
||||
anchors.top: parent.top
|
||||
width: 215
|
||||
|
||||
Text {
|
||||
anchors.left: parent.left
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#545454"
|
||||
text: qsTr("Date") + translationManager.emptyString
|
||||
}
|
||||
|
||||
Row {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
spacing: 33
|
||||
|
||||
Text {
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
color: "#000000"
|
||||
text: date
|
||||
}
|
||||
|
||||
Text {
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
color: "#000000"
|
||||
text: time
|
||||
}
|
||||
}
|
||||
}
|
||||
// -- "Balance" column
|
||||
// XXX: we don't have a balance
|
||||
/*
|
||||
Column {
|
||||
anchors.top: parent.top
|
||||
width: 148
|
||||
visible: false
|
||||
|
||||
Text {
|
||||
anchors.left: parent.left
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#545454"
|
||||
text: qsTr("Balance") + translationManager.emptyString
|
||||
}
|
||||
|
||||
Text {
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
color: "#000000"
|
||||
text: balance
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
// -- "Amount column
|
||||
Column {
|
||||
anchors.top: parent.top
|
||||
|
||||
Text {
|
||||
anchors.left: parent.left
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#545454"
|
||||
text: qsTr("Amount") + translationManager.emptyString
|
||||
}
|
||||
|
||||
Row {
|
||||
spacing: 2
|
||||
Text {
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.bottomMargin: 3
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 16
|
||||
color: isOut ? "#FF4F41" : "#36B05B"
|
||||
text: isOut ? "↓" : "↑"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: amountText
|
||||
anchors.bottom: parent.bottom
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
color: isOut ? "#FF4F41" : "#36B05B"
|
||||
text: displayAmount
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// -- "Fee column
|
||||
Column {
|
||||
anchors.top: parent.top
|
||||
width: 148
|
||||
visible: isOut
|
||||
Text {
|
||||
anchors.left: parent.left
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#545454"
|
||||
text: qsTr("Fee") + translationManager.emptyString
|
||||
}
|
||||
|
||||
Row {
|
||||
spacing: 2
|
||||
Text {
|
||||
anchors.bottom: parent.bottom
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
color: "#FF4F41"
|
||||
text: fee
|
||||
}
|
||||
}
|
||||
}
|
||||
height: 1
|
||||
color: "#404040"
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
// Transaction dropdown menu.
|
||||
// Disable for now until AddressBook implemented
|
||||
TableDropdown {
|
||||
id: dropdown
|
||||
Rectangle{
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.bottomMargin: 11
|
||||
anchors.rightMargin: 5
|
||||
dataModel: dropModel
|
||||
z: 1
|
||||
onExpandedChanged: {
|
||||
if(expanded) {
|
||||
listView.previousItem = delegate
|
||||
listView.currentIndex = index
|
||||
}
|
||||
anchors.left: parent.left
|
||||
height: 1
|
||||
color: "#404040"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: row1
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 20 * scaleRatio
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 20 * scaleRatio
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 15 * scaleRatio
|
||||
height: 40 * scaleRatio
|
||||
color: "transparent"
|
||||
|
||||
Image {
|
||||
id: arrowImage
|
||||
source: isOut ? "../images/downArrow.png" : "../images/upArrow-green.png"
|
||||
height: 18 * scaleRatio
|
||||
width: 12 * scaleRatio
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 12 * scaleRatio
|
||||
}
|
||||
onOptionClicked: {
|
||||
if(option === 0)
|
||||
clipboard.setText(address)
|
||||
|
||||
Text {
|
||||
id: txrxLabel
|
||||
anchors.left: arrowImage.right
|
||||
anchors.leftMargin: 18 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
text: isOut ? "Sent" : "Received"
|
||||
color: "#808080"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: amountLabel
|
||||
anchors.left: arrowImage.right
|
||||
anchors.leftMargin: 18 * scaleRatio
|
||||
anchors.top: txrxLabel.bottom
|
||||
anchors.topMargin: 0 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontBold.name
|
||||
font.pixelSize: 18 * scaleRatio
|
||||
font.bold: true
|
||||
text: {
|
||||
var _amount = amount;
|
||||
if(_amount === 0){
|
||||
// *sometimes* amount is 0, while the 'destinations string'
|
||||
// has the correct amount, so we try to fetch it from that instead.
|
||||
_amount = TxUtils.destinationsToAmount(destinations);
|
||||
_amount = (_amount *1);
|
||||
}
|
||||
|
||||
return _amount + " XMR";
|
||||
}
|
||||
color: isOut ? "white" : "#2eb358"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.right: parent.right
|
||||
width: 300 * scaleRatio
|
||||
height: parent.height
|
||||
color: "transparent"
|
||||
|
||||
Text {
|
||||
id: dateLabel
|
||||
anchors.left: parent.left
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
text: date
|
||||
color: "#808080"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: timeLabel
|
||||
anchors.left: dateLabel.right
|
||||
anchors.leftMargin: 7 * scaleRatio
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 3 * scaleRatio
|
||||
font.pixelSize: 12 * scaleRatio
|
||||
text: time
|
||||
color: "#808080"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: toLabel
|
||||
property string address: ""
|
||||
color: "#BBBBBB"
|
||||
anchors.left: parent.left
|
||||
anchors.top: dateLabel.bottom
|
||||
anchors.topMargin: 0
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 16 * scaleRatio
|
||||
text: {
|
||||
if(isOut){
|
||||
address = TxUtils.destinationsToAddress(destinations);
|
||||
if(address){
|
||||
var truncated = TxUtils.addressTruncate(address);
|
||||
return "To " + truncated;
|
||||
} else {
|
||||
return "Unknown recipient";
|
||||
}
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
MouseArea{
|
||||
visible: parent.address !== undefined
|
||||
hoverEnabled: true
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onEntered: {
|
||||
toLabel.color = "white";
|
||||
}
|
||||
onExited: {
|
||||
toLabel.color = "#BBBBBB";
|
||||
}
|
||||
onClicked: {
|
||||
if(parent.address){
|
||||
console.log("Address copied to clipboard");
|
||||
clipboard.setText(parent.address);
|
||||
appWindow.showStatusMessage(qsTr("Address copied to clipboard"),3)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
height: 24 * scaleRatio
|
||||
width: 24 * scaleRatio
|
||||
color: "transparent"
|
||||
anchors.right: parent.right
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
|
||||
Image {
|
||||
id: dropdownImage
|
||||
height: 8 * scaleRatio
|
||||
width: 12 * scaleRatio
|
||||
source: "../images/whiteDropIndicator.png"
|
||||
rotation: delegate.collapsed ? 180 : 0
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
}
|
||||
|
||||
MouseArea{
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
delegate.collapsed = !delegate.collapsed;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: row2
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 20 * scaleRatio
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
*/
|
||||
}
|
||||
anchors.rightMargin: 20 * scaleRatio
|
||||
anchors.top: row1.bottom
|
||||
anchors.topMargin: 15 * scaleRatio
|
||||
height: 40 * scaleRatio
|
||||
color: "transparent"
|
||||
visible: delegate.collapsed
|
||||
|
||||
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" }
|
||||
// left column
|
||||
MoneroComponents.HistoryTableInnerColumn{
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 30 * scaleRatio
|
||||
|
||||
labelHeader: "Transaction ID"
|
||||
labelValue: hash.substring(0, 18) + "..."
|
||||
copyValue: hash
|
||||
}
|
||||
|
||||
// right column
|
||||
MoneroComponents.HistoryTableInnerColumn{
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 100 * scaleRatio
|
||||
width: 200 * scaleRatio
|
||||
height: parent.height
|
||||
color: "transparent"
|
||||
|
||||
labelHeader: qsTr("Fee")
|
||||
labelValue: {
|
||||
if(!isOut && !fee){
|
||||
return "-";
|
||||
} else if(isOut && fee){
|
||||
return fee + " XMR";
|
||||
} else {
|
||||
return "Unknown"
|
||||
}
|
||||
}
|
||||
copyValue: {
|
||||
if(isOut && fee){ return fee }
|
||||
else { return "" }
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: row3
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 20 * scaleRatio
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 20 * scaleRatio
|
||||
anchors.top: row2.bottom
|
||||
anchors.topMargin: 15 * scaleRatio
|
||||
height: 40 * scaleRatio
|
||||
color: "transparent"
|
||||
visible: delegate.collapsed
|
||||
|
||||
// left column
|
||||
MoneroComponents.HistoryTableInnerColumn{
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 30 * scaleRatio
|
||||
labelHeader: qsTr("Blockheight")
|
||||
labelValue: {
|
||||
if (!isPending)
|
||||
if(confirmations < confirmationsRequired)
|
||||
return blockHeight + " " + qsTr("(%1/%2 confirmations)").arg(confirmations).arg(confirmationsRequired);
|
||||
else
|
||||
return blockHeight;
|
||||
if (!isOut)
|
||||
return qsTr("UNCONFIRMED") + translationManager.emptyString
|
||||
if (isFailed)
|
||||
return qsTr("FAILED") + translationManager.emptyString
|
||||
return qsTr("PENDING") + translationManager.emptyString
|
||||
}
|
||||
copyValue: labelValue
|
||||
}
|
||||
|
||||
// right column
|
||||
MoneroComponents.HistoryTableInnerColumn {
|
||||
visible: currentWallet.getUserNote(hash)
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 80 * scaleRatio
|
||||
width: 220 * scaleRatio
|
||||
height: parent.height
|
||||
color: "transparent"
|
||||
|
||||
labelHeader: qsTr("Description")
|
||||
labelValue: {
|
||||
var note = currentWallet.getUserNote(hash);
|
||||
if(note){
|
||||
if(note.length > 28) {
|
||||
return note.substring(0, 28) + "...";
|
||||
} else {
|
||||
return note;
|
||||
}
|
||||
} else {
|
||||
return "";
|
||||
}
|
||||
}
|
||||
copyValue: {
|
||||
return currentWallet.getUserNote(hash);
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: proofButton
|
||||
visible: isOut
|
||||
color: "#404040"
|
||||
height: 24 * scaleRatio
|
||||
width: 24 * scaleRatio
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.bottomMargin: 36
|
||||
radius: 20 * scaleRatio
|
||||
|
||||
MouseArea {
|
||||
id: proofButtonMouseArea
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
var address = TxUtils.destinationsToAddress(destinations);
|
||||
if(address === undefined){
|
||||
console.log('getProof: Error fetching address')
|
||||
return;
|
||||
}
|
||||
|
||||
var checked = (TxUtils.checkTxID(hash) && TxUtils.checkAddress(address, appWindow.persistentSettings.nettype));
|
||||
if(!checked){
|
||||
console.log('getProof: Error checking TxId and/or address');
|
||||
}
|
||||
|
||||
console.log("getProof: Generate clicked: txid " + hash + ", address " + address);
|
||||
root.getProofClicked(hash, address, '');
|
||||
}
|
||||
|
||||
onEntered: {
|
||||
proofButton.color = "#656565";
|
||||
}
|
||||
|
||||
onExited: {
|
||||
proofButton.color = "#404040";
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
text: "P"
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: detailsButton
|
||||
color: "#404040"
|
||||
height: 24 * scaleRatio
|
||||
width: 24 * scaleRatio
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.bottomMargin: 6
|
||||
radius: 20 * scaleRatio
|
||||
|
||||
MouseArea {
|
||||
id: detailsButtonMouseArea
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
var tx_key = currentWallet.getTxKey(hash)
|
||||
var tx_note = currentWallet.getUserNote(hash)
|
||||
var rings = currentWallet.getRings(hash)
|
||||
if (rings)
|
||||
rings = rings.replace(/\|/g, '\n')
|
||||
informationPopup.title = "Transaction details";
|
||||
informationPopup.content = buildTxDetailsString(hash,paymentId,tx_key,tx_note,destinations, rings);
|
||||
informationPopup.onCloseCallback = null
|
||||
informationPopup.open();
|
||||
}
|
||||
|
||||
onEntered: {
|
||||
detailsButton.color = "#656565";
|
||||
}
|
||||
|
||||
onExited: {
|
||||
detailsButton.color = "#404040";
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
text: "?"
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Clipboard { id: clipboard }
|
||||
|
||||
91
components/HistoryTableInnerColumn.qml
Normal file
@@ -0,0 +1,91 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import moneroComponents.Clipboard 1.0
|
||||
import moneroComponents.PendingTransaction 1.0
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
|
||||
Rectangle{
|
||||
Clipboard { id: clipboard }
|
||||
|
||||
width: label1.width > label2.width ? label1.width : label2.width
|
||||
height: label1.height + label2.height
|
||||
color: "transparent"
|
||||
|
||||
property string copyValue: ""
|
||||
property alias labelHeader: label1.text
|
||||
property alias labelValue: label2.text
|
||||
|
||||
Text {
|
||||
id: label1
|
||||
anchors.left: parent.left
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
text: labelHeader
|
||||
color: MoneroComponents.Style.dimmedFontColor
|
||||
}
|
||||
|
||||
Text {
|
||||
id: label2
|
||||
anchors.left: parent.left
|
||||
anchors.top: label1.bottom
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
text: labelValue
|
||||
color: MoneroComponents.Style.dimmedFontColor
|
||||
}
|
||||
|
||||
// hover effect / copy value
|
||||
MouseArea {
|
||||
visible: copyValue !== ""
|
||||
hoverEnabled: true
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onEntered: {
|
||||
label1.color = MoneroComponents.Style.defaultFontColor;
|
||||
label2.color = MoneroComponents.Style.defaultFontColor;
|
||||
}
|
||||
onExited: {
|
||||
label1.color = MoneroComponents.Style.dimmedFontColor
|
||||
label2.color = MoneroComponents.Style.dimmedFontColor;
|
||||
}
|
||||
onClicked: {
|
||||
if(copyValue){
|
||||
console.log("Copied to clipboard");
|
||||
clipboard.setText(copyValue);
|
||||
appWindow.showStatusMessage(qsTr("Copied to clipboard"),3)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
222
components/HistoryTableMobile.qml
Normal file
@@ -0,0 +1,222 @@
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
import moneroComponents.Clipboard 1.0
|
||||
import moneroComponents.AddressBookModel 1.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
ListView {
|
||||
id: listView
|
||||
clip: true
|
||||
boundsBehavior: ListView.StopAtBounds
|
||||
property var previousItem
|
||||
property var addressBookModel: null
|
||||
|
||||
function buildTxDetailsString(tx_id, paymentId, tx_key,tx_note, destinations, rings) {
|
||||
var trStart = '<tr><td width="85" style="padding-top:5px"><b>',
|
||||
trMiddle = '</b></td><td style="padding-left:10px;padding-top:5px;">',
|
||||
trEnd = "</td></tr>";
|
||||
|
||||
return '<table border="0">'
|
||||
+ (tx_id ? trStart + qsTr("Tx ID:") + trMiddle + tx_id + trEnd : "")
|
||||
+ (paymentId ? trStart + qsTr("Payment ID:") + trMiddle + paymentId + trEnd : "")
|
||||
+ (tx_key ? trStart + qsTr("Tx key:") + trMiddle + tx_key + trEnd : "")
|
||||
+ (tx_note ? trStart + qsTr("Tx note:") + trMiddle + tx_note + trEnd : "")
|
||||
+ (destinations ? trStart + qsTr("Destinations:") + trMiddle + destinations + trEnd : "")
|
||||
+ (rings ? trStart + qsTr("Rings:") + trMiddle + rings + trEnd : "")
|
||||
+ "</table>"
|
||||
+ translationManager.emptyString;
|
||||
}
|
||||
|
||||
function lookupPaymentID(paymentId) {
|
||||
if (!addressBookModel)
|
||||
return ""
|
||||
var idx = addressBookModel.lookupPaymentID(paymentId)
|
||||
if (idx < 0)
|
||||
return ""
|
||||
idx = addressBookModel.index(idx, 0)
|
||||
return addressBookModel.data(idx, AddressBookModel.AddressBookDescriptionRole)
|
||||
}
|
||||
|
||||
|
||||
footer: Rectangle {
|
||||
height: 127 * scaleRatio
|
||||
width: listView.width
|
||||
color: "transparent"
|
||||
|
||||
Text {
|
||||
anchors.centerIn: parent
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: "#545454"
|
||||
text: qsTr("No more results") + translationManager.emptyString
|
||||
}
|
||||
}
|
||||
|
||||
delegate: Rectangle {
|
||||
id: delegate
|
||||
height: tableContent.height + 20 * scaleRatio
|
||||
width: listView.width
|
||||
color: "transparent"
|
||||
Layout.leftMargin: 10 * scaleRatio
|
||||
z: listView.count - index
|
||||
function collapseDropdown() { dropdown.expanded = false }
|
||||
|
||||
Rectangle{
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
width: 1
|
||||
color: "#404040"
|
||||
}
|
||||
|
||||
Rectangle{
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.top: parent.top
|
||||
width: 1
|
||||
color: "#404040"
|
||||
}
|
||||
|
||||
Rectangle{
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.left: parent.left
|
||||
height: 1
|
||||
color: "#404040"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: {
|
||||
var tx_key = currentWallet.getTxKey(hash)
|
||||
var tx_note = currentWallet.getUserNote(hash)
|
||||
var rings = currentWallet.getRings(hash)
|
||||
if (rings)
|
||||
rings = rings.replace(/\|/g, '\n')
|
||||
informationPopup.title = "Transaction details";
|
||||
informationPopup.text = buildTxDetailsString(hash,paymentId,tx_key,tx_note,destinations, rings);
|
||||
informationPopup.open();
|
||||
informationPopup.onCloseCallback = null
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 15 * scaleRatio
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: parent.height/2 - this.height/2
|
||||
width: 30 * scaleRatio; height: 30 * scaleRatio
|
||||
radius: 25
|
||||
color: "#404040"
|
||||
|
||||
Image {
|
||||
width: 20 * scaleRatio
|
||||
height: 20 * scaleRatio
|
||||
fillMode: Image.PreserveAspectFit
|
||||
anchors.centerIn: parent
|
||||
source: "qrc:///images/nextPage.png"
|
||||
}
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
id: tableContent
|
||||
// Date
|
||||
RowLayout {
|
||||
Layout.topMargin: 20 * scaleRatio
|
||||
Layout.leftMargin: 10 * scaleRatio
|
||||
Text {
|
||||
font.family: MoneroComponents.Style.fontMedium.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
text: date
|
||||
}
|
||||
|
||||
Text {
|
||||
font.family: Style.fontRegular.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: MoneroComponents.Style.dimmedFontColor
|
||||
text: time
|
||||
}
|
||||
|
||||
// Show confirmations
|
||||
Text {
|
||||
visible: confirmations < confirmationsRequired || isPending
|
||||
Layout.leftMargin: 5 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: (confirmations < confirmationsRequired)? "#FF6C3C" : "#545454"
|
||||
text: {
|
||||
if (!isPending)
|
||||
if(confirmations < confirmationsRequired)
|
||||
return qsTr("(%1/%2 confirmations)").arg(confirmations).arg(confirmationsRequired)
|
||||
if (!isOut)
|
||||
return qsTr("UNCONFIRMED") + translationManager.emptyString
|
||||
if (isFailed)
|
||||
return qsTr("FAILED") + translationManager.emptyString
|
||||
return qsTr("PENDING") + translationManager.emptyString
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Amount & confirmations
|
||||
RowLayout {
|
||||
Layout.leftMargin: 10 * scaleRatio
|
||||
spacing: 2
|
||||
Text {
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: isOut ? MoneroComponents.Style.defaultFontColor : "#2eb358"
|
||||
text: isOut ? "↓" : "↑"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: amountText
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18 * scaleRatio
|
||||
color: isOut ? MoneroComponents.Style.defaultFontColor : "#2eb358"
|
||||
text: displayAmount
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
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 this address</b>"; icon: "../images/dropdownSend.png" }
|
||||
ListElement { name: "<b>Find similar transactions</b>"; icon: "../images/dropdownSearch.png" }
|
||||
}
|
||||
|
||||
Clipboard { id: clipboard }
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -30,6 +30,7 @@
|
||||
import QtQuick 2.0
|
||||
|
||||
Item {
|
||||
property alias image : buttonImage
|
||||
property alias imageSource : buttonImage.source
|
||||
|
||||
signal clicked(var mouse)
|
||||
@@ -53,7 +54,8 @@ Item {
|
||||
MouseArea {
|
||||
id: buttonArea
|
||||
anchors.fill: parent
|
||||
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
||||
onPressed: {
|
||||
buttonImage.x = buttonImage.x + 2
|
||||
|
||||
93
components/InlineButton.qml
Normal file
@@ -0,0 +1,93 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: inlineButton
|
||||
height: rect.height * scaleRatio
|
||||
property string shadowPressedColor: "#B32D00"
|
||||
property string shadowReleasedColor: "#FF4304"
|
||||
property string pressedColor: "#FF4304"
|
||||
property string releasedColor: "#FF6C3C"
|
||||
property string icon: ""
|
||||
property string textColor: "#FFFFFF"
|
||||
property int fontSize: 12 * scaleRatio
|
||||
property alias text: inlineText.text
|
||||
signal clicked()
|
||||
|
||||
function doClick() {
|
||||
// Android workaround
|
||||
releaseFocus();
|
||||
clicked();
|
||||
}
|
||||
|
||||
Rectangle{
|
||||
id: rect
|
||||
color: MoneroComponents.Style.buttonBackgroundColorDisabled
|
||||
border.color: "black"
|
||||
height: 28 * scaleRatio
|
||||
width: inlineText.width + 22 * scaleRatio
|
||||
radius: 4
|
||||
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
|
||||
Text {
|
||||
id: inlineText
|
||||
font.family: MoneroComponents.Style.fontBold.name
|
||||
font.bold: true
|
||||
font.pixelSize: 16 * scaleRatio
|
||||
color: "black"
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: buttonArea
|
||||
cursorShape: rect.enabled ? Qt.PointingHandCursor : Qt.ArrowCursor
|
||||
hoverEnabled: true
|
||||
anchors.fill: parent
|
||||
onClicked: doClick()
|
||||
onEntered: {
|
||||
rect.color = "#707070";
|
||||
rect.opacity = 0.8;
|
||||
}
|
||||
onExited: {
|
||||
rect.opacity = 1.0;
|
||||
rect.color = "#808080";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Keys.onSpacePressed: doClick()
|
||||
Keys.onReturnPressed: doClick()
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -26,21 +26,22 @@
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick.Controls 1.2
|
||||
import QtQuick.Controls.Styles 1.2
|
||||
import QtQuick 2.2
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick 2.7
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
TextField {
|
||||
font.family: "Arial"
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 18 * scaleRatio
|
||||
font.bold: true
|
||||
horizontalAlignment: TextInput.AlignLeft
|
||||
selectByMouse: true
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
selectionColor: MoneroComponents.Style.dimmedFontColor
|
||||
selectedTextColor: MoneroComponents.Style.defaultFontColor
|
||||
|
||||
style: TextFieldStyle {
|
||||
textColor: "#3F3F3F"
|
||||
placeholderTextColor: "#BABABA"
|
||||
|
||||
background: Rectangle {
|
||||
border.width: 0
|
||||
color: "transparent"
|
||||
}
|
||||
background: Rectangle {
|
||||
color: "transparent"
|
||||
}
|
||||
}
|
||||
|
||||
160
components/InputDialog.qml
Normal file
@@ -0,0 +1,160 @@
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.7
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Window 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: root
|
||||
visible: false
|
||||
property alias labelText: label.text
|
||||
property alias inputText: input.text
|
||||
|
||||
// same signals as Dialog has
|
||||
signal accepted()
|
||||
signal rejected()
|
||||
|
||||
function open() {
|
||||
inactiveOverlay.visible = true
|
||||
leftPanel.enabled = false
|
||||
middlePanel.enabled = false
|
||||
titleBar.enabled = false
|
||||
show()
|
||||
root.visible = true;
|
||||
input.focus = true;
|
||||
input.text = "";
|
||||
}
|
||||
|
||||
function close() {
|
||||
inactiveOverlay.visible = false
|
||||
leftPanel.enabled = true
|
||||
middlePanel.enabled = true
|
||||
titleBar.enabled = true
|
||||
root.visible = false;
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
z: parent.z + 1
|
||||
id: mainLayout
|
||||
spacing: 10
|
||||
anchors { fill: parent; margins: 35 }
|
||||
|
||||
ColumnLayout {
|
||||
id: column
|
||||
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.maximumWidth: 400 * scaleRatio
|
||||
|
||||
Label {
|
||||
id: label
|
||||
anchors.left: parent.left
|
||||
Layout.fillWidth: true
|
||||
|
||||
font.pixelSize: 16 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
}
|
||||
|
||||
TextField {
|
||||
id : input
|
||||
focus: true
|
||||
Layout.topMargin: 6
|
||||
Layout.fillWidth: true
|
||||
anchors.left: parent.left
|
||||
horizontalAlignment: TextInput.AlignLeft
|
||||
verticalAlignment: TextInput.AlignVCenter
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
font.pixelSize: 24 * scaleRatio
|
||||
KeyNavigation.tab: okButton
|
||||
bottomPadding: 10
|
||||
leftPadding: 10
|
||||
topPadding: 10
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
selectionColor: MoneroComponents.Style.dimmedFontColor
|
||||
selectedTextColor: MoneroComponents.Style.defaultFontColor
|
||||
|
||||
background: Rectangle {
|
||||
radius: 2
|
||||
border.color: Qt.rgba(255, 255, 255, 0.35)
|
||||
border.width: 1
|
||||
color: "black"
|
||||
}
|
||||
|
||||
Keys.onReturnPressed: {
|
||||
root.close()
|
||||
root.accepted()
|
||||
}
|
||||
Keys.onEscapePressed: {
|
||||
root.close()
|
||||
root.rejected()
|
||||
}
|
||||
}
|
||||
|
||||
// Ok/Cancel buttons
|
||||
RowLayout {
|
||||
id: buttons
|
||||
spacing: 16 * scaleRatio
|
||||
Layout.topMargin: 16
|
||||
Layout.alignment: Qt.AlignRight
|
||||
|
||||
MoneroComponents.StandardButton {
|
||||
id: cancelButton
|
||||
small: true
|
||||
width: 120
|
||||
fontSize: 14
|
||||
text: qsTr("Cancel") + translationManager.emptyString
|
||||
KeyNavigation.tab: input
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.rejected()
|
||||
}
|
||||
}
|
||||
MoneroComponents.StandardButton {
|
||||
id: okButton
|
||||
small: true
|
||||
width: 120
|
||||
fontSize: 14
|
||||
text: qsTr("Ok")
|
||||
KeyNavigation.tab: cancelButton
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.accepted()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
64
components/InputMulti.qml
Normal file
@@ -0,0 +1,64 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick 2.7
|
||||
|
||||
import "../js/TxUtils.js" as TxUtils
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
TextArea {
|
||||
property int fontSize: 18 * scaleRatio
|
||||
property bool fontBold: false
|
||||
property string fontColor: MoneroComponents.Style.defaultFontColor
|
||||
|
||||
property bool mouseSelection: true
|
||||
property bool error: false
|
||||
property bool addressValidation: false
|
||||
|
||||
id: textArea
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
color: fontColor
|
||||
font.pixelSize: fontSize
|
||||
font.bold: fontBold
|
||||
horizontalAlignment: TextInput.AlignLeft
|
||||
selectByMouse: mouseSelection
|
||||
selectionColor: MoneroComponents.Style.dimmedFontColor
|
||||
selectedTextColor: MoneroComponents.Style.defaultFontColor
|
||||
|
||||
onTextChanged: {
|
||||
if(addressValidation){
|
||||
// js replacement for `RegExpValidator { regExp: /[0-9A-Fa-f]{95}/g }`
|
||||
textArea.text = textArea.text.replace(/[^a-z0-9.@]/gi,'');
|
||||
var address_ok = TxUtils.checkAddress(textArea.text, appWindow.persistentSettings.nettype);
|
||||
if(!address_ok) error = true;
|
||||
else error = false;
|
||||
TextArea.cursorPosition = textArea.text.length;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -26,7 +26,10 @@
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick 2.5
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: item
|
||||
@@ -34,48 +37,33 @@ Item {
|
||||
property alias color: label.color
|
||||
property alias textFormat: label.textFormat
|
||||
property string tipText: ""
|
||||
property int fontSize: 12
|
||||
property int fontSize: 16 * scaleRatio
|
||||
property bool fontBold: false
|
||||
property string fontColor: MoneroComponents.Style.defaultFontColor
|
||||
property string fontFamily: ""
|
||||
property alias wrapMode: label.wrapMode
|
||||
property alias horizontalAlignment: label.horizontalAlignment
|
||||
property alias hoveredLink: label.hoveredLink
|
||||
signal linkActivated()
|
||||
width: icon.x + icon.width
|
||||
height: icon.height
|
||||
height: label.height * scaleRatio
|
||||
width: label.width * scaleRatio
|
||||
Layout.topMargin: 10 * scaleRatio
|
||||
|
||||
Text {
|
||||
id: label
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.bottomMargin: 2
|
||||
anchors.bottomMargin: 2 * scaleRatio
|
||||
anchors.left: parent.left
|
||||
font.family: "Arial"
|
||||
font.pixelSize: parent.fontSize
|
||||
color: "#555555"
|
||||
font.family: {
|
||||
if(fontFamily){
|
||||
return fontFamily;
|
||||
} else {
|
||||
return MoneroComponents.Style.fontRegular.name;
|
||||
}
|
||||
}
|
||||
font.pixelSize: fontSize
|
||||
font.bold: fontBold
|
||||
color: fontColor
|
||||
onLinkActivated: item.linkActivated()
|
||||
}
|
||||
|
||||
Image {
|
||||
id: icon
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: label.right
|
||||
anchors.leftMargin: 5
|
||||
source: "../images/whatIsIcon.png"
|
||||
visible: appWindow.whatIsEnable
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: icon
|
||||
enabled: appWindow.whatIsEnable
|
||||
hoverEnabled: true
|
||||
onEntered: {
|
||||
icon.visible = false
|
||||
var pos = appWindow.mapFromItem(icon, 0, -15)
|
||||
tipItem.text = item.tipText
|
||||
tipItem.x = pos.x
|
||||
if(tipItem.height > 30)
|
||||
pos.y -= tipItem.height - 28
|
||||
tipItem.y = pos.y
|
||||
tipItem.visible = true
|
||||
}
|
||||
onExited: {
|
||||
icon.visible = Qt.binding(function(){ return appWindow.whatIsEnable; })
|
||||
tipItem.visible = false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
73
components/LabelButton.qml
Normal file
@@ -0,0 +1,73 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
|
||||
Rectangle {
|
||||
signal clicked();
|
||||
property alias text: labelButtonText.text
|
||||
|
||||
id: labelButton
|
||||
color: "#808080"
|
||||
radius: 3
|
||||
height: 20
|
||||
width: labelButtonText.width + 14
|
||||
anchors.right: copyButton.left
|
||||
anchors.rightMargin: 6
|
||||
|
||||
Text {
|
||||
id: labelButtonText
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 12
|
||||
font.bold: true
|
||||
text: ""
|
||||
color: "black"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
onClicked: labelButton.clicked()
|
||||
onEntered: {
|
||||
labelButton.color = "#707070";
|
||||
labelButtonText.opacity = 0.8;
|
||||
}
|
||||
onExited: {
|
||||
labelButton.color = "#808080";
|
||||
labelButtonText.opacity = 1.0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
52
components/LabelSubheader.qml
Normal file
@@ -0,0 +1,52 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Label {
|
||||
id: item
|
||||
fontSize: 18 * scaleRatio
|
||||
|
||||
Rectangle {
|
||||
anchors.top: item.bottom
|
||||
anchors.topMargin: 4
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: 2
|
||||
color: MoneroComponents.Style.dividerColor
|
||||
opacity: MoneroComponents.Style.dividerOpacity
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
acceptedButtons: Qt.NoButton
|
||||
cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.ArrowCursor
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -28,51 +28,191 @@
|
||||
|
||||
import QtQuick 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: item
|
||||
property alias placeholderText: input.placeholderText
|
||||
property alias text: input.text
|
||||
|
||||
property alias placeholderText: placeholderLabel.text
|
||||
property bool placeholderCenter: false
|
||||
property string placeholderFontFamily: MoneroComponents.Style.fontRegular.name
|
||||
property bool placeholderFontBold: false
|
||||
property int placeholderFontSize: 18 * scaleRatio
|
||||
property string placeholderColor: MoneroComponents.Style.defaultFontColor
|
||||
property real placeholderOpacity: 0.35
|
||||
|
||||
property alias validator: input.validator
|
||||
property alias readOnly : input.readOnly
|
||||
property alias cursorPosition: input.cursorPosition
|
||||
property alias echoMode: input.echoMode
|
||||
property int fontSize: 18
|
||||
property alias inlineButton: inlineButtonId
|
||||
property alias inlineButtonText: inlineButtonId.text
|
||||
property alias inlineIcon: inlineIcon.visible
|
||||
property bool copyButton: false
|
||||
|
||||
property bool borderDisabled: false
|
||||
property string borderColor: {
|
||||
if(input.activeFocus){
|
||||
return MoneroComponents.Style.inputBorderColorActive;
|
||||
} else {
|
||||
return MoneroComponents.Style.inputBorderColorInActive;
|
||||
}
|
||||
}
|
||||
|
||||
property int fontSize: 18 * scaleRatio
|
||||
property bool fontBold: false
|
||||
property alias fontColor: input.color
|
||||
property bool error: false
|
||||
signal editingFinished()
|
||||
property alias labelText: inputLabel.text
|
||||
property alias labelColor: inputLabel.color
|
||||
property alias labelTextFormat: inputLabel.textFormat
|
||||
property string backgroundColor: "transparent"
|
||||
property string tipText: ""
|
||||
property int labelFontSize: 16 * scaleRatio
|
||||
property bool labelFontBold: false
|
||||
property alias labelWrapMode: inputLabel.wrapMode
|
||||
property alias labelHorizontalAlignment: inputLabel.horizontalAlignment
|
||||
property bool showingHeader: inputLabel.text !== "" || copyButton
|
||||
property int inputHeight: 42 * scaleRatio
|
||||
|
||||
signal labelLinkActivated(); // input label, rich text <a> signal
|
||||
signal editingFinished();
|
||||
signal accepted();
|
||||
signal textUpdated();
|
||||
|
||||
height: 37
|
||||
height: showingHeader ? (inputLabel.height + inputItem.height + 2) * scaleRatio : 42 * scaleRatio
|
||||
|
||||
function getColor(error) {
|
||||
if (error)
|
||||
return "#FFDDDD"
|
||||
else
|
||||
return "#FFFFFF"
|
||||
onTextUpdated: {
|
||||
// check to remove placeholder text when there is content
|
||||
if(item.isEmpty()){
|
||||
placeholderLabel.visible = true;
|
||||
} else {
|
||||
placeholderLabel.visible = false;
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
anchors.bottomMargin: 1
|
||||
color: "#DBDBDB"
|
||||
//radius: 4
|
||||
function isEmpty(){
|
||||
var val = input.text;
|
||||
if(val === "") {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
anchors.topMargin: 1
|
||||
color: getColor(error)
|
||||
//radius: 4
|
||||
Text {
|
||||
id: inputLabel
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
anchors.topMargin: 2 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
font.pixelSize: labelFontSize
|
||||
font.bold: labelFontBold
|
||||
textFormat: Text.RichText
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
onLinkActivated: item.labelLinkActivated()
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
acceptedButtons: Qt.NoButton
|
||||
cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.ArrowCursor
|
||||
}
|
||||
}
|
||||
|
||||
Input {
|
||||
id: input
|
||||
anchors.fill: parent
|
||||
anchors.leftMargin: 4
|
||||
anchors.rightMargin: 30
|
||||
font.pixelSize: parent.fontSize
|
||||
onEditingFinished: item.editingFinished()
|
||||
onAccepted: item.accepted();
|
||||
onTextChanged: item.textUpdated()
|
||||
MoneroComponents.LabelButton {
|
||||
id: copyButtonId
|
||||
text: qsTr("Copy")
|
||||
anchors.right: parent.right
|
||||
onClicked: {
|
||||
if (input.text.length > 0) {
|
||||
console.log("Copied to clipboard");
|
||||
clipboard.setText(input.text);
|
||||
appWindow.showStatusMessage(qsTr("Copied to clipboard"), 3);
|
||||
}
|
||||
}
|
||||
visible: copyButton && input.text !== ""
|
||||
}
|
||||
|
||||
Item{
|
||||
id: inputItem
|
||||
height: inputHeight * scaleRatio
|
||||
anchors.top: showingHeader ? inputLabel.bottom : parent.top
|
||||
anchors.topMargin: showingHeader ? 12 * scaleRatio : 2 * scaleRatio
|
||||
width: parent.width
|
||||
clip: true
|
||||
|
||||
Text {
|
||||
id: placeholderLabel
|
||||
visible: input.text ? false : true
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.horizontalCenter: placeholderCenter ? parent.horizontalCenter : undefined
|
||||
anchors.left: placeholderCenter ? undefined : parent.left
|
||||
anchors.leftMargin: {
|
||||
if(placeholderCenter){
|
||||
return undefined;
|
||||
}
|
||||
else if(inlineIcon.visible){ return 50 * scaleRatio; }
|
||||
else { return 10 * scaleRatio; }
|
||||
}
|
||||
|
||||
opacity: item.placeholderOpacity
|
||||
color: item.placeholderColor
|
||||
font.family: item.placeholderFontFamily
|
||||
font.pixelSize: placeholderFontSize * scaleRatio
|
||||
font.bold: item.placeholderFontBold
|
||||
text: ""
|
||||
z: 3
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
anchors.topMargin: 1 * scaleRatio
|
||||
color: "transparent"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: inputFill
|
||||
color: backgroundColor
|
||||
anchors.fill: parent
|
||||
border.width: borderDisabled ? 0 : 1
|
||||
border.color: borderColor
|
||||
radius: 4
|
||||
}
|
||||
|
||||
Image {
|
||||
id: inlineIcon
|
||||
width: 26 * scaleRatio
|
||||
height: 26 * scaleRatio
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 8 * scaleRatio
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 12 * scaleRatio
|
||||
source: "../images/moneroIcon-28x28.png"
|
||||
visible: false
|
||||
}
|
||||
|
||||
MoneroComponents.Input {
|
||||
id: input
|
||||
anchors.fill: parent
|
||||
anchors.leftMargin: inlineIcon.visible ? 44 * scaleRatio : 0
|
||||
font.pixelSize: item.fontSize
|
||||
font.bold: item.fontBold
|
||||
onEditingFinished: item.editingFinished()
|
||||
onAccepted: item.accepted();
|
||||
onTextChanged: item.textUpdated()
|
||||
topPadding: 10 * scaleRatio
|
||||
bottomPadding: 10 * scaleRatio
|
||||
}
|
||||
|
||||
MoneroComponents.InlineButton {
|
||||
id: inlineButtonId
|
||||
visible: item.inlineButtonText ? true : false
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 8 * scaleRatio
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 6 * scaleRatio
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
174
components/LineEditMulti.qml
Normal file
@@ -0,0 +1,174 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
ColumnLayout {
|
||||
id: item
|
||||
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: childrenRect.height
|
||||
|
||||
property alias text: input.text
|
||||
property alias labelText: inputLabel.text
|
||||
property alias labelButtonText: labelButton.text
|
||||
property alias placeholderText: placeholderLabel.text
|
||||
|
||||
property bool placeholderCenter: false
|
||||
property string placeholderFontFamily: MoneroComponents.Style.fontRegular.name
|
||||
property bool placeholderFontBold: false
|
||||
property int placeholderFontSize: 18 * scaleRatio
|
||||
property string placeholderColor: MoneroComponents.Style.defaultFontColor
|
||||
property real placeholderOpacity: 0.35
|
||||
|
||||
property bool borderDisabled: false
|
||||
property string borderColor: {
|
||||
if(input.error && input.text !== ""){
|
||||
return MoneroComponents.Style.inputBorderColorInvalid;
|
||||
} else if(input.activeFocus){
|
||||
return MoneroComponents.Style.inputBorderColorActive;
|
||||
} else {
|
||||
return MoneroComponents.Style.inputBorderColorInActive;
|
||||
}
|
||||
}
|
||||
|
||||
property bool error: false
|
||||
|
||||
property string labelFontColor: MoneroComponents.Style.defaultFontColor
|
||||
property bool labelFontBold: false
|
||||
property int labelFontSize: 16 * scaleRatio
|
||||
property bool labelButtonVisible: false
|
||||
|
||||
property string fontColor: "white"
|
||||
property bool fontBold: false
|
||||
property int fontSize: 16 * scaleRatio
|
||||
|
||||
property bool mouseSelection: true
|
||||
property alias readOnly: input.readOnly
|
||||
property bool copyButton: false
|
||||
property bool showingHeader: true
|
||||
property var wrapMode: Text.NoWrap
|
||||
property alias addressValidation: input.addressValidation
|
||||
property string backgroundColor: "" // mock
|
||||
|
||||
signal labelButtonClicked();
|
||||
signal inputLabelLinkActivated();
|
||||
signal editingFinished();
|
||||
|
||||
spacing: 0
|
||||
Rectangle {
|
||||
id: inputLabelRect
|
||||
color: "transparent"
|
||||
Layout.fillWidth: true
|
||||
height: (inputLabel.height + 10) * scaleRatio
|
||||
visible: showingHeader ? true : false
|
||||
|
||||
Text {
|
||||
id: inputLabel
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: item.labelFontSize
|
||||
font.bold: labelFontBold
|
||||
textFormat: Text.RichText
|
||||
color: item.labelFontColor
|
||||
onLinkActivated: inputLabelLinkActivated()
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
acceptedButtons: Qt.NoButton
|
||||
cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.ArrowCursor
|
||||
}
|
||||
}
|
||||
|
||||
MoneroComponents.LabelButton {
|
||||
id: labelButton
|
||||
onClicked: labelButtonClicked()
|
||||
visible: labelButtonVisible
|
||||
}
|
||||
|
||||
MoneroComponents.LabelButton {
|
||||
id: copyButtonId
|
||||
visible: copyButton && input.text !== ""
|
||||
text: qsTr("Copy")
|
||||
anchors.right: labelButton.visible ? inputLabel.right : parent.right
|
||||
anchors.rightMargin: labelButton.visible? 4 : 0
|
||||
onClicked: {
|
||||
if (input.text.length > 0) {
|
||||
console.log("Copied to clipboard");
|
||||
clipboard.setText(input.text);
|
||||
appWindow.showStatusMessage(qsTr("Copied to clipboard"), 3);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
MoneroComponents.InputMulti {
|
||||
id: input
|
||||
readOnly: false
|
||||
addressValidation: false
|
||||
anchors.top: item.showingHeader ? inputLabelRect.bottom : item.top
|
||||
Layout.fillWidth: true
|
||||
topPadding: item.showingHeader ? 10 * scaleRatio : 0
|
||||
bottomPadding: 10 * scaleRatio
|
||||
wrapMode: item.wrapMode
|
||||
fontSize: item.fontSize
|
||||
fontBold: item.fontBold
|
||||
fontColor: item.fontColor
|
||||
mouseSelection: item.mouseSelection
|
||||
onEditingFinished: item.editingFinished()
|
||||
error: item.error
|
||||
|
||||
Text {
|
||||
id: placeholderLabel
|
||||
visible: input.text ? false : true
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 10 * scaleRatio
|
||||
opacity: item.placeholderOpacity
|
||||
color: item.placeholderColor
|
||||
font.family: item.placeholderFontFamily
|
||||
font.bold: item.placeholderFontBold
|
||||
font.pixelSize: item.placeholderFontSize
|
||||
text: ""
|
||||
z: 3
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
color: "transparent"
|
||||
border.width: 1
|
||||
border.color: item.borderColor
|
||||
radius: 4
|
||||
anchors.fill: parent
|
||||
visible: !item.borderDisabled
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -26,7 +26,9 @@
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick 2.5
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Rectangle {
|
||||
id: button
|
||||
@@ -38,31 +40,122 @@ Rectangle {
|
||||
property var under: null
|
||||
signal clicked()
|
||||
|
||||
function doClick() {
|
||||
// Android workaround
|
||||
releaseFocus();
|
||||
clicked();
|
||||
}
|
||||
|
||||
|
||||
function getOffset() {
|
||||
var offset = 0
|
||||
var item = button
|
||||
while (item.under) {
|
||||
offset += 20
|
||||
offset += 20 * scaleRatio
|
||||
item = item.under
|
||||
}
|
||||
return offset
|
||||
}
|
||||
|
||||
color: checked ? "#FFFFFF" : "#1C1C1C"
|
||||
color: "transparent"
|
||||
property bool present: !under || under.checked || checked || under.numSelectedChildren > 0
|
||||
height: present ? ((appWindow.height >= 800) ? 64 : 52) : 0
|
||||
height: present ? ((appWindow.height >= 800) ? 44 * scaleRatio : 38 * scaleRatio ) : 0
|
||||
|
||||
// button gradient while checked
|
||||
Image {
|
||||
height: parent.height
|
||||
width: 260
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: -20
|
||||
anchors.leftMargin: parent.getOffset()
|
||||
source: "../images/menuButtonGradient.png"
|
||||
visible: button.checked
|
||||
}
|
||||
|
||||
// button decorations that are subject to leftMargin offsets
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: parent.getOffset() + 20 * scaleRatio
|
||||
height: parent.height
|
||||
width: button.checked ? 20: 10
|
||||
color: "#00000000"
|
||||
|
||||
// dot if unchecked
|
||||
Rectangle {
|
||||
id: dot
|
||||
anchors.centerIn: parent
|
||||
width: button.checked ? 20 * scaleRatio : 8 * scaleRatio
|
||||
height: button.checked ? 20 * scaleRatio : 8 * scaleRatio
|
||||
radius: button.checked ? 20 * scaleRatio : 4 * scaleRatio
|
||||
color: button.dotColor
|
||||
// arrow if checked
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
anchors.left: parent.left
|
||||
source: "../images/arrow-right-medium-white.png"
|
||||
visible: button.checked
|
||||
}
|
||||
}
|
||||
|
||||
// button text
|
||||
Text {
|
||||
id: label
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.right
|
||||
anchors.leftMargin: 8 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontMedium.name
|
||||
font.bold: true
|
||||
font.pixelSize: 16 * scaleRatio
|
||||
color: "#FFFFFF"
|
||||
}
|
||||
}
|
||||
|
||||
// menu button right arrow
|
||||
Image {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 20 * scaleRatio
|
||||
anchors.leftMargin: parent.getOffset()
|
||||
source: "../images/right.png"
|
||||
opacity: button.checked ? 1.0 : 0.4
|
||||
}
|
||||
|
||||
Text {
|
||||
id: symbolText
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 44 * scaleRatio
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
font.pixelSize: 12 * scaleRatio
|
||||
font.bold: true
|
||||
color: button.checked || buttonArea.containsMouse ? "#FFFFFF" : dot.color
|
||||
visible: appWindow.ctrlPressed
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: buttonArea
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
if(parent.checked)
|
||||
return
|
||||
button.doClick()
|
||||
parent.checked = true
|
||||
}
|
||||
}
|
||||
|
||||
transform: Scale {
|
||||
yScale: button.present ? 1 : 0
|
||||
|
||||
Behavior on yScale {
|
||||
NumberAnimation { duration: 500; easing.type: Easing.InOutCubic }
|
||||
NumberAnimation { duration: 200; easing.type: Easing.OutCubic }
|
||||
}
|
||||
}
|
||||
|
||||
Behavior on height {
|
||||
SequentialAnimation {
|
||||
NumberAnimation { duration: 500; easing.type: Easing.InOutCubic }
|
||||
NumberAnimation { duration: 200; easing.type: Easing.OutCubic }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -70,77 +163,4 @@ Rectangle {
|
||||
// we get the value of checked before the change
|
||||
ScriptAction { script: if (under) under.numSelectedChildren += checked > 0 ? -1 : 1 }
|
||||
}
|
||||
|
||||
Item {
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: parent.getOffset()
|
||||
width: 50
|
||||
|
||||
Rectangle {
|
||||
id: dot
|
||||
anchors.centerIn: parent
|
||||
width: 16
|
||||
height: width
|
||||
radius: height / 2
|
||||
|
||||
Rectangle {
|
||||
anchors.centerIn: parent
|
||||
width: 12
|
||||
height: width
|
||||
radius: height / 2
|
||||
color: "#1C1C1C"
|
||||
visible: !button.checked && !buttonArea.containsMouse
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
id: symbolText
|
||||
anchors.centerIn: parent
|
||||
font.pixelSize: 11
|
||||
font.bold: true
|
||||
color: button.checked || buttonArea.containsMouse ? "#FFFFFF" : dot.color
|
||||
visible: appWindow.ctrlPressed
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
visible: parent.checked
|
||||
}
|
||||
|
||||
Image {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 20
|
||||
anchors.leftMargin: parent.getOffset()
|
||||
source: "../images/menuIndicator.png"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: label
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: parent.getOffset() + 50
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
color: parent.checked ? "#000000" : "#FFFFFF"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: buttonArea
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
onClicked: {
|
||||
if(parent.checked)
|
||||
return
|
||||
button.clicked()
|
||||
parent.checked = true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
118
components/MobileHeader.qml
Normal file
@@ -0,0 +1,118 @@
|
||||
import QtQuick 2.2
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import moneroComponents.Wallet 1.0
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
// BasicPanel header
|
||||
Rectangle {
|
||||
id: header
|
||||
anchors.leftMargin: 1
|
||||
anchors.rightMargin: 1
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: 64 * scaleRatio
|
||||
color: "#FFFFFF"
|
||||
|
||||
Image {
|
||||
id: logo
|
||||
visible: appWindow.width > 460 * scaleRatio
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.verticalCenterOffset: -5
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 50 * scaleRatio
|
||||
source: "../images/moneroLogo2.png"
|
||||
}
|
||||
|
||||
Image {
|
||||
id: icon
|
||||
visible: !logo.visible
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 40 * scaleRatio
|
||||
source: "../images/moneroIcon.png"
|
||||
}
|
||||
|
||||
Grid {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
anchors.topMargin: 10 * scaleRatio
|
||||
width: 256 * scaleRatio
|
||||
columns: 3
|
||||
|
||||
Text {
|
||||
id: balanceLabel
|
||||
width: 116 * scaleRatio
|
||||
height: 20 * scaleRatio
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12 * scaleRatio
|
||||
font.letterSpacing: -1
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#535353"
|
||||
text: leftPanel.balanceLabelText + ":"
|
||||
}
|
||||
|
||||
Text {
|
||||
id: balanceText
|
||||
width: 110 * scaleRatio
|
||||
height: 20 * scaleRatio
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18 * scaleRatio
|
||||
font.letterSpacing: -1
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#000000"
|
||||
text: leftPanel.balanceText
|
||||
}
|
||||
|
||||
Item {
|
||||
height: 20 * scaleRatio
|
||||
width: 20 * scaleRatio
|
||||
|
||||
Image {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
source: "../images/lockIcon.png"
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
width: 116 * scaleRatio
|
||||
height: 20 * scaleRatio
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12 * scaleRatio
|
||||
font.letterSpacing: -1
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#535353"
|
||||
text: qsTr("Unlocked Balance:")
|
||||
}
|
||||
|
||||
Text {
|
||||
id: availableBalanceText
|
||||
width: 110 * scaleRatio
|
||||
height: 20 * scaleRatio
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
font.letterSpacing: -1
|
||||
elide: Text.ElideRight
|
||||
horizontalAlignment: Text.AlignLeft
|
||||
verticalAlignment: Text.AlignBottom
|
||||
color: "#000000"
|
||||
text: leftPanel.unlockedBalanceText
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -27,30 +27,22 @@
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import moneroComponents.Wallet 1.0
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Row {
|
||||
Rectangle {
|
||||
id: item
|
||||
color: "transparent"
|
||||
property var connected: Wallet.ConnectionStatus_Disconnected
|
||||
|
||||
function getConnectionStatusImage(status) {
|
||||
if (status == Wallet.ConnectionStatus_Connected)
|
||||
return "../images/statusConnected.png"
|
||||
else
|
||||
return "../images/statusDisconnected.png"
|
||||
}
|
||||
|
||||
function getConnectionStatusColor(status) {
|
||||
if (status == Wallet.ConnectionStatus_Connected)
|
||||
return "#FF6C3B"
|
||||
else
|
||||
return "#AAAAAA"
|
||||
}
|
||||
|
||||
function getConnectionStatusString(status) {
|
||||
if (status == Wallet.ConnectionStatus_Connected) {
|
||||
if(!appWindow.daemonSynced)
|
||||
return qsTr("Synchronizing")
|
||||
if(appWindow.remoteNodeConnected)
|
||||
return qsTr("Remote node")
|
||||
return qsTr("Connected")
|
||||
}
|
||||
if (status == Wallet.ConnectionStatus_WrongVersion)
|
||||
@@ -60,37 +52,68 @@ Row {
|
||||
return qsTr("Invalid connection status")
|
||||
}
|
||||
|
||||
Item {
|
||||
id: iconItem
|
||||
anchors.bottom: parent.bottom
|
||||
width: 50
|
||||
height: 50
|
||||
RowLayout {
|
||||
Layout.preferredHeight: 40 * scaleRatio
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: getConnectionStatusImage(item.connected)
|
||||
Item {
|
||||
id: iconItem
|
||||
anchors.top: parent.top
|
||||
width: 40 * scaleRatio
|
||||
height: 40 * scaleRatio
|
||||
opacity: {
|
||||
if(item.connected == Wallet.ConnectionStatus_Connected){
|
||||
return 1
|
||||
} else {
|
||||
return 0.5
|
||||
}
|
||||
}
|
||||
|
||||
Image {
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 6
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 11
|
||||
source: {
|
||||
if(item.connected == Wallet.ConnectionStatus_Connected){
|
||||
return "../images/lightning.png"
|
||||
} else {
|
||||
return "../images/lightning-white.png"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Item {
|
||||
anchors.top: parent.top
|
||||
anchors.left: iconItem.right
|
||||
height: 40 * scaleRatio
|
||||
width: 260 * scaleRatio
|
||||
|
||||
Text {
|
||||
id: statusText
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 0
|
||||
font.family: MoneroComponents.Style.fontMedium.name
|
||||
font.bold: true
|
||||
font.pixelSize: 13 * scaleRatio
|
||||
color: "white"
|
||||
opacity: 0.5
|
||||
text: qsTr("Network status") + translationManager.emptyString
|
||||
}
|
||||
|
||||
Text {
|
||||
id: statusTextVal
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 14
|
||||
font.family: MoneroComponents.Style.fontMedium.name
|
||||
font.pixelSize: 20 * scaleRatio
|
||||
color: "white"
|
||||
text: getConnectionStatusString(item.connected) + translationManager.emptyString
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Column {
|
||||
anchors.bottom: parent.bottom
|
||||
height: 53
|
||||
spacing: 3
|
||||
|
||||
Text {
|
||||
anchors.left: parent.left
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#545454"
|
||||
text: qsTr("Network status") + translationManager.emptyString
|
||||
}
|
||||
|
||||
Text {
|
||||
anchors.left: parent.left
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 18
|
||||
color: getConnectionStatusColor(item.connected)
|
||||
text: getConnectionStatusString(item.connected) + translationManager.emptyString
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
248
components/NewPasswordDialog.qml
Normal file
@@ -0,0 +1,248 @@
|
||||
// Copyright (c) 2017, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.7
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Window 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: root
|
||||
visible: false
|
||||
z: parent.z + 2
|
||||
|
||||
property alias password: passwordInput1.text
|
||||
|
||||
// same signals as Dialog has
|
||||
signal accepted()
|
||||
signal rejected()
|
||||
signal closeCallback()
|
||||
|
||||
function open() {
|
||||
inactiveOverlay.visible = true
|
||||
leftPanel.enabled = false
|
||||
middlePanel.enabled = false
|
||||
titleBar.enabled = false
|
||||
show();
|
||||
root.visible = true;
|
||||
passwordInput1.text = "";
|
||||
passwordInput2.text = "";
|
||||
passwordInput1.focus = true
|
||||
}
|
||||
|
||||
function close() {
|
||||
inactiveOverlay.visible = false
|
||||
leftPanel.enabled = true
|
||||
middlePanel.enabled = true
|
||||
titleBar.enabled = true
|
||||
root.visible = false;
|
||||
closeCallback();
|
||||
}
|
||||
|
||||
// TODO: implement without hardcoding sizes
|
||||
width: 480
|
||||
height: 360
|
||||
|
||||
// Make window draggable
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
property point lastMousePos: Qt.point(0, 0)
|
||||
onPressed: { lastMousePos = Qt.point(mouseX, mouseY); }
|
||||
onMouseXChanged: root.x += (mouseX - lastMousePos.x)
|
||||
onMouseYChanged: root.y += (mouseY - lastMousePos.y)
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
z: inactiveOverlay.z + 1
|
||||
id: mainLayout
|
||||
spacing: 10
|
||||
anchors { fill: parent; margins: 35 * scaleRatio }
|
||||
|
||||
ColumnLayout {
|
||||
id: column
|
||||
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.maximumWidth: 400 * scaleRatio
|
||||
|
||||
Label {
|
||||
text: qsTr("Please enter new password")
|
||||
anchors.left: parent.left
|
||||
Layout.fillWidth: true
|
||||
|
||||
font.pixelSize: 16 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
}
|
||||
|
||||
TextField {
|
||||
id : passwordInput1
|
||||
Layout.topMargin: 6
|
||||
Layout.fillWidth: true
|
||||
anchors.left: parent.left
|
||||
horizontalAlignment: TextInput.AlignLeft
|
||||
verticalAlignment: TextInput.AlignVCenter
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
font.pixelSize: 24 * scaleRatio
|
||||
echoMode: TextInput.Password
|
||||
bottomPadding: 10
|
||||
leftPadding: 10
|
||||
topPadding: 10
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
KeyNavigation.tab: passwordInput2
|
||||
|
||||
background: Rectangle {
|
||||
radius: 2
|
||||
border.color: Qt.rgba(255, 255, 255, 0.35)
|
||||
border.width: 1
|
||||
color: "black"
|
||||
|
||||
Image {
|
||||
width: 12
|
||||
height: 16
|
||||
source: "../images/lockIcon.png"
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 20
|
||||
}
|
||||
}
|
||||
|
||||
Keys.onEscapePressed: {
|
||||
root.close()
|
||||
root.rejected()
|
||||
}
|
||||
}
|
||||
|
||||
// padding
|
||||
Rectangle {
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
height: 10
|
||||
opacity: 0
|
||||
color: "black"
|
||||
}
|
||||
|
||||
Label {
|
||||
text: qsTr("Please confirm new password")
|
||||
anchors.left: parent.left
|
||||
Layout.fillWidth: true
|
||||
|
||||
font.pixelSize: 16 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
}
|
||||
|
||||
TextField {
|
||||
id : passwordInput2
|
||||
Layout.topMargin: 6
|
||||
Layout.fillWidth: true
|
||||
anchors.left: parent.left
|
||||
horizontalAlignment: TextInput.AlignLeft
|
||||
verticalAlignment: TextInput.AlignVCenter
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
font.pixelSize: 24 * scaleRatio
|
||||
echoMode: TextInput.Password
|
||||
KeyNavigation.tab: okButton
|
||||
bottomPadding: 10
|
||||
leftPadding: 10
|
||||
topPadding: 10
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
|
||||
background: Rectangle {
|
||||
radius: 2
|
||||
border.color: Qt.rgba(255, 255, 255, 0.35)
|
||||
border.width: 1
|
||||
color: "black"
|
||||
|
||||
Image {
|
||||
width: 12
|
||||
height: 16
|
||||
source: "../images/lockIcon.png"
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 20
|
||||
}
|
||||
}
|
||||
|
||||
Keys.onReturnPressed: {
|
||||
if (passwordInput1.text === passwordInput2.text) {
|
||||
root.close()
|
||||
root.accepted()
|
||||
}
|
||||
}
|
||||
Keys.onEscapePressed: {
|
||||
root.close()
|
||||
root.rejected()
|
||||
}
|
||||
}
|
||||
|
||||
// padding
|
||||
Rectangle {
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
height: 10
|
||||
opacity: 0
|
||||
color: "black"
|
||||
}
|
||||
|
||||
// Ok/Cancel buttons
|
||||
RowLayout {
|
||||
id: buttons
|
||||
spacing: 16 * scaleRatio
|
||||
Layout.topMargin: 16
|
||||
Layout.alignment: Qt.AlignRight
|
||||
|
||||
MoneroComponents.StandardButton {
|
||||
id: cancelButton
|
||||
text: qsTr("Cancel") + translationManager.emptyString
|
||||
KeyNavigation.tab: passwordInput1
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.rejected()
|
||||
}
|
||||
}
|
||||
MoneroComponents.StandardButton {
|
||||
id: okButton
|
||||
text: qsTr("Continue")
|
||||
KeyNavigation.tab: cancelButton
|
||||
enabled: passwordInput1.text === passwordInput2.text
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.accepted()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2017, The Monero Project
|
||||
// Copyright (c) 2017-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -75,6 +75,7 @@ Item {
|
||||
}
|
||||
|
||||
function show(message) {
|
||||
item.visible = true
|
||||
item.message = message
|
||||
item.active = true
|
||||
hider.running = true
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -26,8 +26,8 @@
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick 2.7
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
@@ -35,70 +35,99 @@ import QtQuick.Window 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Window {
|
||||
Item {
|
||||
id: root
|
||||
modality: Qt.ApplicationModal
|
||||
flags: Qt.Window | Qt.FramelessWindowHint
|
||||
visible: false
|
||||
z: parent.z + 2
|
||||
|
||||
property alias password: passwordInput.text
|
||||
property string walletName
|
||||
|
||||
// same signals as Dialog has
|
||||
signal accepted()
|
||||
signal rejected()
|
||||
|
||||
signal closeCallback()
|
||||
|
||||
function open(walletName) {
|
||||
inactiveOverlay.visible = true // draw appwindow inactive
|
||||
root.walletName = walletName ? walletName : ""
|
||||
leftPanel.enabled = false
|
||||
middlePanel.enabled = false
|
||||
titleBar.enabled = false
|
||||
show()
|
||||
root.visible = true;
|
||||
passwordInput.forceActiveFocus();
|
||||
passwordInput.text = ""
|
||||
}
|
||||
|
||||
// TODO: implement without hardcoding sizes
|
||||
width: 480
|
||||
height: walletName ? 240 : 200
|
||||
function close() {
|
||||
inactiveOverlay.visible = false
|
||||
leftPanel.enabled = true
|
||||
middlePanel.enabled = true
|
||||
titleBar.enabled = true
|
||||
root.visible = false;
|
||||
closeCallback();
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
z: inactiveOverlay.z + 1
|
||||
id: mainLayout
|
||||
spacing: 10
|
||||
anchors { fill: parent; margins: 35 }
|
||||
anchors { fill: parent; margins: 35 * scaleRatio }
|
||||
|
||||
ColumnLayout {
|
||||
id: column
|
||||
//anchors {fill: parent; margins: 16 }
|
||||
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.maximumWidth: 400 * scaleRatio
|
||||
|
||||
Label {
|
||||
text: root.walletName.length > 0 ? qsTr("Please enter wallet password for:<br>") + root.walletName : qsTr("Please enter wallet password")
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.columnSpan: 2
|
||||
text: root.walletName.length > 0 ? qsTr("Please enter wallet password for: ") + root.walletName : qsTr("Please enter wallet password")
|
||||
anchors.left: parent.left
|
||||
Layout.fillWidth: true
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
font.pixelSize: 24
|
||||
font.family: "Arial"
|
||||
color: "#555555"
|
||||
|
||||
font.pixelSize: 16 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
}
|
||||
|
||||
TextField {
|
||||
id : passwordInput
|
||||
focus: true
|
||||
Layout.topMargin: 6
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
horizontalAlignment: TextInput.AlignHCenter
|
||||
anchors.left: parent.left
|
||||
horizontalAlignment: TextInput.AlignLeft
|
||||
verticalAlignment: TextInput.AlignVCenter
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 32
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
font.pixelSize: 24 * scaleRatio
|
||||
echoMode: TextInput.Password
|
||||
KeyNavigation.tab: okButton
|
||||
bottomPadding: 10
|
||||
leftPadding: 10
|
||||
topPadding: 10
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
selectionColor: MoneroComponents.Style.dimmedFontColor
|
||||
selectedTextColor: MoneroComponents.Style.defaultFontColor
|
||||
|
||||
style: TextFieldStyle {
|
||||
renderType: Text.NativeRendering
|
||||
textColor: "#35B05A"
|
||||
passwordCharacter: "•"
|
||||
// no background
|
||||
background: Rectangle {
|
||||
radius: 0
|
||||
border.width: 0
|
||||
background: Rectangle {
|
||||
radius: 2
|
||||
border.color: Qt.rgba(255, 255, 255, 0.35)
|
||||
border.width: 1
|
||||
color: "black"
|
||||
|
||||
Image {
|
||||
width: 12
|
||||
height: 16
|
||||
source: "../images/lockIcon.png"
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 20
|
||||
}
|
||||
}
|
||||
|
||||
Keys.enabled: root.visible
|
||||
Keys.onReturnPressed: {
|
||||
root.close()
|
||||
root.accepted()
|
||||
@@ -109,66 +138,38 @@ Window {
|
||||
root.rejected()
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// underline
|
||||
Rectangle {
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
anchors.bottomMargin: 3
|
||||
|
||||
}
|
||||
// padding
|
||||
Rectangle {
|
||||
Layout.fillWidth: true
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
height: 10
|
||||
opacity: 0
|
||||
color: "black"
|
||||
}
|
||||
}
|
||||
// Ok/Cancel buttons
|
||||
RowLayout {
|
||||
id: buttons
|
||||
spacing: 60
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
|
||||
MoneroComponents.StandardButton {
|
||||
id: cancelButton
|
||||
width: 120
|
||||
fontSize: 14
|
||||
shadowReleasedColor: "#FF4304"
|
||||
shadowPressedColor: "#B32D00"
|
||||
releasedColor: "#FF6C3C"
|
||||
pressedColor: "#FF4304"
|
||||
text: qsTr("Cancel") + translationManager.emptyString
|
||||
KeyNavigation.tab: passwordInput
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.rejected()
|
||||
}
|
||||
}
|
||||
MoneroComponents.StandardButton {
|
||||
id: okButton
|
||||
width: 120
|
||||
fontSize: 14
|
||||
shadowReleasedColor: "#FF4304"
|
||||
shadowPressedColor: "#B32D00"
|
||||
releasedColor: "#FF6C3C"
|
||||
pressedColor: "#FF4304"
|
||||
text: qsTr("Ok")
|
||||
KeyNavigation.tab: cancelButton
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.accepted()
|
||||
// Ok/Cancel buttons
|
||||
RowLayout {
|
||||
id: buttons
|
||||
spacing: 16 * scaleRatio
|
||||
Layout.topMargin: 16
|
||||
Layout.alignment: Qt.AlignRight
|
||||
|
||||
MoneroComponents.StandardButton {
|
||||
id: cancelButton
|
||||
small: true
|
||||
text: qsTr("Cancel") + translationManager.emptyString
|
||||
KeyNavigation.tab: passwordInput
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.rejected()
|
||||
}
|
||||
}
|
||||
|
||||
MoneroComponents.StandardButton {
|
||||
id: okButton
|
||||
small: true
|
||||
text: qsTr("Continue")
|
||||
KeyNavigation.tab: cancelButton
|
||||
onClicked: {
|
||||
root.close()
|
||||
root.accepted()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -26,6 +26,8 @@
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
// @TODO: Remove component after wizard redesign
|
||||
|
||||
import QtQuick 2.0
|
||||
|
||||
Item {
|
||||
@@ -62,11 +64,7 @@ Item {
|
||||
//radius: 2
|
||||
width: row.x
|
||||
|
||||
color: {
|
||||
if(item.fillLevel < 3) return "#FF6C3C"
|
||||
if(item.fillLevel < 13) return "#AAFFBB"
|
||||
return "#36B25C"
|
||||
}
|
||||
color: "#FF6C3C"
|
||||
|
||||
Timer {
|
||||
interval: 500
|
||||
@@ -116,7 +114,7 @@ Item {
|
||||
|
||||
Row {
|
||||
id: row2
|
||||
spacing: ((bar.width - 8) / 2) / 4
|
||||
spacing: bar.width / 14
|
||||
|
||||
Repeater {
|
||||
model: 4
|
||||
@@ -125,7 +123,7 @@ Item {
|
||||
id: delegateItem2
|
||||
currentX: x + row2.x
|
||||
currentIndex: index
|
||||
mainTick: currentIndex === 0 || currentIndex === 3 || currentIndex === 13
|
||||
mainTick: currentIndex === 0
|
||||
Component.onCompleted: {
|
||||
row.positions[currentIndex] = delegateItem2
|
||||
}
|
||||
@@ -135,7 +133,7 @@ Item {
|
||||
|
||||
Row {
|
||||
id: row1
|
||||
spacing: ((bar.width - 8) / 2) / 10
|
||||
spacing: bar.width / 14
|
||||
|
||||
Repeater {
|
||||
model: 10
|
||||
@@ -144,7 +142,7 @@ Item {
|
||||
id: delegateItem1
|
||||
currentX: x + row1.x
|
||||
currentIndex: index + 4
|
||||
mainTick: currentIndex === 0 || currentIndex === 3 || currentIndex === 13
|
||||
mainTick: currentIndex === 13
|
||||
Component.onCompleted: {
|
||||
row.positions[currentIndex] = delegateItem1
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -26,6 +26,8 @@
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
// @TODO: Remove component after wizard redesign
|
||||
|
||||
import QtQuick 2.0
|
||||
|
||||
Item {
|
||||
@@ -71,11 +73,7 @@ Item {
|
||||
//radius: 2
|
||||
width: row.x
|
||||
|
||||
color: {
|
||||
if(item.fillLevel < 5) return "#FF6C3C"
|
||||
if(item.fillLevel < 13) return "#AAFFBB"
|
||||
return "#36B25C"
|
||||
}
|
||||
color: "#FF6C3C"
|
||||
|
||||
Timer {
|
||||
interval: 500
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -31,17 +31,26 @@ import QtQuick.Window 2.1
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
Window {
|
||||
Rectangle {
|
||||
id: root
|
||||
modality: Qt.ApplicationModal
|
||||
flags: Qt.Window
|
||||
color: "white"
|
||||
visible: false
|
||||
z:11
|
||||
property alias messageText: messageTitle.text
|
||||
property alias heightProgressText : heightProgress.text
|
||||
|
||||
width: 200
|
||||
height: 100
|
||||
width: 200 * scaleRatio
|
||||
height: 100 * scaleRatio
|
||||
opacity: 0.7
|
||||
|
||||
function show() {
|
||||
root.visible = true;
|
||||
}
|
||||
|
||||
function close() {
|
||||
root.visible = false;
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
id: rootLayout
|
||||
|
||||
@@ -49,8 +58,8 @@ Window {
|
||||
anchors.right: parent.right
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
|
||||
anchors.leftMargin: 30
|
||||
anchors.rightMargin: 30
|
||||
anchors.leftMargin: 30 * scaleRatio
|
||||
anchors.rightMargin: 30 * scaleRatio
|
||||
|
||||
BusyIndicator {
|
||||
running: parent.visible
|
||||
@@ -61,7 +70,7 @@ Window {
|
||||
id: messageTitle
|
||||
text: "Please wait..."
|
||||
font {
|
||||
pixelSize: 22
|
||||
pixelSize: 22 * scaleRatio
|
||||
}
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
Layout.alignment: Qt.AlignVCenter | Qt.AlignHCenter
|
||||
@@ -72,7 +81,7 @@ Window {
|
||||
Text {
|
||||
id: heightProgress
|
||||
font {
|
||||
pixelSize: 18
|
||||
pixelSize: 18 * scaleRatio
|
||||
}
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
Layout.alignment: Qt.AlignVCenter | Qt.AlignHCenter
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -29,78 +29,94 @@
|
||||
import QtQuick 2.0
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
||||
Item {
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Rectangle {
|
||||
id: item
|
||||
property int fillLevel: 0
|
||||
height: 22
|
||||
anchors.margins:15
|
||||
property string syncType // Wallet or Daemon
|
||||
property string syncText: qsTr("%1 blocks remaining: ").arg(syncType)
|
||||
visible: false
|
||||
//clip: true
|
||||
|
||||
function updateProgress(currentBlock,targetBlock, blocksToSync){
|
||||
if(targetBlock == 1) {
|
||||
fillLevel = 0
|
||||
progressText.text = qsTr("Establishing connection...");
|
||||
progressBar.visible = true
|
||||
return
|
||||
}
|
||||
color: "transparent"
|
||||
|
||||
function updateProgress(currentBlock,targetBlock, blocksToSync, statusTxt){
|
||||
if(targetBlock > 0) {
|
||||
var remaining = targetBlock - currentBlock
|
||||
// wallet sync
|
||||
if(blocksToSync > 0)
|
||||
var progressLevel = (100*(blocksToSync - remaining)/blocksToSync).toFixed(0);
|
||||
// Daemon sync
|
||||
else
|
||||
var progressLevel = (100*(currentBlock/targetBlock)).toFixed(0);
|
||||
var remaining = (currentBlock < targetBlock) ? targetBlock - currentBlock : 0
|
||||
var progressLevel = (blocksToSync > 0 && blocksToSync != remaining) ? (100*(blocksToSync - remaining)/blocksToSync).toFixed(0) : (100*(currentBlock / targetBlock)).toFixed(0)
|
||||
fillLevel = progressLevel
|
||||
progressText.text = qsTr("Blocks remaining: %1").arg(remaining.toFixed(0));
|
||||
progressBar.visible = currentBlock < targetBlock
|
||||
if(typeof statusTxt != "undefined" && statusTxt != "") {
|
||||
progressText.text = statusTxt;
|
||||
} else {
|
||||
progressText.text = syncText + remaining.toFixed(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: bar
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
height: 22
|
||||
radius: 2
|
||||
color: "#FFFFFF"
|
||||
Item {
|
||||
anchors.top: item.top
|
||||
anchors.topMargin: 10 * scaleRatio
|
||||
anchors.leftMargin: 15 * scaleRatio
|
||||
anchors.rightMargin: 15 * scaleRatio
|
||||
anchors.fill: parent
|
||||
|
||||
Rectangle {
|
||||
id: fillRect
|
||||
Text {
|
||||
id: progressText
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.left: parent.left
|
||||
anchors.margins: 2
|
||||
height: bar.height
|
||||
property int maxWidth: parent.width - 4
|
||||
width: (maxWidth * fillLevel) / 100
|
||||
color: {
|
||||
if(item.fillLevel < 99 ) return "#FF6C3C"
|
||||
//if(item.fillLevel < 99) return "#FFE00A"
|
||||
return "#36B25C"
|
||||
}
|
||||
|
||||
anchors.topMargin: 6
|
||||
font.family: MoneroComponents.Style.fontMedium.name
|
||||
font.pixelSize: 13 * scaleRatio
|
||||
font.bold: true
|
||||
color: "white"
|
||||
text: qsTr("Synchronizing %1").arg(syncType) + translationManager.emptyString
|
||||
height: 18 * scaleRatio
|
||||
}
|
||||
|
||||
Text {
|
||||
id: progressTextValue
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 6
|
||||
anchors.right: parent.right
|
||||
font.family: MoneroComponents.Style.fontMedium.name
|
||||
font.pixelSize: 13 * scaleRatio
|
||||
font.bold: true
|
||||
color: "white"
|
||||
height:18 * scaleRatio
|
||||
}
|
||||
|
||||
|
||||
Rectangle {
|
||||
color:"#333"
|
||||
anchors.bottom: parent.bottom
|
||||
id: bar
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 8
|
||||
anchors.right: parent.right
|
||||
anchors.top: progressText.bottom
|
||||
anchors.topMargin: 4
|
||||
height: 8 * scaleRatio
|
||||
radius: 8 * scaleRatio
|
||||
color: "#333333" // progressbar bg
|
||||
|
||||
Text {
|
||||
id:progressText
|
||||
Rectangle {
|
||||
id: fillRect
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#000"
|
||||
text: qsTr("Synchronizing blocks")
|
||||
height:18
|
||||
anchors.left: parent.left
|
||||
height: bar.height
|
||||
property int maxWidth: bar.width * scaleRatio
|
||||
width: (maxWidth * fillLevel) / 100
|
||||
radius: 8
|
||||
// could change color based on progressbar status; if(item.fillLevel < 99 )
|
||||
color: "#FA6800"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
color:"#333"
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 8 * scaleRatio
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2017, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -44,7 +44,7 @@ Rectangle {
|
||||
color: "black"
|
||||
state: "Stopped"
|
||||
|
||||
signal qrcode_decoded(string address, string payment_id, string amount, string tx_description, string recipient_name)
|
||||
signal qrcode_decoded(string address, string payment_id, string amount, string tx_description, string recipient_name, var extra_parameters)
|
||||
|
||||
states: [
|
||||
State {
|
||||
@@ -83,7 +83,7 @@ Rectangle {
|
||||
id : finder
|
||||
objectName: "QrFinder"
|
||||
onDecoded : {
|
||||
root.qrcode_decoded(address, payment_id, amount, tx_description, recipient_name)
|
||||
root.qrcode_decoded(address, payment_id, amount, tx_description, recipient_name, extra_parameters)
|
||||
root.state = "Stopped"
|
||||
}
|
||||
onNotifyError : {
|
||||
@@ -126,7 +126,7 @@ Rectangle {
|
||||
|
||||
MessageDialog {
|
||||
id: messageDialog
|
||||
title: "Scanning QrCode"
|
||||
title: qsTr("QrCode Scanned") + translationManager.emptyString
|
||||
onAccepted: {
|
||||
root.state = "Stopped"
|
||||
}
|
||||
|
||||
101
components/RadioButton.qml
Normal file
@@ -0,0 +1,101 @@
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
RowLayout {
|
||||
id: radioButton
|
||||
property alias text: label.text
|
||||
property bool checked: false
|
||||
property int fontSize: 14 * scaleRatio
|
||||
property alias fontColor: label.color
|
||||
signal clicked()
|
||||
height: 26 * scaleRatio
|
||||
// legacy properties
|
||||
property var checkedColor: "white"
|
||||
property var borderColor: checked ? Qt.rgba(1, 1, 1, 0.35) : Qt.rgba(1, 1, 1, 0.25)
|
||||
|
||||
function toggle(){
|
||||
radioButton.checked = !radioButton.checked
|
||||
radioButton.clicked()
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
Rectangle {
|
||||
id: button
|
||||
anchors.left: parent.left
|
||||
y: 0
|
||||
color: "transparent"
|
||||
border.color: borderColor
|
||||
width: radioButton.height
|
||||
height: radioButton.height
|
||||
radius: radioButton.height
|
||||
|
||||
Rectangle {
|
||||
visible: radioButton.checked
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
color: checkedColor
|
||||
width: 10 * scaleRatio
|
||||
height: 10 * scaleRatio
|
||||
radius: 10
|
||||
opacity: 0.8
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
toggle()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Text {
|
||||
id: label
|
||||
anchors.left: button.right
|
||||
anchors.leftMargin: !isMobile ? 10 : 8
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: radioButton.fontSize
|
||||
wrapMode: Text.Wrap
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
toggle()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
102
components/RemoteNodeEdit.qml
Normal file
@@ -0,0 +1,102 @@
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without modification, are
|
||||
// permitted provided that the following conditions are met:
|
||||
//
|
||||
// 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
// conditions and the following disclaimer.
|
||||
//
|
||||
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
// of conditions and the following disclaimer in the documentation and/or other
|
||||
// materials provided with the distribution.
|
||||
//
|
||||
// 3. Neither the name of the copyright holder nor the names of its contributors may be
|
||||
// used to endorse or promote products derived from this software without specific
|
||||
// prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
|
||||
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
|
||||
// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick.Controls 1.2
|
||||
import QtQuick.Controls.Styles 1.2
|
||||
import QtQuick 2.2
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
GridLayout {
|
||||
columns: (isMobile) ? 1 : 2
|
||||
columnSpacing: 32
|
||||
id: root
|
||||
property alias daemonAddrText: daemonAddr.text
|
||||
property alias daemonPortText: daemonPort.text
|
||||
property alias daemonAddrLabelText: daemonAddr.labelText
|
||||
property alias daemonPortLabelText: daemonPort.labelText
|
||||
|
||||
// TODO: LEGACY; remove these placeHolder variables when
|
||||
// the wizards get redesigned to the black-theme
|
||||
property string placeholderFontFamily: MoneroComponents.Style.fontRegular.name
|
||||
property bool placeholderFontBold: false
|
||||
property int placeholderFontSize: 18 * scaleRatio
|
||||
property string placeholderColor: MoneroComponents.Style.defaultFontColor
|
||||
property real placeholderOpacity: 0.35
|
||||
|
||||
property string lineEditBorderColor: Qt.rgba(0, 0, 0, 0.15)
|
||||
property string lineEditBackgroundColor: "white"
|
||||
property string lineEditFontColor: "black"
|
||||
property int lineEditFontSize: 18 * scaleRatio
|
||||
property int labelFontSize: 16 * scaleRatio
|
||||
property bool lineEditFontBold: true
|
||||
|
||||
signal editingFinished()
|
||||
|
||||
function getAddress() {
|
||||
return daemonAddr.text.trim() + ":" + daemonPort.text.trim()
|
||||
}
|
||||
|
||||
LineEditMulti {
|
||||
id: daemonAddr
|
||||
Layout.fillWidth: true
|
||||
placeholderText: qsTr("Remote Node Hostname / IP") + translationManager.emptyString
|
||||
placeholderFontFamily: root.placeholderFontFamily
|
||||
placeholderFontBold: root.placeholderFontBold
|
||||
placeholderFontSize: root.placeholderFontSize
|
||||
placeholderColor: root.placeholderColor
|
||||
placeholderOpacity: root.placeholderOpacity
|
||||
labelFontSize: root.labelFontSize
|
||||
borderColor: lineEditBorderColor
|
||||
backgroundColor: lineEditBackgroundColor
|
||||
fontColor: lineEditFontColor
|
||||
fontBold: lineEditFontBold
|
||||
fontSize: lineEditFontSize
|
||||
onEditingFinished: root.editingFinished()
|
||||
}
|
||||
|
||||
LineEditMulti {
|
||||
id: daemonPort
|
||||
Layout.fillWidth: true
|
||||
placeholderText: qsTr("Port") + translationManager.emptyString
|
||||
placeholderFontFamily: root.placeholderFontFamily
|
||||
placeholderFontBold: root.placeholderFontBold
|
||||
placeholderFontSize: root.placeholderFontSize
|
||||
placeholderColor: root.placeholderColor
|
||||
placeholderOpacity: root.placeholderOpacity
|
||||
labelFontSize: root.labelFontSize
|
||||
borderColor: lineEditBorderColor
|
||||
backgroundColor: lineEditBackgroundColor
|
||||
fontColor: lineEditFontColor
|
||||
fontBold: lineEditFontBold
|
||||
fontSize: lineEditFontSize
|
||||
|
||||
onEditingFinished: root.editingFinished()
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -51,7 +51,7 @@ Item {
|
||||
Rectangle {
|
||||
id: scroll
|
||||
|
||||
width: 15
|
||||
width: 4
|
||||
height: {
|
||||
var t = (flickable.height * flickable.height) / flickable.contentHeight
|
||||
return t < 20 ? 20 : t
|
||||
@@ -62,7 +62,7 @@ Item {
|
||||
visible: flickable.contentHeight > flickable.height
|
||||
|
||||
Behavior on opacity {
|
||||
NumberAnimation { duration: 100; easing.type: Easing.InQuad }
|
||||
NumberAnimation { duration: 200; easing.type: Easing.InQuad }
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -28,6 +28,8 @@
|
||||
|
||||
import QtQuick 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: item
|
||||
signal searchClicked(string text, int option)
|
||||
@@ -213,18 +215,13 @@ Item {
|
||||
}
|
||||
}
|
||||
|
||||
StandardButton {
|
||||
MoneroComponents.StandardButton {
|
||||
id: button
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
anchors.margins: 6
|
||||
width: 80
|
||||
|
||||
shadowReleasedColor: "#C60F00"
|
||||
shadowPressedColor: "#8C0B00"
|
||||
pressedColor: "#C60F00"
|
||||
releasedColor: "#FF4F41"
|
||||
text: qsTr("SEARCH")
|
||||
onClicked: item.searchClicked(input.text, droplist.currentOption)
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -29,52 +29,71 @@
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: button
|
||||
height: 37
|
||||
property string shadowPressedColor
|
||||
property string shadowReleasedColor
|
||||
property string pressedColor
|
||||
property string releasedColor
|
||||
property string rightIcon: ""
|
||||
property string rightIconInactive: ""
|
||||
property string icon: ""
|
||||
property string textColor: "#FFFFFF"
|
||||
property int fontSize: 12
|
||||
property string textColor: button.enabled? MoneroComponents.Style.buttonTextColor: MoneroComponents.Style.buttonTextColorDisabled
|
||||
property string textAlign: rightIcon !== "" ? "left" : "center"
|
||||
property bool small: false
|
||||
property alias text: label.text
|
||||
property int fontSize: {
|
||||
if(small) return 14 * scaleRatio;
|
||||
else return 16 * scaleRatio;
|
||||
}
|
||||
signal clicked()
|
||||
|
||||
// Dynamic label width
|
||||
Layout.minimumWidth: (label.contentWidth > 80)? label.contentWidth + 20 : 100
|
||||
|
||||
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: parent.height - 1
|
||||
y: buttonArea.pressed ? 0 : 1
|
||||
//radius: 4
|
||||
color: {
|
||||
parent.enabled ? (buttonArea.pressed ? parent.shadowPressedColor : parent.shadowReleasedColor)
|
||||
: Qt.lighter(parent.shadowReleasedColor)
|
||||
// Dynamic height/width
|
||||
Layout.minimumWidth: {
|
||||
var _padding = 22;
|
||||
if(button.rightIcon !== ""){
|
||||
_padding += 60;
|
||||
}
|
||||
border.color: Qt.darker(parent.releasedColor)
|
||||
border.width: parent.focus ? 1 : 0
|
||||
|
||||
var _width = label.contentWidth + _padding;
|
||||
if(_width <= 50) {
|
||||
return 60;
|
||||
}
|
||||
|
||||
return _width;
|
||||
}
|
||||
|
||||
height: small ? 30 * scaleRatio : 36 * scaleRatio
|
||||
|
||||
function doClick() {
|
||||
// Android workaround
|
||||
releaseFocus();
|
||||
clicked();
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: parent.height - 1
|
||||
y: buttonArea.pressed ? 1 : 0
|
||||
color: {
|
||||
parent.enabled ? (buttonArea.pressed ? parent.pressedColor : parent.releasedColor)
|
||||
: Qt.lighter(parent.releasedColor)
|
||||
radius: 3
|
||||
color: parent.enabled ? MoneroComponents.Style.buttonBackgroundColor : MoneroComponents.Style.buttonBackgroundColorDisabled
|
||||
border.width: parent.focus ? 1 : 0
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
hoverEnabled: true
|
||||
|
||||
propagateComposedEvents: true
|
||||
|
||||
// possibly do some hover effects here
|
||||
onEntered: {
|
||||
// if(button.enabled) parent.color = Style.buttonBackgroundColorHover;
|
||||
// else parent.color = Style.buttonBackgroundColorDisabledHover;
|
||||
}
|
||||
onExited: {
|
||||
// if(button.enabled) parent.color = Style.buttonBackgroundColor;
|
||||
// else parent.color = Style.buttonBackgroundColorDisabled;
|
||||
}
|
||||
}
|
||||
//radius: 4
|
||||
|
||||
|
||||
}
|
||||
|
||||
Text {
|
||||
@@ -82,13 +101,13 @@ Item {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
font.family: "Arial"
|
||||
horizontalAlignment: textAlign === "center" ? Text.AlignHCenter : Text.AlignLeft
|
||||
anchors.leftMargin: textAlign === "center" ? 0 : 11
|
||||
font.family: MoneroComponents.Style.fontBold.name
|
||||
font.bold: true
|
||||
font.pixelSize: button.fontSize
|
||||
font.pixelSize: buttonArea.pressed ? button.fontSize - 1 : button.fontSize
|
||||
color: parent.textColor
|
||||
visible: parent.icon === ""
|
||||
// font.capitalization : Font.Capitalize
|
||||
}
|
||||
|
||||
Image {
|
||||
@@ -97,12 +116,28 @@ Item {
|
||||
source: parent.icon
|
||||
}
|
||||
|
||||
Image {
|
||||
visible: parent.rightIcon !== ""
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 11 * scaleRatio
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
width: parent.small ? 16 * scaleRatio : 20 * scaleRatio
|
||||
height: parent.small ? 16 * scaleRatio : 20 * scaleRatio
|
||||
source: {
|
||||
if(parent.rightIconInactive !== "" && !parent.enabled){
|
||||
return parent.rightIconInactive;
|
||||
}
|
||||
return parent.rightIcon;
|
||||
}
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: buttonArea
|
||||
anchors.fill: parent
|
||||
onClicked: parent.clicked()
|
||||
onClicked: doClick()
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
}
|
||||
|
||||
Keys.onSpacePressed: clicked()
|
||||
Keys.onReturnPressed: clicked()
|
||||
Keys.onSpacePressed: doClick()
|
||||
Keys.onReturnPressed: doClick()
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -27,7 +27,7 @@
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
@@ -35,10 +35,10 @@ import QtQuick.Window 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Window {
|
||||
Rectangle {
|
||||
id: root
|
||||
modality: Qt.ApplicationModal
|
||||
flags: Qt.Window | Qt.FramelessWindowHint
|
||||
color: "transparent"
|
||||
visible: false
|
||||
property alias title: dialogTitle.text
|
||||
property alias text: dialogContent.text
|
||||
property alias content: root.text
|
||||
@@ -53,32 +53,62 @@ Window {
|
||||
// same signals as Dialog has
|
||||
signal accepted()
|
||||
signal rejected()
|
||||
signal closeCallback();
|
||||
|
||||
Image {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
source: "../images/middlePanelBg.jpg"
|
||||
}
|
||||
|
||||
// Make window draggable
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
property point lastMousePos: Qt.point(0, 0)
|
||||
onPressed: { lastMousePos = Qt.point(mouseX, mouseY); }
|
||||
onMouseXChanged: root.x += (mouseX - lastMousePos.x)
|
||||
onMouseYChanged: root.y += (mouseY - lastMousePos.y)
|
||||
}
|
||||
|
||||
function open() {
|
||||
// Center
|
||||
if(!isMobile) {
|
||||
root.x = parent.width/2 - root.width/2
|
||||
root.y = 100
|
||||
}
|
||||
show()
|
||||
root.z = 11
|
||||
root.visible = true;
|
||||
}
|
||||
|
||||
function close() {
|
||||
root.visible = false;
|
||||
closeCallback();
|
||||
}
|
||||
|
||||
// TODO: implement without hardcoding sizes
|
||||
width: 480
|
||||
height: 280
|
||||
width: isMobile ? screenWidth : 520
|
||||
height: isMobile ? screenHeight : 380
|
||||
|
||||
ColumnLayout {
|
||||
id: mainLayout
|
||||
spacing: 10
|
||||
anchors { fill: parent; margins: 35 }
|
||||
anchors { fill: parent; margins: 15 }
|
||||
|
||||
RowLayout {
|
||||
id: column
|
||||
//anchors {fill: parent; margins: 16 }
|
||||
Layout.topMargin: 14 * scaleRatio
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
|
||||
Label {
|
||||
MoneroComponents.Label {
|
||||
id: dialogTitle
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
font.pixelSize: 32
|
||||
font.family: "Arial"
|
||||
color: "#555555"
|
||||
fontSize: 18 * scaleRatio
|
||||
fontFamily: "Arial"
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
}
|
||||
|
||||
}
|
||||
@@ -88,10 +118,28 @@ Window {
|
||||
id : dialogContent
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
font.family: "Arial"
|
||||
renderType: Text.QtRendering
|
||||
font.family: MoneroComponents.Style.fontLight.name
|
||||
textFormat: TextEdit.AutoText
|
||||
readOnly: true
|
||||
font.pixelSize: 12
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
selectByMouse: false
|
||||
wrapMode: TextEdit.Wrap
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: {
|
||||
appWindow.showStatusMessage(qsTr("Double tap to copy"),3)
|
||||
}
|
||||
onDoubleClicked: {
|
||||
parent.selectAll()
|
||||
parent.copy()
|
||||
parent.deselect()
|
||||
console.log("copied to clipboard");
|
||||
appWindow.showStatusMessage(qsTr("Content copied to clipboard"),3)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -103,12 +151,6 @@ Window {
|
||||
|
||||
MoneroComponents.StandardButton {
|
||||
id: cancelButton
|
||||
width: 120
|
||||
fontSize: 14
|
||||
shadowReleasedColor: "#FF4304"
|
||||
shadowPressedColor: "#B32D00"
|
||||
releasedColor: "#FF6C3C"
|
||||
pressedColor: "#FF4304"
|
||||
text: qsTr("Cancel") + translationManager.emptyString
|
||||
onClicked: {
|
||||
root.close()
|
||||
@@ -118,13 +160,7 @@ Window {
|
||||
|
||||
MoneroComponents.StandardButton {
|
||||
id: okButton
|
||||
width: 120
|
||||
fontSize: 14
|
||||
shadowReleasedColor: "#FF4304"
|
||||
shadowPressedColor: "#B32D00"
|
||||
releasedColor: "#FF6C3C"
|
||||
pressedColor: "#FF4304"
|
||||
text: qsTr("Ok")
|
||||
text: qsTr("OK")
|
||||
KeyNavigation.tab: cancelButton
|
||||
onClicked: {
|
||||
root.close()
|
||||
@@ -135,7 +171,36 @@ Window {
|
||||
}
|
||||
}
|
||||
|
||||
// window borders
|
||||
Rectangle{
|
||||
width: 1
|
||||
color: MoneroComponents.Style.grey
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
}
|
||||
|
||||
Rectangle{
|
||||
width: 1
|
||||
color: MoneroComponents.Style.grey
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
}
|
||||
|
||||
Rectangle{
|
||||
height: 1
|
||||
color: MoneroComponents.Style.grey
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
}
|
||||
|
||||
Rectangle{
|
||||
height: 1
|
||||
color: MoneroComponents.Style.grey
|
||||
anchors.left: parent.left
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -28,8 +28,11 @@
|
||||
|
||||
import QtQuick 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: dropdown
|
||||
property int itemTopMargin: 0
|
||||
property alias dataModel: repeater.model
|
||||
property string shadowPressedColor
|
||||
property string shadowReleasedColor
|
||||
@@ -38,7 +41,17 @@ Item {
|
||||
property string textColor: "#FFFFFF"
|
||||
property alias currentIndex: column.currentIndex
|
||||
property bool expanded: false
|
||||
height: 37
|
||||
property int dropdownHeight: 42
|
||||
property int fontHeaderSize: 16 * scaleRatio
|
||||
property int fontItemSize: 14 * scaleRatio
|
||||
property string colorBorder: MoneroComponents.Style.inputBorderColorInActive
|
||||
property string colorHeaderBackground: "transparent"
|
||||
property bool headerBorder: true
|
||||
property bool headerFontBold: false
|
||||
|
||||
height: dropdownHeight
|
||||
|
||||
signal changed();
|
||||
|
||||
onExpandedChanged: if(expanded) appWindow.currentItem = dropdown
|
||||
function hide() { dropdown.expanded = false }
|
||||
@@ -54,83 +67,36 @@ Item {
|
||||
return true
|
||||
}
|
||||
|
||||
// Workaroud for suspected memory leak in 5.8 causing malloc crash on app exit
|
||||
function update() {
|
||||
firstColText.text = column.currentIndex < repeater.model.rowCount() ? qsTr(repeater.model.get(column.currentIndex).column1) + translationManager.emptyString : ""
|
||||
}
|
||||
|
||||
Item {
|
||||
id: head
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
height: 37
|
||||
anchors.topMargin: parent.itemTopMargin
|
||||
height: dropdown.dropdownHeight
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: parent.height - 1
|
||||
y: dropdown.expanded || droplist.height > 0 ? 0 : 1
|
||||
color: dropdown.expanded || droplist.height > 0 ? dropdown.shadowPressedColor : dropdown.shadowReleasedColor
|
||||
//radius: 4
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: parent.height - 1
|
||||
y: dropdown.expanded || droplist.height > 0 ? 1 : 0
|
||||
color: dropdown.expanded || droplist.height > 0 ? dropdown.pressedColor : dropdown.releasedColor
|
||||
//radius: 4
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.bottom: parent.bottom
|
||||
height: 3
|
||||
width: 3
|
||||
color: dropdown.pressedColor
|
||||
visible: dropdown.expanded || droplist.height > 0
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 3
|
||||
width: 3
|
||||
color: dropdown.pressedColor
|
||||
visible: dropdown.expanded || droplist.height > 0
|
||||
color: dropdown.colorHeaderBackground
|
||||
border.width: dropdown.headerBorder ? 1 : 0
|
||||
border.color: dropdown.colorBorder
|
||||
radius: 4
|
||||
anchors.fill: parent
|
||||
}
|
||||
|
||||
Text {
|
||||
id: firstColText
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: 12
|
||||
anchors.leftMargin: 12 * scaleRatio
|
||||
elide: Text.ElideRight
|
||||
font.family: "Arial"
|
||||
font.bold: true
|
||||
font.pixelSize: 12
|
||||
color: "#FFFFFF"
|
||||
text: column.currentIndex < repeater.model.rowCount() ? qsTr(repeater.model.get(column.currentIndex).column1) + translationManager.emptyString : ""
|
||||
}
|
||||
|
||||
Text {
|
||||
id: secondColText
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: separator.left
|
||||
anchors.rightMargin: 12
|
||||
width: dropdown.expanded ? w : (separator.x - 12) - (firstColText.x + firstColText.width + 5)
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
color: "#FFFFFF"
|
||||
text: column.currentIndex < repeater.model.rowCount() ? qsTr(repeater.model.get(column.currentIndex).column2) + translationManager.emptyString : ""
|
||||
|
||||
property int w: 0
|
||||
Component.onCompleted: w = implicitWidth
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: separator
|
||||
anchors.right: dropIndicator.left
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
height: 18
|
||||
width: 1
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.bold: dropdown.headerFontBold
|
||||
font.pixelSize: dropdown.fontHeaderSize
|
||||
color: "#FFFFFF"
|
||||
}
|
||||
|
||||
@@ -139,12 +105,12 @@ Item {
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
width: 32
|
||||
width: 32 * scaleRatio
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: "../images/whiteDropIndicator.png"
|
||||
rotation: dropdown.expanded ? 180 : 0
|
||||
rotation: dropdown.expanded ? 180 * scaleRatio : 0
|
||||
}
|
||||
}
|
||||
|
||||
@@ -152,6 +118,8 @@ Item {
|
||||
id: dropArea
|
||||
anchors.fill: parent
|
||||
onClicked: dropdown.expanded = !dropdown.expanded
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
}
|
||||
}
|
||||
|
||||
@@ -168,14 +136,14 @@ Item {
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
width: 3; height: 3
|
||||
width: 3 * scaleRatio; height: 3 * scaleRatio
|
||||
color: dropdown.pressedColor
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
width: 3; height: 3
|
||||
width: 3 * scaleRatio; height: 3 * scaleRatio
|
||||
color: dropdown.pressedColor
|
||||
}
|
||||
|
||||
@@ -197,28 +165,32 @@ Item {
|
||||
property string stringLow: qsTr("Low (x1 fee)") + translationManager.emptyString
|
||||
property string stringMedium: qsTr("Medium (x20 fee)") + translationManager.emptyString
|
||||
property string stringHigh: qsTr("High (x166 fee)") + translationManager.emptyString
|
||||
property string stringSlow: qsTr("Slow (x0.25 fee)") + translationManager.emptyString
|
||||
property string stringDefault: qsTr("Default (x1 fee)") + translationManager.emptyString
|
||||
property string stringFast: qsTr("Fast (x5 fee)") + translationManager.emptyString
|
||||
property string stringFastest: qsTr("Fastest (x41.5 fee)") + translationManager.emptyString
|
||||
property string stringAll: qsTr("All") + translationManager.emptyString
|
||||
property string stringSent: qsTr("Sent") + translationManager.emptyString
|
||||
property string stringReceived: qsTr("Received") + translationManager.emptyString
|
||||
|
||||
|
||||
delegate: Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
height: 30
|
||||
height: (dropdown.dropdownHeight * 0.75) * scaleRatio
|
||||
//radius: index === repeater.count - 1 ? 4 : 0
|
||||
color: itemArea.containsMouse || index === column.currentIndex || itemArea.containsMouse ? dropdown.releasedColor : dropdown.pressedColor
|
||||
|
||||
Text {
|
||||
id: col1Text
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.left: parent.left
|
||||
anchors.right: col2Text.left
|
||||
anchors.leftMargin: 12
|
||||
anchors.rightMargin: column2.length > 0 ? 12 : 0
|
||||
font.family: "Arial"
|
||||
anchors.leftMargin: 12 * scaleRatio
|
||||
anchors.rightMargin: 0
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.bold: true
|
||||
font.pixelSize: 12
|
||||
color: "#FFFFFF"
|
||||
font.pixelSize: fontItemSize
|
||||
color: itemArea.containsMouse || index === column.currentIndex || itemArea.containsMouse ? "#FA6800" : "#FFFFFF"
|
||||
text: qsTr(column1) + translationManager.emptyString
|
||||
}
|
||||
|
||||
@@ -226,24 +198,24 @@ Item {
|
||||
id: col2Text
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: 45
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 12
|
||||
anchors.rightMargin: 45 * scaleRatio
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: 14 * scaleRatio
|
||||
color: "#FFFFFF"
|
||||
text: column2
|
||||
text: ""
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
width: 3; height: 3
|
||||
width: 3 * scaleRatio; height: 3 * scaleRatio
|
||||
color: parent.color
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
width: 3; height: 3
|
||||
width: 3 * scaleRatio; height: 3 * scaleRatio
|
||||
color: parent.color
|
||||
}
|
||||
|
||||
@@ -251,9 +223,13 @@ Item {
|
||||
id: itemArea
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
||||
onClicked: {
|
||||
dropdown.expanded = false
|
||||
column.currentIndex = index
|
||||
changed();
|
||||
dropdown.update()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
31
components/Style.qml
Normal file
@@ -0,0 +1,31 @@
|
||||
pragma Singleton
|
||||
|
||||
import QtQuick 2.5
|
||||
|
||||
QtObject {
|
||||
property QtObject fontMedium: FontLoader { id: _fontMedium; source: "qrc:/fonts/Roboto-Medium.ttf"; }
|
||||
property QtObject fontBold: FontLoader { id: _fontBold; source: "qrc:/fonts/Roboto-Bold.ttf"; }
|
||||
property QtObject fontLight: FontLoader { id: _fontLight; source: "qrc:/fonts/Roboto-Light.ttf"; }
|
||||
property QtObject fontRegular: FontLoader { id: _fontRegular; source: "qrc:/fonts/Roboto-Regular.ttf"; }
|
||||
|
||||
property string grey: "#404040"
|
||||
|
||||
property string defaultFontColor: "white"
|
||||
property string dimmedFontColor: "#BBBBBB"
|
||||
property string inputBoxBackground: "black"
|
||||
property string inputBoxBackgroundError: "#FFDDDD"
|
||||
property string inputBoxColor: "white"
|
||||
property string legacy_placeholderFontColor: "#BABABA"
|
||||
property string inputBorderColorActive: Qt.rgba(255, 255, 255, 0.38)
|
||||
property string inputBorderColorInActive: Qt.rgba(255, 255, 255, 0.32)
|
||||
property string inputBorderColorInvalid: Qt.rgba(255, 0, 0, 0.40)
|
||||
|
||||
property string buttonBackgroundColor: "#FA6800"
|
||||
property string buttonBackgroundColorHover: "#E65E00"
|
||||
property string buttonBackgroundColorDisabled: "#707070"
|
||||
property string buttonBackgroundColorDisabledHover: "#808080"
|
||||
property string buttonTextColor: "white"
|
||||
property string buttonTextColorDisabled: "black"
|
||||
property string dividerColor: "white"
|
||||
property real dividerOpacity: 0.20
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -180,7 +180,7 @@ Item {
|
||||
|
||||
// Workaround for translations in listElements. All translated strings needs to be listed in this file.
|
||||
property string stringCopy: qsTr("<b>Copy address to clipboard</b>") + translationManager.emptyString
|
||||
property string stringSend: qsTr("<b>Send to same destination</b>") + translationManager.emptyString
|
||||
property string stringSend: qsTr("<b>Send to this address</b>") + translationManager.emptyString
|
||||
property string stringFind: qsTr("<b>Find similar transactions</b>") + translationManager.emptyString
|
||||
property string stringRemove: qsTr("<b>Remove from address book</b>") + translationManager.emptyString
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -36,26 +36,40 @@ Rectangle {
|
||||
property int offset: 0
|
||||
|
||||
height: 31
|
||||
color: "#FFFFFF"
|
||||
color: "transparent"
|
||||
|
||||
Rectangle{
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
width: 1
|
||||
color: "#808080"
|
||||
}
|
||||
|
||||
Rectangle{
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
width: 1
|
||||
color: "#808080"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: "#DBDBDB"
|
||||
color: "#808080"
|
||||
}
|
||||
|
||||
Row {
|
||||
id: row
|
||||
anchors.horizontalCenter: header.offset !== 0 ? undefined: parent.horizontalCenter
|
||||
anchors.left: header.offset !== 0 ? parent.left : undefined
|
||||
anchors.leftMargin: header.offset
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
|
||||
Rectangle {
|
||||
height: 31
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
color: "#808080"
|
||||
}
|
||||
|
||||
Repeater {
|
||||
@@ -70,6 +84,7 @@ Rectangle {
|
||||
delegate: Rectangle {
|
||||
id: delegate
|
||||
property bool desc: false
|
||||
color: "transparent"
|
||||
height: 31
|
||||
width: columnWidth
|
||||
|
||||
@@ -86,7 +101,7 @@ Rectangle {
|
||||
color: {
|
||||
if(delegateArea.pressed)
|
||||
return "#FF4304"
|
||||
return index === header.activeSortColumn || delegateArea.containsMouse ? "#FF6C3C" : "#4A4949"
|
||||
return index === header.activeSortColumn || delegateArea.containsMouse ? "white" : "#808080"
|
||||
}
|
||||
text: qsTr(columnName) + translationManager.emptyString
|
||||
}
|
||||
@@ -95,6 +110,7 @@ Rectangle {
|
||||
id: delegateArea
|
||||
hoverEnabled: true
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onClicked: {
|
||||
delegate.desc = !delegate.desc
|
||||
header.activeSortColumn = index
|
||||
@@ -170,7 +186,7 @@ Rectangle {
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
height: 1
|
||||
color: index === header.activeSortColumn ? "#FFFFFF" : "#DBDBDB"
|
||||
color: "transparent"
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
@@ -178,7 +194,7 @@ Rectangle {
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
color: "#808080"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
17
components/TextBlock.qml
Normal file
@@ -0,0 +1,17 @@
|
||||
import QtQuick 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
TextEdit {
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
selectionColor: MoneroComponents.Style.dimmedFontColor
|
||||
wrapMode: Text.Wrap
|
||||
readOnly: true
|
||||
selectByMouse: true
|
||||
// Workaround for https://bugreports.qt.io/browse/QTBUG-50587
|
||||
onFocusChanged: {
|
||||
if(focus === false)
|
||||
deselect()
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -28,6 +28,8 @@
|
||||
|
||||
import QtQuick 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
Item {
|
||||
id: delegateItem
|
||||
width: 1
|
||||
@@ -49,11 +51,10 @@ Item {
|
||||
anchors.bottomMargin: 2
|
||||
font.family: "Arial"
|
||||
font.bold: true
|
||||
font.pixelSize: 12
|
||||
color: "#4A4949"
|
||||
font.pixelSize: 12 * scaleRatio
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
text: {
|
||||
if(currentIndex === 0) return qsTr("Normal") + translationManager.emptyString
|
||||
if(currentIndex === 3) return qsTr("Medium") + translationManager.emptyString
|
||||
if(currentIndex === 0) return qsTr("Default") + translationManager.emptyString
|
||||
if(currentIndex === 13) return qsTr("High") + translationManager.emptyString
|
||||
return ""
|
||||
}
|
||||
@@ -65,7 +66,7 @@ Item {
|
||||
anchors.topMargin: 14
|
||||
width: 1
|
||||
color: "#DBDBDB"
|
||||
height: currentIndex === 8 ? 16 : 8
|
||||
height: 8
|
||||
visible: !parent.mainTick
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -26,56 +26,113 @@
|
||||
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
|
||||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.2
|
||||
import QtQuick 2.5
|
||||
import QtQuick.Window 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
Rectangle {
|
||||
id: titleBar
|
||||
color: "#000000"
|
||||
|
||||
height: {
|
||||
if(!customDecorations || isMobile){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(small) return 38 * scaleRatio;
|
||||
else return 50 * scaleRatio;
|
||||
}
|
||||
y: -height
|
||||
z: 1
|
||||
|
||||
property string title
|
||||
property int mouseX: 0
|
||||
property bool containsMouse: false
|
||||
property alias basicButtonVisible: goToBasicVersionButton.visible
|
||||
property bool customDecorations: true
|
||||
signal goToBasicVersion(bool yes)
|
||||
height: customDecorations ? 30 : 0
|
||||
y: -height
|
||||
property string title
|
||||
property alias maximizeButtonVisible: maximizeButton.visible
|
||||
z: 1
|
||||
property bool customDecorations: persistentSettings.customDecorations
|
||||
property bool showWhatIsButton: true
|
||||
property bool showMinimizeButton: false
|
||||
property bool showMaximizeButton: false
|
||||
property bool showCloseButton: true
|
||||
property bool showMoneroLogo: false
|
||||
property bool small: false
|
||||
|
||||
Text {
|
||||
anchors.centerIn: parent
|
||||
font.family: "Arial"
|
||||
font.pixelSize: 15
|
||||
color: "#FFFFFF"
|
||||
text: titleBar.title
|
||||
visible: customDecorations
|
||||
signal closeClicked
|
||||
signal maximizeClicked
|
||||
signal minimizeClicked
|
||||
signal goToBasicVersion(bool yes)
|
||||
|
||||
Item {
|
||||
// Background gradient
|
||||
width: parent.width
|
||||
height: parent.height
|
||||
z: parent.z + 1
|
||||
|
||||
Image {
|
||||
anchors.fill: parent
|
||||
height: titleBar.height
|
||||
width: titleBar.width
|
||||
source: "../images/titlebarGradient.jpg"
|
||||
}
|
||||
}
|
||||
|
||||
Item {
|
||||
id: titlebarlogo
|
||||
width: 125
|
||||
height: parent.height
|
||||
anchors.centerIn: parent
|
||||
visible: customDecorations && showMoneroLogo
|
||||
z: parent.z + 1
|
||||
|
||||
Image {
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: 11
|
||||
width: 125
|
||||
height: 28
|
||||
source: "../images/titlebarLogo.png"
|
||||
}
|
||||
}
|
||||
|
||||
Label {
|
||||
id: titleLabel
|
||||
visible: !showMoneroLogo && customDecorations && titleBar.title !== ''
|
||||
anchors.centerIn: parent
|
||||
fontSize: 18
|
||||
text: titleBar.title
|
||||
z: parent.z + 1
|
||||
}
|
||||
|
||||
// collapse left panel
|
||||
Rectangle {
|
||||
id: goToBasicVersionButton
|
||||
property bool containsMouse: titleBar.mouseX >= x && titleBar.mouseX <= x + width
|
||||
property bool checked: false
|
||||
anchors.top: parent.top
|
||||
anchors.left: parent.left
|
||||
color: basicMouseArea.containsMouse || checked ? "#FFE00A" : "#000000"
|
||||
height: 30
|
||||
color: "transparent"
|
||||
height: titleBar.height
|
||||
width: height
|
||||
visible: isMobile
|
||||
z: parent.z + 2
|
||||
|
||||
Image {
|
||||
width: 14
|
||||
height: 14
|
||||
anchors.centerIn: parent
|
||||
rotation: parent.checked ? 180 : 0
|
||||
source: parent.customDecorations || parent.checked ? "../images/goToBasicVersionHovered.png" :
|
||||
"../images/gotoBasicVersion.png"
|
||||
source: "../images/expand.png"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: basicMouseArea
|
||||
hoverEnabled: true
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onEntered: goToBasicVersionButton.color = "#262626";
|
||||
onExited: goToBasicVersionButton.color = "transparent";
|
||||
onClicked: {
|
||||
releaseFocus()
|
||||
parent.checked = !parent.checked
|
||||
titleBar.goToBasicVersion(parent.checked)
|
||||
titleBar.goToBasicVersion(leftPanel.visible)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -86,91 +143,102 @@ Rectangle {
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
visible: parent.customDecorations
|
||||
z: parent.z + 2
|
||||
|
||||
Rectangle {
|
||||
property bool containsMouse: titleBar.mouseX >= x + row.x && titleBar.mouseX <= x + row.x + width && titleBar.containsMouse
|
||||
id: minimizeButton
|
||||
visible: showMinimizeButton
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
width: height
|
||||
color: containsMouse ? "#6B0072" : "#000000"
|
||||
width: 42
|
||||
color: "transparent"
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: "../images/helpIcon.png"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: whatIsArea
|
||||
anchors.fill: parent
|
||||
onClicked: {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
property bool containsMouse: titleBar.mouseX >= x + row.x && titleBar.mouseX <= x + row.x + width && titleBar.containsMouse
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
width: height
|
||||
color: containsMouse ? "#3665B3" : "#000000"
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: "../images/minimizeIcon.png"
|
||||
source: "../images/minimize.png"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: minimizeArea
|
||||
anchors.fill: parent
|
||||
onClicked: {
|
||||
appWindow.visibility = Window.Minimized
|
||||
}
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onEntered: minimizeButton.color = "#262626";
|
||||
onExited: minimizeButton.color = "transparent";
|
||||
onClicked: minimizeClicked();
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: maximizeButton
|
||||
property bool containsMouse: titleBar.mouseX >= x + row.x && titleBar.mouseX <= x + row.x + width && titleBar.containsMouse
|
||||
visible: showMaximizeButton
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
width: height
|
||||
color: containsMouse ? "#FF6C3C" : "#000000"
|
||||
width: 42
|
||||
color: "transparent";
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
height: 16
|
||||
width: 16
|
||||
source: appWindow.visibility === Window.FullScreen ? "../images/backToWindowIcon.png" :
|
||||
"../images/maximizeIcon.png"
|
||||
|
||||
"../images/fullscreen.png"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
id: maximizeArea
|
||||
anchors.fill: parent
|
||||
onClicked: {
|
||||
appWindow.visibility = appWindow.visibility !== Window.FullScreen ? Window.FullScreen :
|
||||
Window.Windowed
|
||||
}
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onEntered: maximizeButton.color = "#262626";
|
||||
onExited: maximizeButton.color = "transparent";
|
||||
onClicked: maximizeClicked();
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
property bool containsMouse: titleBar.mouseX >= x + row.x && titleBar.mouseX <= x + row.x + width && titleBar.containsMouse
|
||||
id: closeButton
|
||||
visible: showCloseButton
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
width: height
|
||||
color: containsMouse ? "#E04343" : "#000000"
|
||||
width: 42
|
||||
color: containsMouse ? "#E04343" : "#00000000"
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: "../images/closeIcon.png"
|
||||
width: 16
|
||||
height: 16
|
||||
source: "../images/close.png"
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: appWindow.close();
|
||||
onClicked: closeClicked();
|
||||
hoverEnabled: true
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
onEntered: closeButton.color = "#262626";
|
||||
onExited: closeButton.color = "transparent";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// window borders
|
||||
Rectangle {
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
anchors.left: parent.left
|
||||
height: 1
|
||||
color: "#2F2F2F"
|
||||
z: parent.z + 1
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
anchors.top: parent.top
|
||||
anchors.right: parent.right
|
||||
anchors.left: parent.left
|
||||
visible: titleBar.small
|
||||
height: 1
|
||||
color: "#2F2F2F"
|
||||
z: parent.z + 1
|
||||
}
|
||||
}
|
||||
|
||||
63
components/WarningBox.qml
Normal file
@@ -0,0 +1,63 @@
|
||||
import QtQuick 2.7
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "." as MoneroComponents
|
||||
|
||||
Rectangle {
|
||||
id: root
|
||||
property alias text: content.text
|
||||
property int fontSize: 15 * scaleRatio
|
||||
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: warningLayout.height
|
||||
|
||||
color: "#09FFFFFF"
|
||||
radius: 4
|
||||
border.color: MoneroComponents.Style.inputBorderColorInActive
|
||||
border.width: 1
|
||||
|
||||
signal linkActivated;
|
||||
|
||||
RowLayout {
|
||||
id: warningLayout
|
||||
spacing: 0
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
|
||||
Image {
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
Layout.preferredHeight: 33
|
||||
Layout.preferredWidth: 33
|
||||
Layout.rightMargin: 14
|
||||
Layout.leftMargin: 14
|
||||
Layout.topMargin: 12
|
||||
Layout.bottomMargin: 12
|
||||
source: "../images/warning.png"
|
||||
}
|
||||
|
||||
TextArea {
|
||||
id: content
|
||||
Layout.fillWidth: true
|
||||
color: MoneroComponents.Style.defaultFontColor
|
||||
font.family: MoneroComponents.Style.fontRegular.name
|
||||
font.pixelSize: root.fontSize
|
||||
horizontalAlignment: TextInput.AlignLeft
|
||||
selectByMouse: false
|
||||
textFormat: Text.RichText
|
||||
wrapMode: Text.WordWrap
|
||||
textMargin: 0
|
||||
leftPadding: 0
|
||||
topPadding: 6
|
||||
readOnly: true
|
||||
onLinkActivated: root.linkActivated();
|
||||
|
||||
// @TODO: Legacy. Remove after Qt 5.8.
|
||||
// https://stackoverflow.com/questions/41990013
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
enabled: false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
1
components/qmldir
Normal file
@@ -0,0 +1 @@
|
||||
singleton Style 1.0 Style.qml
|
||||
27
filter.cpp
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -34,13 +34,20 @@ filter::filter(QObject *parent) :
|
||||
QObject(parent)
|
||||
{
|
||||
m_tabPressed = false;
|
||||
m_backtabPressed = false;
|
||||
}
|
||||
|
||||
bool filter::eventFilter(QObject *obj, QEvent *ev) {
|
||||
switch(ev->type()) {
|
||||
case QEvent::KeyPress: {
|
||||
QKeyEvent *ke = static_cast<QKeyEvent*>(ev);
|
||||
if(ke->key() == Qt::Key_Tab || ke->key() == Qt::Key_Backtab) {
|
||||
if(ke->key() == Qt::Key_Backtab) {
|
||||
if(m_backtabPressed)
|
||||
break;
|
||||
else m_backtabPressed = true;
|
||||
}
|
||||
|
||||
if(ke->key() == Qt::Key_Tab) {
|
||||
if(m_tabPressed)
|
||||
break;
|
||||
else m_tabPressed = true;
|
||||
@@ -58,7 +65,7 @@ bool filter::eventFilter(QObject *obj, QEvent *ev) {
|
||||
sks = ks.toString();
|
||||
}
|
||||
#ifndef Q_OS_MAC
|
||||
if(sks.contains("Alt+Tab") || sks.contains("Alt+Shift+Backtab"))
|
||||
if(sks.contains("Alt+Tab") || sks.contains("Alt+Backtab"))
|
||||
break;
|
||||
#else
|
||||
sks.replace("Meta", "Ctrl");
|
||||
@@ -67,10 +74,20 @@ bool filter::eventFilter(QObject *obj, QEvent *ev) {
|
||||
} break;
|
||||
case QEvent::KeyRelease: {
|
||||
QKeyEvent *ke = static_cast<QKeyEvent*>(ev);
|
||||
if(ke->key() == Qt::Key_Tab || ke->key() == Qt::Key_Backtab)
|
||||
|
||||
if(ke->key() == Qt::Key_Backtab)
|
||||
m_backtabPressed = false;
|
||||
|
||||
if(ke->key() == Qt::Key_Tab)
|
||||
m_tabPressed = false;
|
||||
|
||||
QString sks;
|
||||
#ifdef Q_OS_ANDROID
|
||||
if(ke->key() == Qt::Key_Back) {
|
||||
qDebug() << "Android back hit";
|
||||
sks = "android_back";
|
||||
}
|
||||
#endif
|
||||
if(ke->key() == Qt::Key_Control) {
|
||||
sks = "Ctrl";
|
||||
#ifdef Q_OS_MAC
|
||||
@@ -82,7 +99,7 @@ bool filter::eventFilter(QObject *obj, QEvent *ev) {
|
||||
sks = ks.toString();
|
||||
}
|
||||
#ifndef Q_OS_MAC
|
||||
if(sks.contains("Alt+Tab") || sks.contains("Alt+Shift+Backtab"))
|
||||
if(sks.contains("Alt+Tab") || sks.contains("Alt+Backtab"))
|
||||
break;
|
||||
#else
|
||||
sks.replace("Meta", "Ctrl");
|
||||
|
||||
4
filter.h
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2014-2015, The Monero Project
|
||||
// Copyright (c) 2014-2018, The Monero Project
|
||||
//
|
||||
// All rights reserved.
|
||||
//
|
||||
@@ -36,7 +36,7 @@ class filter : public QObject
|
||||
Q_OBJECT
|
||||
private:
|
||||
bool m_tabPressed;
|
||||
|
||||
bool m_backtabPressed;
|
||||
public:
|
||||
explicit filter(QObject *parent = 0);
|
||||
|
||||
|
||||
202
fonts/LICENSE.txt
Normal file
@@ -0,0 +1,202 @@
|
||||
|
||||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
(except as stated in this section) patent license to make, have made,
|
||||
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
APPENDIX: How to apply the Apache License to your work.
|
||||
|
||||
To apply the Apache License to your work, attach the following
|
||||
boilerplate notice, with the fields enclosed by brackets "[]"
|
||||
replaced with your own identifying information. (Don't include
|
||||
the brackets!) The text should be enclosed in the appropriate
|
||||
comment syntax for the file format. We also recommend that a
|
||||
file or class name and description of purpose be included on the
|
||||
same "printed page" as the copyright notice for easier
|
||||
identification within third-party archives.
|
||||
|
||||
Copyright [yyyy] [name of copyright owner]
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
BIN
fonts/Roboto-Bold.ttf
Normal file
BIN
fonts/Roboto-Light.ttf
Normal file
BIN
fonts/Roboto-Medium.ttf
Normal file
BIN
fonts/Roboto-Regular.ttf
Normal file
@@ -15,15 +15,18 @@ BUILD_LIBWALLET=false
|
||||
if [ ! -d $MONERO_DIR/src ]; then
|
||||
git submodule init monero
|
||||
fi
|
||||
git submodule update
|
||||
git -C $MONERO_DIR fetch --tags
|
||||
git -C $MONERO_DIR checkout v0.10.3.1
|
||||
git submodule update --remote
|
||||
git -C $MONERO_DIR fetch
|
||||
git -C $MONERO_DIR checkout release-v0.13
|
||||
|
||||
# get monero core tag
|
||||
get_tag
|
||||
# create local monero branch
|
||||
git -C $MONERO_DIR checkout -B $VERSIONTAG
|
||||
|
||||
git -C $MONERO_DIR submodule init
|
||||
git -C $MONERO_DIR submodule update
|
||||
|
||||
# Merge monero PR dependencies
|
||||
|
||||
# Workaround for git username requirements
|
||||
@@ -72,8 +75,7 @@ else
|
||||
fi
|
||||
|
||||
if [ "$BUILD_LIBWALLET" != true ]; then
|
||||
# exit this script
|
||||
return
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "GUI_MONERO_VERSION=\"$VERSIONTAG\"" > $MONERO_DIR/version.sh
|
||||
@@ -108,6 +110,7 @@ elif [ "$BUILD_TYPE" == "debug-android" ]; then
|
||||
elif [ "$BUILD_TYPE" == "debug" ]; then
|
||||
echo "Building libwallet debug"
|
||||
CMAKE_BUILD_TYPE=Debug
|
||||
STATIC=true
|
||||
else
|
||||
echo "Valid build types are release, release-static, release-android, debug-android and debug"
|
||||
exit 1;
|
||||
@@ -115,14 +118,14 @@ fi
|
||||
|
||||
|
||||
echo "cleaning up existing monero build dir, libs and includes"
|
||||
#rm -fr $MONERO_DIR/build
|
||||
rm -fr $MONERO_DIR/build
|
||||
rm -fr $MONERO_DIR/lib
|
||||
rm -fr $MONERO_DIR/include
|
||||
rm -fr $MONERO_DIR/bin
|
||||
|
||||
|
||||
mkdir -p $MONERO_DIR/build/release
|
||||
pushd $MONERO_DIR/build/release
|
||||
mkdir -p $MONERO_DIR/build/$BUILD_TYPE
|
||||
pushd $MONERO_DIR/build/$BUILD_TYPE
|
||||
|
||||
# reusing function from "utils.sh"
|
||||
platform=$(get_platform)
|
||||
@@ -208,7 +211,7 @@ if test -z "$CPU_CORE_COUNT"; then
|
||||
fi
|
||||
|
||||
# Build libwallet_merged
|
||||
pushd $MONERO_DIR/build/release/src/wallet
|
||||
pushd $MONERO_DIR/build/$BUILD_TYPE/src/wallet
|
||||
eval $make_exec version -C ../..
|
||||
eval $make_exec -j$CPU_CORE_COUNT
|
||||
eval $make_exec install -j$CPU_CORE_COUNT
|
||||
@@ -217,19 +220,24 @@ popd
|
||||
# Build monerod
|
||||
# win32 need to build daemon manually with msys2 toolchain
|
||||
if [ "$platform" != "mingw32" ] && [ "$ANDROID" != true ]; then
|
||||
pushd $MONERO_DIR/build/release/src/daemon
|
||||
pushd $MONERO_DIR/build/$BUILD_TYPE/src/daemon
|
||||
eval make -j$CPU_CORE_COUNT
|
||||
eval make install -j$CPU_CORE_COUNT
|
||||
popd
|
||||
fi
|
||||
|
||||
# build install epee
|
||||
eval make -C $MONERO_DIR/build/release/contrib/epee all install
|
||||
eval make -C $MONERO_DIR/build/$BUILD_TYPE/contrib/epee all install
|
||||
|
||||
# install easylogging
|
||||
eval make -C $MONERO_DIR/build/$BUILD_TYPE/external/easylogging++ all install
|
||||
|
||||
# Install libunwind
|
||||
# install lmdb
|
||||
eval make -C $MONERO_DIR/build/$BUILD_TYPE/external/db_drivers/liblmdb all install
|
||||
|
||||
# Install libunbound
|
||||
echo "Installing libunbound..."
|
||||
pushd $MONERO_DIR/build/release/external/unbound
|
||||
pushd $MONERO_DIR/build/$BUILD_TYPE/external/unbound
|
||||
# no need to make, it was already built as dependency for libwallet
|
||||
# make -j$CPU_CORE_COUNT
|
||||
$make_exec install -j$CPU_CORE_COUNT
|
||||
|
||||
BIN
images/arrow-right-medium-white.png
Normal file
|
After Width: | Height: | Size: 324 B |
|
Before Width: | Height: | Size: 288 B After Width: | Height: | Size: 447 B |
|
Before Width: | Height: | Size: 287 B After Width: | Height: | Size: 447 B |
|
Before Width: | Height: | Size: 288 B After Width: | Height: | Size: 447 B |
|
Before Width: | Height: | Size: 231 B After Width: | Height: | Size: 396 B |
BIN
images/card-background.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
images/checkedBlackIcon.png
Normal file
|
After Width: | Height: | Size: 344 B |
BIN
images/checkedIcon-black.png
Normal file
|
After Width: | Height: | Size: 388 B |
|
Before Width: | Height: | Size: 317 B After Width: | Height: | Size: 460 B |
|
Before Width: | Height: | Size: 320 B After Width: | Height: | Size: 460 B |
BIN
images/close.png
Normal file
|
After Width: | Height: | Size: 383 B |
|
Before Width: | Height: | Size: 249 B After Width: | Height: | Size: 408 B |
|
Before Width: | Height: | Size: 255 B After Width: | Height: | Size: 408 B |
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 306 B After Width: | Height: | Size: 454 B |
|
Before Width: | Height: | Size: 59 KiB After Width: | Height: | Size: 3.7 KiB |
BIN
images/createWalletFromDevice.png
Executable file
|
After Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 268 B After Width: | Height: | Size: 415 B |
|
Before Width: | Height: | Size: 334 B After Width: | Height: | Size: 456 B |
|
Before Width: | Height: | Size: 301 B After Width: | Height: | Size: 448 B |
|
Before Width: | Height: | Size: 301 B After Width: | Height: | Size: 448 B |
|
Before Width: | Height: | Size: 301 B After Width: | Height: | Size: 448 B |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 1.8 KiB |
BIN
images/downArrow.png
Normal file
|
After Width: | Height: | Size: 364 B |
|
Before Width: | Height: | Size: 301 B After Width: | Height: | Size: 448 B |