use of bisq.common.util.Tuple3 in project bisq-desktop by bisq-network.
the class FormBuilder method getEditableValueCurrencyBox.
// /////////////////////////////////////////////////////////////////////////////////////////
// Trade: HBox, InputTextField, Label
// /////////////////////////////////////////////////////////////////////////////////////////
public static Tuple3<HBox, InputTextField, Label> getEditableValueCurrencyBox(String promptText) {
InputTextField input = new InputTextField();
input.setPrefWidth(170);
input.setAlignment(Pos.CENTER_RIGHT);
input.setId("text-input-with-currency-text-field");
input.setPromptText(promptText);
Label currency = new AutoTooltipLabel(Res.getBaseCurrencyCode());
currency.setId("currency-info-label");
HBox box = new HBox();
box.getChildren().addAll(input, currency);
return new Tuple3<>(box, input, currency);
}
use of bisq.common.util.Tuple3 in project bisq-desktop by bisq-network.
the class FormBuilder method addHBoxLabelComboBox.
// /////////////////////////////////////////////////////////////////////////////////////////
// HBox + AutoTooltipLabel + ComboBox
// /////////////////////////////////////////////////////////////////////////////////////////
public static Tuple3<HBox, AutoTooltipLabel, ComboBox> addHBoxLabelComboBox(GridPane gridPane, int rowIndex, String title, double top) {
HBox hBox = new HBox();
hBox.setAlignment(Pos.CENTER_LEFT);
hBox.setSpacing(4);
final AutoTooltipLabel label = new AutoTooltipLabel(title);
final ComboBox<Object> comboBox = new ComboBox<>();
hBox.getChildren().addAll(label, comboBox);
GridPane.setRowIndex(hBox, rowIndex);
GridPane.setColumnSpan(hBox, 2);
GridPane.setMargin(hBox, new Insets(top, 0, 0, 24));
gridPane.getChildren().add(hBox);
return new Tuple3<>(hBox, label, comboBox);
}
Aggregations