diff --git a/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/adapter/BankAccountsAdapter.kt b/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/adapter/BankAccountsAdapter.kt index 6c0c075e..645bfbfc 100644 --- a/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/adapter/BankAccountsAdapter.kt +++ b/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/adapter/BankAccountsAdapter.kt @@ -1,9 +1,11 @@ package net.dankito.banking.ui.android.adapter import android.content.Context +import android.net.Uri import android.view.LayoutInflater import android.view.View import android.view.ViewGroup +import android.widget.ImageView import kotlinx.android.synthetic.main.list_item_bank_account.view.* import net.dankito.banking.ui.android.R import net.dankito.banking.ui.model.BankAccount @@ -21,9 +23,21 @@ open class BankAccountsAdapter(bankAccounts: List) : ListAdapter - + + + + \ No newline at end of file + /> + + \ No newline at end of file diff --git a/ui/BankingAndroidApp/src/main/res/values/dimens.xml b/ui/BankingAndroidApp/src/main/res/values/dimens.xml index 8fd23860..1d522017 100644 --- a/ui/BankingAndroidApp/src/main/res/values/dimens.xml +++ b/ui/BankingAndroidApp/src/main/res/values/dimens.xml @@ -51,7 +51,10 @@ 6dp 120dp + 26dp 4dp + 16dp + 8dp 13sp 60dp diff --git a/ui/BankingJavaFxControls/src/main/kotlin/net/dankito/banking/ui/javafx/dialogs/cashtransfer/TransferMoneyDialog.kt b/ui/BankingJavaFxControls/src/main/kotlin/net/dankito/banking/ui/javafx/dialogs/cashtransfer/TransferMoneyDialog.kt index 579f7a61..d5830c14 100644 --- a/ui/BankingJavaFxControls/src/main/kotlin/net/dankito/banking/ui/javafx/dialogs/cashtransfer/TransferMoneyDialog.kt +++ b/ui/BankingJavaFxControls/src/main/kotlin/net/dankito/banking/ui/javafx/dialogs/cashtransfer/TransferMoneyDialog.kt @@ -7,6 +7,8 @@ import javafx.beans.property.SimpleStringProperty import javafx.collections.FXCollections import javafx.geometry.Insets import javafx.geometry.Pos +import javafx.scene.control.ContentDisplay +import javafx.scene.image.ImageView import javafx.scene.layout.Priority import net.dankito.banking.ui.javafx.dialogs.JavaFxDialogService import net.dankito.banking.ui.model.BankAccount @@ -33,6 +35,8 @@ open class TransferMoneyDialog @JvmOverloads constructor( private val FieldHeight = 40.0 private val TextFieldHeight = 32.0 + private const val BankIconSize = 24.0 + private val ButtonHeight = 40.0 private val ButtonWidth = 150.0 } @@ -96,6 +100,20 @@ open class TransferMoneyDialog @JvmOverloads constructor( combobox(selectedBankAccount, bankAccountsSupportingTransferringMoney) { fixedHeight = TextFieldHeight + + cellFormat { + text = it.displayNameIncludingBankName + + it.account.bank.iconUrl?.let { iconUrl -> + graphic = ImageView(iconUrl)?.apply { + this.fitHeight = BankIconSize + this.fitWidth = BankIconSize + this.isPreserveRatio = true + } + contentDisplay = ContentDisplay.LEFT + } + ?: run { contentDisplay = ContentDisplay.TEXT_ONLY } + } } vboxConstraints {