Skip to content

Conversation

@10xcryptodev
Copy link

Apply the changes suggested on #3241

@UdjinM6
Copy link

UdjinM6 commented Apr 19, 2020

Looks good code-wise but I don't like the new layout tbh.

@10xcryptodev
Copy link
Author

@UdjinM6 agree with you. Another suggestion that i thought is use the old layout, remove the PrivateSend checkbox and add the option in confirmation dialog Yes (PrivateSend). It will be cleaner and the user will always see the option before send

@UdjinM6
Copy link

UdjinM6 commented Apr 20, 2020

Simply removing PS checkbox won't work because:

  • it also switches "Balance" from "All" to "PS only" numbers, you'd have to show both balances if you remove it;
  • it affects numbers in CoinControl labels (PS txes can't have change, "fee"/"after fee" are adjusted accordingly), duplicating these would be a mess.

IMO the GUI is already pretty clear + there is another label about funds you are going to use (mixed/no-mixed) in confirmation box. The only possible tweak I can think about is that we could add another button "PrivateSend" right next to "Send" which would internally call the same on_sendButton_clicked() but would be disabled if PS checkbox is off (and "Send" would be disabled if PS checkbox is on). Not sure if that would it make things clearer or the other way around though.

@10xcryptodev
Copy link
Author

@UdjinM6 PrivateSend changes the available balance and inputs, so it should be the first step the user should choose. I thought 2 possibilities:

  1. Create a new PrivateSend tab between Send and Receive that will use the same UI (sendcoinsdialog.ui) and behind will act "as the checkbox is activated"
  2. Ask the user when enter the Send tab if want to Send or PrivateSend using a confirmation dialog, the checkbox could stay at the same place, but the user will always be asked the option

Personally i prefer the first option, it will be clear and simple and give us more possibilities if we want to add more PrivateSend features in the future

@UdjinM6
Copy link

UdjinM6 commented Apr 21, 2020

Hmm.... yeah, I would probably go with (1) assuming it's going to reuse the same code/ui.

@10xcryptodev
Copy link
Author

@UdjinM6 implemented the number 1 solution, reusing the same UI

Copy link

@UdjinM6 UdjinM6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have one question/change request and still kind of on the fence if new UI looks better or not but otherwise code changes look good IMO 👍

PS. and it works as expected as far as I can tell.

UdjinM6
UdjinM6 previously approved these changes Apr 24, 2020
Copy link

@UdjinM6 UdjinM6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK

@PastaPastaPasta
Copy link
Member

Could we get some screen-shots of the new format etc?

Copy link
Member

@PastaPastaPasta PastaPastaPasta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some formatting nits

@10xcryptodev
Copy link
Author

10xcryptodev commented Apr 27, 2020

@PastaPastaPasta code formating updated

Screenshots:
Screenshot from 2020-04-26 21-34-11

New PrivateSend tab, shows only the mixed balance and mixed outputs in coin control
Screenshot from 2020-04-26 21-34-54

This way will be clear for the user that is using PrivateSend in his first action selecting the type of sending. Also before this change, the user could select PrivateSend checkbox and select a not mixed output in coin control, that could cause confusion too.

PS.: Didn't finished the mixing on my test wallet, it's a good test to do. I will finish the mixing process and see

@UdjinM6
Copy link

UdjinM6 commented Apr 27, 2020

Also before this change, the user could select PrivateSend checkbox and select a not mixed output in coin control, that could cause confusion too.

We have a warning for this case https://github.com/dashpay/dash/blob/develop/src/qt/coincontroldialog.cpp#L430-L436 (which I think can be dropped now btw since this should be no longer possible) but it's much better to hide non-mixed inputs completely, I like that.

@UdjinM6
Copy link

UdjinM6 commented Apr 27, 2020

Hmm... Interesting. So switching from Send to PrivateSend tab with non-mixed inputs selected via CoinControl on the former results in some new confusing situation when it says N inputs selected but you can't see them cause they are not in the list. 🤔 PS would still fail as it should saying "not enough mixed funds" so it's not that bad but maybe we could also clear non-mixed inputs from selection when CoinControl is opened via PS tab?

@10xcryptodev
Copy link
Author

@UdjinM6 great! I will check to clear the selections when changing the tab and remove the unnecessary warning

@10xcryptodev
Copy link
Author

@UdjinM6 reviewed the points about clear selected outputs and warning message

@UdjinM6
Copy link

UdjinM6 commented Apr 29, 2020

Hmm... clear() is pretty disruptive (imagine filling 10 recipients and then switching tabs accidentally). I was thinking about smth like 803f029a8c (and maybe smth like a00c2e98 on top cause silently dropping coins from selection feels kind of weird).

@10xcryptodev
Copy link
Author

@UdjinM6 thanks for the contribution, tested and agreed with the better UX. Added the suggested commits

@PastaPastaPasta
Copy link
Member

test failure looks unrelated, can you force-push and hopefully CI will be happy

@10xcryptodev 10xcryptodev force-pushed the pr_fix_privatesend_location branch from e512189 to 37b7445 Compare May 2, 2020 01:48
@10xcryptodev
Copy link
Author

@PastaPastaPasta passed CI check now

@UdjinM6
Copy link

UdjinM6 commented May 2, 2020

Found another issue - when running with --enableprivatesend=0 the PS tab shows "Balance: 0" yet it allows to send PS txes. I think it makes sense to disable the tab (and the corresponding icon/tray menu item) in this case i.e. ef3f107344.

@10xcryptodev
Copy link
Author

@UdjinM6 good catch! also tested with -litemode and it's ok. Added the suggestion

UdjinM6
UdjinM6 previously approved these changes May 10, 2020
Copy link

@UdjinM6 UdjinM6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK

@UdjinM6 UdjinM6 requested a review from PastaPastaPasta May 11, 2020 12:29
@PastaPastaPasta PastaPastaPasta linked an issue May 11, 2020 that may be closed by this pull request
@PastaPastaPasta
Copy link
Member

Will review in the next few days

@PastaPastaPasta
Copy link
Member

Started a review, when clicking on "PrivateSend" it doesn't become bold and unbold the prior.
dash-core-pr_3442

@PastaPastaPasta
Copy link
Member

Also, "Use available balance" button doesn't work properly

@10xcryptodev
Copy link
Author

@PastaPastaPasta rebase done 👍

@PastaPastaPasta
Copy link
Member

PastaPastaPasta commented May 14, 2020

Man you must be really unlucky, cause there are still test failures that seem unrelated

@UdjinM6 UdjinM6 added this to the 16 milestone May 14, 2020
Copy link
Member

@PastaPastaPasta PastaPastaPasta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

reACK: 791908e
light code review utACK: b373b33

Copy link

@UdjinM6 UdjinM6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Slightly tested ACK

@PastaPastaPasta
Copy link
Member

test passed this time 👍

@10xcryptodev
Copy link
Author

Lucky now 😆

@UdjinM6 UdjinM6 changed the title #3241 UX/UI - change PrivateSend and balance location #3241 UX/UI - Introduce PrivateSend tab which allows to spend fully mixed coins only May 14, 2020
@UdjinM6 UdjinM6 changed the title #3241 UX/UI - Introduce PrivateSend tab which allows to spend fully mixed coins only Fix #3241 UX/UI - Introduce PrivateSend tab which allows to spend fully mixed coins only May 15, 2020
@UdjinM6 UdjinM6 merged commit 4c1f65b into dashpay:develop May 15, 2020
gades pushed a commit to cosanta/cosanta-core that referenced this pull request Feb 16, 2022
…end fully mixed coins only (dashpay#3442)

* dashpay#3241 change PrivateSend and balance location

* include resource location back

* change back balance and privatesend checkbox position

* add new PrivateSend tab on main window and PrivateSend tray option

* adjust code formating

* revert QT TODO

* Update src/qt/forms/sendcoinsdialog.ui code formating

Co-Authored-By: UdjinM6 <UdjinM6@users.noreply.github.com>

* code formating update

* clear send dialog and remove unnecessary warning

* change clear location for better UX and performance

* remove variable used in warning

* Do not clear everything, simply unselect non-fully-mixes coins instead

Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>

* Warn about unselected coins

Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>

* Disable PrivateSend tab/menu item when PrivateSend is disabled

Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>

* fix tab selection bold font

* fix use available balance for PS

* change back line

Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0.15.0.0-rc1 UI/UX Send tab move Privatesend checkbox

3 participants