diff --git a/core/src/main/resources/i18n/displayStrings.properties b/core/src/main/resources/i18n/displayStrings.properties index c18e2c91fc3..7487c5fb975 100644 --- a/core/src/main/resources/i18n/displayStrings.properties +++ b/core/src/main/resources/i18n/displayStrings.properties @@ -300,6 +300,8 @@ market.trades.tooltip.candle.date=Date: offerbook.createOffer=Create offer offerbook.takeOffer=Take offer +offerbook.takeOfferToBuy=Take offer to buy {0} +offerbook.takeOfferToSell=Take offer to sell {0} offerbook.trader=Trader offerbook.offerersBankId=Maker''s bank ID (BIC/SWIFT): {0} offerbook.offerersBankName=Maker''s bank name: {0} @@ -2026,6 +2028,9 @@ popup.attention.forTradeWithId=Attention required for trade with ID {0} popup.roundedFiatValues.headline=New privacy feature: Rounded fiat values popup.roundedFiatValues.msg=To increase privacy of your trade the {0} amount was rounded.\n\nDepending on the client version you''ll pay or receive either values with decimals or rounded ones.\n\nBoth values do comply from now on with the trade protocol.\n\nAlso be aware that BTC values are changed automatically to match the rounded fiat amount as close as possible. +popup.info.multiplePaymentAccounts.headline=Multiple payment accounts available +popup.info.multiplePaymentAccounts.msg=You have multiple payment accounts available for this offer. Please make sure you've picked the right one. + #################################################################### # Notifications diff --git a/desktop/src/main/java/bisq/desktop/bisq.css b/desktop/src/main/java/bisq/desktop/bisq.css index ee5000d19b7..125ebe30ea6 100644 --- a/desktop/src/main/java/bisq/desktop/bisq.css +++ b/desktop/src/main/java/bisq/desktop/bisq.css @@ -299,11 +299,11 @@ bg color of non edit textFields: fafafa } .jfx-button:hover, .jfx-button:focused { - -fx-background-color: derive(-bs-rd-grey-light, -30%); + -fx-background-color: derive(-bs-rd-grey-light, -10%); } .action-button:hover, .action-button:focused { - -fx-background-color: derive(-bs-rd-green-dark, -30%); + -fx-background-color: derive(-bs-rd-green-dark, -10%); } .action-button { @@ -1718,9 +1718,9 @@ textfield */ -fx-text-fill: -bs-rd-white; } -#buy-button-big:hover, #buy-button:hover, +#buy-button-big:hover, #buy-button:hover, #buy-button-big:focused, #buy-button:focused { - -fx-background-color: derive(-bs-buy, -30%); + -fx-background-color: derive(-bs-buy, -10%); } #sell-button-big { @@ -1736,7 +1736,7 @@ textfield */ #sell-button-big:hover, #sell-button:hover, #sell-button-big:focused, #sell-button:focused { - -fx-background-color: derive(-bs-sell, -30%); + -fx-background-color: derive(-bs-sell, -10%); } #sell-button-big.grey-style, #buy-button-big.grey-style, diff --git a/desktop/src/main/java/bisq/desktop/main/funds/deposit/DepositView.fxml b/desktop/src/main/java/bisq/desktop/main/funds/deposit/DepositView.fxml index a90dde001df..bde328b7160 100644 --- a/desktop/src/main/java/bisq/desktop/main/funds/deposit/DepositView.fxml +++ b/desktop/src/main/java/bisq/desktop/main/funds/deposit/DepositView.fxml @@ -31,7 +31,6 @@ - diff --git a/desktop/src/main/java/bisq/desktop/main/funds/deposit/DepositView.java b/desktop/src/main/java/bisq/desktop/main/funds/deposit/DepositView.java index 1b5f4a2a35f..a20f6ee1d0c 100644 --- a/desktop/src/main/java/bisq/desktop/main/funds/deposit/DepositView.java +++ b/desktop/src/main/java/bisq/desktop/main/funds/deposit/DepositView.java @@ -20,7 +20,6 @@ import bisq.desktop.common.view.ActivatableView; import bisq.desktop.common.view.FxmlView; import bisq.desktop.components.AddressTextField; -import bisq.desktop.components.AutoTooltipButton; import bisq.desktop.components.AutoTooltipLabel; import bisq.desktop.components.HyperlinkWithIcon; import bisq.desktop.components.InputTextField; @@ -98,7 +97,7 @@ public class DepositView extends ActivatableView { @FXML TableView tableView; @FXML - TableColumn selectColumn, addressColumn, balanceColumn, confirmationsColumn, usageColumn; + TableColumn addressColumn, balanceColumn, confirmationsColumn, usageColumn; private ImageView qrCodeImageView; private AddressTextField addressTextField; private Button generateNewAddressButton; @@ -134,7 +133,6 @@ private DepositView(BtcWalletService walletService, public void initialize() { paymentLabelString = Res.get("funds.deposit.fundBisqWallet"); - selectColumn.setGraphic(new AutoTooltipLabel(Res.get("shared.select"))); addressColumn.setGraphic(new AutoTooltipLabel(Res.get("shared.address"))); balanceColumn.setGraphic(new AutoTooltipLabel(Res.get("shared.balanceWithCur", Res.getBaseCurrencyCode()))); confirmationsColumn.setGraphic(new AutoTooltipLabel(Res.get("shared.confirmations"))); @@ -152,7 +150,6 @@ public void initialize() { } }; - setSelectColumnCellFactory(); setAddressColumnCellFactory(); setBalanceColumnCellFactory(); setUsageColumnCellFactory(); @@ -342,42 +339,8 @@ public void updateItem(final DepositListItem item, boolean empty) { }); } - private void setSelectColumnCellFactory() { - selectColumn.getStyleClass().add("first-column"); - selectColumn.setCellValueFactory((addressListItem) -> - new ReadOnlyObjectWrapper<>(addressListItem.getValue())); - selectColumn.setCellFactory( - new Callback<>() { - - @Override - public TableCell call(TableColumn column) { - return new TableCell<>() { - Button button; - - @Override - public void updateItem(final DepositListItem item, boolean empty) { - super.updateItem(item, empty); - if (item != null && !empty) { - if (button == null) { - button = new AutoTooltipButton(Res.get("shared.select")); - setGraphic(button); - } - button.setOnAction(e -> tableView.getSelectionModel().select(item)); - } else { - setGraphic(null); - if (button != null) { - button.setOnAction(null); - button = null; - } - } - } - }; - } - }); - } - private void setAddressColumnCellFactory() { + addressColumn.getStyleClass().add("first-column"); addressColumn.setCellValueFactory((addressListItem) -> new ReadOnlyObjectWrapper<>(addressListItem.getValue())); addressColumn.setCellFactory( diff --git a/desktop/src/main/java/bisq/desktop/main/funds/transactions/TransactionsView.java b/desktop/src/main/java/bisq/desktop/main/funds/transactions/TransactionsView.java index fff39afdec4..65323c9e935 100644 --- a/desktop/src/main/java/bisq/desktop/main/funds/transactions/TransactionsView.java +++ b/desktop/src/main/java/bisq/desktop/main/funds/transactions/TransactionsView.java @@ -154,7 +154,6 @@ public void initialize() { tableView.setColumnResizePolicy(TableView.CONSTRAINED_RESIZE_POLICY); tableView.setPlaceholder(new AutoTooltipLabel(Res.get("funds.tx.noTxAvailable"))); - tableView.getStyleClass().add("large-rows"); setDateColumnCellFactory(); setDetailsColumnCellFactory(); diff --git a/desktop/src/main/java/bisq/desktop/main/market/spread/SpreadView.java b/desktop/src/main/java/bisq/desktop/main/market/spread/SpreadView.java index af886e3a775..167d547d48c 100644 --- a/desktop/src/main/java/bisq/desktop/main/market/spread/SpreadView.java +++ b/desktop/src/main/java/bisq/desktop/main/market/spread/SpreadView.java @@ -69,7 +69,6 @@ public SpreadView(SpreadViewModel model, BSFormatter formatter) { @Override public void initialize() { tableView = new TableView<>(); - tableView.getStyleClass().add("large-rows"); int gridRow = 0; GridPane.setRowIndex(tableView, gridRow); diff --git a/desktop/src/main/java/bisq/desktop/main/offer/offerbook/OfferBookView.java b/desktop/src/main/java/bisq/desktop/main/offer/offerbook/OfferBookView.java index d4661a64d72..4b47cedf1c7 100644 --- a/desktop/src/main/java/bisq/desktop/main/offer/offerbook/OfferBookView.java +++ b/desktop/src/main/java/bisq/desktop/main/offer/offerbook/OfferBookView.java @@ -42,6 +42,7 @@ import bisq.core.alert.PrivateNotificationManager; import bisq.core.app.AppOptionKeys; +import bisq.core.locale.CurrencyUtil; import bisq.core.locale.FiatCurrency; import bisq.core.locale.Res; import bisq.core.locale.TradeCurrency; @@ -784,7 +785,7 @@ public void updateItem(final OfferBookListItem item, boolean empty) { private TableColumn getActionColumn() { TableColumn column = new AutoTooltipTableColumn<>(Res.get("shared.actions")) { { - setMinWidth(80); + setMinWidth(200); setSortable(false); } }; @@ -803,8 +804,8 @@ public TableCell call(TableColumn onTakeOffer(offer)); } diff --git a/desktop/src/main/java/bisq/desktop/main/offer/takeoffer/TakeOfferView.java b/desktop/src/main/java/bisq/desktop/main/offer/takeoffer/TakeOfferView.java index e766e04941e..27d5d9365f1 100644 --- a/desktop/src/main/java/bisq/desktop/main/offer/takeoffer/TakeOfferView.java +++ b/desktop/src/main/java/bisq/desktop/main/offer/takeoffer/TakeOfferView.java @@ -282,17 +282,17 @@ protected void activate() { volumeDescriptionLabel.setText(model.volumeDescriptionLabel.get()); if (model.getPossiblePaymentAccounts().size() > 1) { + + new Popup<>().headLine(Res.get("popup.info.multiplePaymentAccounts.headline")) + .information(Res.get("popup.info.multiplePaymentAccounts.msg")) + .dontShowAgainId("MultiplePaymentAccountsAvailableWarning") + .show(); + PaymentAccount lastPaymentAccount = model.getLastSelectedPaymentAccount(); paymentAccountsComboBox.setItems(model.getPossiblePaymentAccounts()); paymentAccountsComboBox.getSelectionModel().select(lastPaymentAccount); model.onPaymentAccountSelected(lastPaymentAccount); paymentAccountTitledGroupBg.setText(Res.get("shared.selectTradingAccount")); - - // TODO if we have multiple payment accounts we should show some info/warning to - // make sure the user has selected the account he wants to use. - // To use a popup is not recommended as we have already 3 popups at the first time (if user has not clicked - // don't show again). - // @Christoph Maybe a similar warn triangle as used in create offer might work? } balanceTextField.setTargetAmount(model.dataModel.getTotalToPayAsCoin().get()); @@ -484,6 +484,10 @@ private void onShowPayFundsScreen() { model.onShowPayFundsScreen(); + paymentAccountsComboBox.setMouseTransparent(true); + paymentAccountsComboBox.setDisable(true); + paymentAccountsComboBox.setFocusTraversable(false); + amountTextField.setMouseTransparent(true); amountTextField.setDisable(false); amountTextField.setFocusTraversable(false); diff --git a/desktop/src/main/java/bisq/desktop/main/overlays/windows/WalletPasswordWindow.java b/desktop/src/main/java/bisq/desktop/main/overlays/windows/WalletPasswordWindow.java index 854a7c69298..c1ebb84fa5d 100644 --- a/desktop/src/main/java/bisq/desktop/main/overlays/windows/WalletPasswordWindow.java +++ b/desktop/src/main/java/bisq/desktop/main/overlays/windows/WalletPasswordWindow.java @@ -24,6 +24,7 @@ import bisq.desktop.main.overlays.Overlay; import bisq.desktop.main.overlays.popups.Popup; import bisq.desktop.util.GUIUtil; +import bisq.desktop.util.Layout; import bisq.desktop.util.Transitions; import bisq.core.btc.wallet.WalletsManager; @@ -189,7 +190,7 @@ protected void setupKeyHandler(Scene scene) { } private void addInputFields() { - passwordTextField = addPasswordTextField(gridPane, ++rowIndex, Res.get("password.enterPassword")); + passwordTextField = addPasswordTextField(gridPane, ++rowIndex, Res.get("password.enterPassword"), Layout.FLOATING_LABEL_DISTANCE); GridPane.setColumnSpan(passwordTextField, 1); GridPane.setHalignment(passwordTextField, HPos.LEFT); changeListener = (observable, oldValue, newValue) -> unlockButton.setDisable(!passwordTextField.validate()); @@ -247,7 +248,7 @@ protected void addButtons() { HBox hBox = new HBox(); hBox.setMinWidth(560); - hBox.setPadding(new Insets(15, 0, 0, 0)); + hBox.setPadding(new Insets(0, 0, 0, 0)); hBox.setSpacing(10); GridPane.setRowIndex(hBox, ++rowIndex); hBox.setAlignment(Pos.CENTER_LEFT);