fix alternating tabs with unselectable offers

This commit is contained in:
woodser 2025-05-05 22:17:32 -04:00
parent 1901a20c42
commit f2b410dd72
No known key found for this signature in database
GPG key ID: 55A10DD48ADEE5EF
4 changed files with 15 additions and 2 deletions

View file

@ -1075,6 +1075,12 @@ textfield */
-fx-background-color: -bs-color-background-table-cell-odd;
-fx-border-color: -bs-color-background-table-cell-odd;
}
.table-view .table-row-cell.row-faded .table-cell .text {
-fx-fill: -bs-color-table-cell-faded;
}
.cell-faded {
-fx-opacity: 0.4;
}
.table-view .table-row-cell:hover .table-cell,
.table-view .table-row-cell:selected .table-cell {
-fx-background: -fx-accent;

View file

@ -1119,7 +1119,12 @@ abstract public class OfferBookView<R extends GridPane, M extends OfferBookViewM
// https://github.com/bisq-network/bisq/issues/4986
if (tableRow != null) {
canTakeOfferResult = model.offerFilterService.canTakeOffer(offer, false);
tableRow.setOpacity(canTakeOfferResult.isValid() || myOffer ? 1 : 0.4);
if (canTakeOfferResult.isValid() || myOffer) {
tableRow.getStyleClass().remove("row-faded");
} else {
if (!tableRow.getStyleClass().contains("row-faded")) tableRow.getStyleClass().add("row-faded");
hbox.getStyleClass().add("cell-faded");
}
if (myOffer) {
button.setDefaultButton(false);
@ -1182,8 +1187,8 @@ abstract public class OfferBookView<R extends GridPane, M extends OfferBookViewM
button.setOnAction(null);
button2.setOnAction(null);
if (tableRow != null) {
tableRow.setOpacity(1);
tableRow.setOnMousePressed(null);
tableRow.getStyleClass().remove("row-faded");
}
}
}

View file

@ -49,6 +49,7 @@
-bs-color-background-table-header: rgb(9, 9, 9);
-bs-color-background-table-cell-even: rgb(9, 9, 9);
-bs-color-background-table-cell-odd: rgb(19, 19, 19);
-bs-color-table-cell-faded: -bs-color-gray-ccc;
/* lesser used colors */
-bs-color-blue-5: #0a4576;

View file

@ -111,6 +111,7 @@
-bs-turquoise-light: #11eeee;
-bs-color-background-table-cell-even: derive(-bs-background-color, 5%);
-bs-color-background-table-cell-odd: derive(-bs-background-color, -5%);
-bs-color-table-cell-faded: -bs-color-gray-ccc;
/* Monero orange color code */
-xmr-orange: #f26822;