Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #3662: Malformed trade chat & dispute speech bubbles #3680

Merged

Conversation

@stejbac
Copy link
Contributor

stejbac commented Nov 25, 2019

Prevent the 'arrow' of a message bubble from being sporadically anchored to the wrong side - appearing on the left instead of the right hand side of the bubble. This is due to the same ListCell object being reused by JavaFX for different bubbles as the user scrolls up and down the chat pane, which requires that the anchors of each arrow be properly cleared between ListCell.updateItem(..) calls.

To this end, move the block of AnchorPane.clearConstraints(..) calls to the beginning of the updateItem(..) method, as the apparent assumption that updateItem(item, empty = true) will always be called to clear the given ListCell before reusing it as a new bubble turns out to be wrong.

Prevent the 'arrow' of a message bubble from being sporadically anchored
to the wrong side - appearing on the left instead of the right hand side
of the bubble. This is due to the same ListCell object being reused by
JavaFX for different bubbles as the user scrolls up and down the chat
pane, which requires that the anchors of each arrow be properly cleared
between ListCell.updateItem(..) calls.

To this end, move the block of AnchorPane.clearConstraints(..) calls to
the beginning of the updateItem(..) method, as the apparent assumption
that 'updateItem(item, empty = true)' will always be called to clear the
given ListCell before reusing it as a new bubble turns out to be wrong.
@stejbac stejbac requested review from ripcurlx and sqrrm as code owners Nov 25, 2019
Copy link
Member

freimair left a comment

utAck

@freimair freimair mentioned this pull request Nov 26, 2019
Copy link
Member

ripcurlx left a comment

utACK - Agree that it is safer to do it like that and that it will fix any constraints issues.

@ripcurlx ripcurlx merged commit c705853 into bisq-network:master Nov 26, 2019
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@stejbac stejbac mentioned this pull request Dec 13, 2019
@ripcurlx ripcurlx mentioned this pull request Dec 13, 2019
@stejbac stejbac mentioned this pull request Jan 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.