Skip to content

Commit

Permalink
Merge pull request #1775 from devinbileck/fix-take-offer-view
Browse files Browse the repository at this point in the history
Hide text that is not applicable in take offer view
  • Loading branch information
ripcurlx committed Oct 17, 2018
2 parents d33298d + 5e27cbb commit 9ce8b21
Showing 1 changed file with 11 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,10 @@ protected void activate() {
maybeShowClearXchangeWarning();

if (!model.isRange()) {
showNextStepAfterAmountIsSet();
nextButton.setVisible(false);
cancelButton1.setVisible(false);
if (model.isOfferAvailable.get())
showNextStepAfterAmountIsSet();
}

if (CurrencyUtil.isFiatCurrency(model.getOffer().getCurrencyCode())) {
Expand Down Expand Up @@ -408,6 +411,9 @@ private void onShowPayFundsScreen() {
cancelButton1.setVisible(false);
cancelButton1.setManaged(false);
cancelButton1.setOnAction(null);
offerAvailabilityBusyAnimation.stop();
offerAvailabilityLabel.setVisible(false);
offerAvailabilityLabel.setManaged(false);


model.onShowPayFundsScreen();
Expand Down Expand Up @@ -445,7 +451,6 @@ private void onShowPayFundsScreen() {
.show();
}

offerAvailabilityBusyAnimation.stop();
cancelButton2.setVisible(true);

waitingForFundsBusyAnimation.play();
Expand Down Expand Up @@ -575,8 +580,11 @@ private void addSubscriptions() {
});

isOfferAvailableSubscription = EasyBind.subscribe(model.isOfferAvailable, isOfferAvailable -> {
if (isOfferAvailable)
if (isOfferAvailable) {
offerAvailabilityBusyAnimation.stop();
if (!model.isRange() && !model.showPayFundsScreenDisplayed.get())
showNextStepAfterAmountIsSet();
}

offerAvailabilityLabel.setVisible(!isOfferAvailable);
offerAvailabilityLabel.setManaged(!isOfferAvailable);
Expand Down

0 comments on commit 9ce8b21

Please sign in to comment.