mirror of
https://github.com/bitcoin-s/bitcoin-s.git
synced 2024-11-19 18:02:54 +01:00
Update balance on cancel DLC (#3205)
This commit is contained in:
parent
4efe88fcba
commit
1af9465881
@ -54,8 +54,8 @@ abstract class WalletGUI {
|
||||
" sats")
|
||||
}
|
||||
|
||||
private lazy val dlcPane = new DLCPane(glassPane)
|
||||
private lazy val model = new WalletGUIModel(dlcPane.model)
|
||||
private[gui] lazy val dlcPane = new DLCPane(glassPane)
|
||||
private[gui] lazy val model = new WalletGUIModel(dlcPane.model)
|
||||
|
||||
private lazy val balanceBox = new VBox {
|
||||
spacing = 10
|
||||
|
@ -119,7 +119,7 @@ class WalletGUIModel(dlcModel: DLCPaneModel)(implicit system: ActorSystem) {
|
||||
}
|
||||
}
|
||||
|
||||
private def updateBalance(): Unit = {
|
||||
private[gui] def updateBalance(): Unit = {
|
||||
ConsoleCli.exec(GetBalances(isSats = true),
|
||||
GlobalData.consoleCliConfig) match {
|
||||
case Success(commandReturn) =>
|
||||
|
@ -8,7 +8,8 @@ import org.bitcoins.core.protocol.dlc.models._
|
||||
import org.bitcoins.crypto._
|
||||
import org.bitcoins.gui.dlc.GlobalDLCData.dlcs
|
||||
import org.bitcoins.gui.dlc.dialog._
|
||||
import org.bitcoins.gui.{GlobalData, TaskRunner}
|
||||
import org.bitcoins.gui._
|
||||
import scalafx.application.Platform
|
||||
import scalafx.beans.property.ObjectProperty
|
||||
import scalafx.scene.control.Alert.AlertType
|
||||
import scalafx.scene.control.{Alert, ButtonType, TextArea}
|
||||
@ -229,6 +230,7 @@ class DLCPaneModel(resultArea: TextArea) extends Logging {
|
||||
case Failure(err) => throw err
|
||||
}
|
||||
updateDLCs()
|
||||
Platform.runLater(GUI.model.updateBalance())
|
||||
}
|
||||
)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user