mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-23 03:23:17 -04:00
UnitTable close button clickHandler fix (#8573)
This commit is contained in:
parent
5335a34734
commit
c7a6082fd7
@ -82,15 +82,16 @@ class UnitTable(val worldScreen: WorldScreen) : Table() {
|
||||
|
||||
add(VerticalGroup().apply {
|
||||
pad(5f)
|
||||
|
||||
deselectUnitButton.add(ImageGetter.getImage("OtherIcons/Close")).size(20f).pad(10f)
|
||||
deselectUnitButton.pack()
|
||||
deselectUnitButton.touchable = Touchable.enabled
|
||||
deselectUnitButton.onClick {
|
||||
touchable = Touchable.enabled
|
||||
onClick {
|
||||
selectUnit()
|
||||
worldScreen.shouldUpdate = true
|
||||
this@UnitTable.isVisible = false
|
||||
}
|
||||
|
||||
deselectUnitButton.add(ImageGetter.getImage("OtherIcons/Close")).size(20f).pad(10f)
|
||||
deselectUnitButton.pack()
|
||||
deselectUnitButton.touchable = Touchable.enabled
|
||||
addActor(deselectUnitButton)
|
||||
}).left()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user