mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-17 11:24:56 -04:00
eros: register key account add callbacks in postInit, fixes #37
This commit is contained in:
parent
fa84eff093
commit
129ca3f78e
@ -81,6 +81,11 @@ class MojangAddController(
|
||||
passwordFX.textProperty().addListener { _, _, _ ->
|
||||
validate()
|
||||
}
|
||||
}
|
||||
|
||||
override fun postInit() {
|
||||
super.postInit()
|
||||
|
||||
stage.scene.root.addEventFilter(KeyEvent.KEY_PRESSED) {
|
||||
if (it.code == KeyCode.ENTER) {
|
||||
login()
|
||||
|
@ -66,6 +66,11 @@ class OfflineAddController(
|
||||
usernameFX.textProperty().addListener { _, _, new ->
|
||||
addButtonFX.isDisable = !ProtocolDefinition.MINECRAFT_NAME_VALIDATOR.matcher(new).matches()
|
||||
}
|
||||
}
|
||||
|
||||
override fun postInit() {
|
||||
super.postInit()
|
||||
|
||||
stage.scene.root.addEventFilter(KeyEvent.KEY_PRESSED) {
|
||||
if (it.code == KeyCode.ENTER) {
|
||||
add()
|
||||
|
Loading…
x
Reference in New Issue
Block a user