mirror of
https://github.com/sparrowwallet/sparrow.git
synced 2024-11-02 20:36:44 +00:00
upgrade to javafx 22 with a minimum requirement of macos 11 and gtk3
This commit is contained in:
parent
17093dbf72
commit
49573d1075
15 changed files with 24 additions and 27 deletions
|
@ -53,7 +53,7 @@ tasks.withType(AbstractArchiveTask) {
|
||||||
}
|
}
|
||||||
|
|
||||||
javafx {
|
javafx {
|
||||||
version = "18"
|
version = headless ? "18" : "22"
|
||||||
modules = [ 'javafx.controls', 'javafx.fxml', 'javafx.swing', 'javafx.graphics' ]
|
modules = [ 'javafx.controls', 'javafx.fxml', 'javafx.swing', 'javafx.graphics' ]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -77,7 +77,7 @@ public class AddressTreeTable extends CoinTreeTable {
|
||||||
getColumns().forEach(col -> col.setContextMenu(contextMenu));
|
getColumns().forEach(col -> col.setContextMenu(contextMenu));
|
||||||
|
|
||||||
setEditable(true);
|
setEditable(true);
|
||||||
setColumnResizePolicy(TreeTableView.CONSTRAINED_RESIZE_POLICY);
|
setEqualPreferredColumnWidths();
|
||||||
|
|
||||||
addressCol.setSortType(TreeTableColumn.SortType.ASCENDING);
|
addressCol.setSortType(TreeTableColumn.SortType.ASCENDING);
|
||||||
getSortOrder().add(addressCol);
|
getSortOrder().add(addressCol);
|
||||||
|
|
|
@ -31,6 +31,7 @@ public class CoinTreeTable extends TreeTableView<Entry> {
|
||||||
private BitcoinUnit bitcoinUnit;
|
private BitcoinUnit bitcoinUnit;
|
||||||
private UnitFormat unitFormat;
|
private UnitFormat unitFormat;
|
||||||
private CurrencyRate currencyRate;
|
private CurrencyRate currencyRate;
|
||||||
|
protected static final double STANDARD_WIDTH = 100.0;
|
||||||
|
|
||||||
public BitcoinUnit getBitcoinUnit() {
|
public BitcoinUnit getBitcoinUnit() {
|
||||||
return bitcoinUnit;
|
return bitcoinUnit;
|
||||||
|
@ -143,4 +144,12 @@ public class CoinTreeTable extends TreeTableView<Entry> {
|
||||||
getSortOrder().add(column);
|
getSortOrder().add(column);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
|
protected void setEqualPreferredColumnWidths() {
|
||||||
|
for(TreeTableColumn<?, ?> column : getColumns()) {
|
||||||
|
column.setPrefWidth(STANDARD_WIDTH);
|
||||||
|
}
|
||||||
|
setColumnResizePolicy(TreeTableView.CONSTRAINED_RESIZE_POLICY);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -841,7 +841,7 @@ public class EntryCell extends TreeTableCell<Entry, Entry> implements Confirmati
|
||||||
}
|
}
|
||||||
} else if(entry instanceof WalletSummaryDialog.UnconfirmedEntry) {
|
} else if(entry instanceof WalletSummaryDialog.UnconfirmedEntry) {
|
||||||
cell.getStyleClass().add("unconfirmed-row");
|
cell.getStyleClass().add("unconfirmed-row");
|
||||||
} else if(entry instanceof WalletSummaryDialog.SummaryEntry) {
|
} else if(entry instanceof WalletSummaryDialog.SummaryEntry || entry instanceof WalletSummaryDialog.AllSummaryEntry) {
|
||||||
cell.getStyleClass().add("summary-row");
|
cell.getStyleClass().add("summary-row");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -89,7 +89,7 @@ public class SearchWalletDialog extends Dialog<Entry> {
|
||||||
results.setShowRoot(false);
|
results.setShowRoot(false);
|
||||||
results.setPrefWidth(showWallet || showAccount ? 950 : 850);
|
results.setPrefWidth(showWallet || showAccount ? 950 : 850);
|
||||||
results.setUnitFormat(walletForms.iterator().next().getWallet());
|
results.setUnitFormat(walletForms.iterator().next().getWallet());
|
||||||
results.setColumnResizePolicy(TreeTableView.CONSTRAINED_RESIZE_POLICY);
|
results.setEqualPreferredColumnWidths();
|
||||||
results.setPlaceholder(new Label("No results"));
|
results.setPlaceholder(new Label("No results"));
|
||||||
results.setEditable(true);
|
results.setEditable(true);
|
||||||
|
|
||||||
|
|
|
@ -49,7 +49,7 @@ public class TransactionsTreeTable extends CoinTreeTable {
|
||||||
|
|
||||||
setPlaceholder(getDefaultPlaceholder(rootEntry.getWallet()));
|
setPlaceholder(getDefaultPlaceholder(rootEntry.getWallet()));
|
||||||
setEditable(true);
|
setEditable(true);
|
||||||
setColumnResizePolicy(TreeTableView.CONSTRAINED_RESIZE_POLICY);
|
setEqualPreferredColumnWidths();
|
||||||
setSortColumn(0, TreeTableColumn.SortType.DESCENDING);
|
setSortColumn(0, TreeTableColumn.SortType.DESCENDING);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -82,7 +82,7 @@ public class UtxosTreeTable extends CoinTreeTable {
|
||||||
|
|
||||||
setPlaceholder(getDefaultPlaceholder(rootEntry.getWallet()));
|
setPlaceholder(getDefaultPlaceholder(rootEntry.getWallet()));
|
||||||
setEditable(true);
|
setEditable(true);
|
||||||
setColumnResizePolicy(TreeTableView.CONSTRAINED_RESIZE_POLICY);
|
setEqualPreferredColumnWidths();
|
||||||
setSortColumn(getColumns().size() - 1, TreeTableColumn.SortType.DESCENDING);
|
setSortColumn(getColumns().size() - 1, TreeTableColumn.SortType.DESCENDING);
|
||||||
|
|
||||||
getSelectionModel().setSelectionMode(SelectionMode.MULTIPLE);
|
getSelectionModel().setSelectionMode(SelectionMode.MULTIPLE);
|
||||||
|
|
|
@ -101,7 +101,7 @@ public class WalletSummaryDialog extends Dialog<Void> {
|
||||||
table.setRoot(rootItem);
|
table.setRoot(rootItem);
|
||||||
rootItem.setExpanded(true);
|
rootItem.setExpanded(true);
|
||||||
|
|
||||||
table.setColumnResizePolicy(TreeTableView.CONSTRAINED_RESIZE_POLICY);
|
table.setEqualPreferredColumnWidths();
|
||||||
table.setPrefWidth(450);
|
table.setPrefWidth(450);
|
||||||
|
|
||||||
VBox vBox = new VBox();
|
VBox vBox = new VBox();
|
||||||
|
|
|
@ -28,6 +28,7 @@ public class ServerAliasDialog extends Dialog<Server> {
|
||||||
private final TableView<ServerEntry> serverTable;
|
private final TableView<ServerEntry> serverTable;
|
||||||
private final Button closeButton;
|
private final Button closeButton;
|
||||||
|
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
public ServerAliasDialog(ServerType serverType) {
|
public ServerAliasDialog(ServerType serverType) {
|
||||||
this.serverType = serverType;
|
this.serverType = serverType;
|
||||||
|
|
||||||
|
|
|
@ -16,11 +16,6 @@
|
||||||
-fx-prompt-text-fill: gray;
|
-fx-prompt-text-fill: gray;
|
||||||
}
|
}
|
||||||
|
|
||||||
.titulo{
|
|
||||||
-fx-font-weight: bold;
|
|
||||||
-fx-font-size: 18px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.button{
|
.button{
|
||||||
-fx-focus-traversable: false;
|
-fx-focus-traversable: false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,6 +36,10 @@
|
||||||
-fx-padding: 3 5;
|
-fx-padding: 3 5;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.form .fieldset .legend, .table-view .column-header, .tree-table-view .column-header, VerticalHeader > Label {
|
||||||
|
-fx-font-weight: normal;
|
||||||
|
}
|
||||||
|
|
||||||
.form .fieldset.header .legend {
|
.form .fieldset.header .legend {
|
||||||
-fx-padding: 0 0 15px 0;
|
-fx-padding: 0 0 15px 0;
|
||||||
}
|
}
|
||||||
|
@ -247,7 +251,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.number-field {
|
.number-field {
|
||||||
-fx-font-family: 'Helvetica Neue', 'System Regular';
|
-fx-font-family: 'Helvetica Neue Regular', 'System Regular';
|
||||||
}
|
}
|
||||||
|
|
||||||
VerticalHeader > Label.selected {
|
VerticalHeader > Label.selected {
|
||||||
|
|
|
@ -50,7 +50,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.listview-label {
|
.listview-label {
|
||||||
-fx-font-weight: bold;
|
-fx-font-weight: normal;
|
||||||
-fx-font-size: 1.2em;
|
-fx-font-size: 1.2em;
|
||||||
-fx-padding: 10 0 10 0;
|
-fx-padding: 10 0 10 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
.addresses-treetable-label {
|
.addresses-treetable-label {
|
||||||
-fx-font-weight: bold;
|
-fx-font-weight: normal;
|
||||||
-fx-font-size: 1.2em;
|
-fx-font-size: 1.2em;
|
||||||
-fx-padding: 10 0 10 0;
|
-fx-padding: 10 0 10 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,9 +1,3 @@
|
||||||
.transactions-treetable-label {
|
|
||||||
-fx-font-weight: bold;
|
|
||||||
-fx-font-size: 1.2em;
|
|
||||||
-fx-padding: 10 0 10 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
#balanceChart {
|
#balanceChart {
|
||||||
-fx-padding: 10 0 0 0;
|
-fx-padding: 10 0 0 0;
|
||||||
-fx-max-width: 350px;
|
-fx-max-width: 350px;
|
||||||
|
|
|
@ -1,9 +1,3 @@
|
||||||
.utxos-treetable-label {
|
|
||||||
-fx-font-weight: bold;
|
|
||||||
-fx-font-size: 1.2em;
|
|
||||||
-fx-padding: 10 0 10 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.utxos-treetable .progress-bar > .bar {
|
.utxos-treetable .progress-bar > .bar {
|
||||||
-fx-padding: 0.6em;
|
-fx-padding: 0.6em;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue