Add close buttons to matter task monitor

This commit is contained in:
DBotThePony 2023-07-23 16:56:49 +07:00
parent 7eec1c7032
commit 8c83cce40d
Signed by: DBot
GPG Key ID: DCC23B5715498507

View File

@ -253,7 +253,7 @@ class MatterPanelScreen(
private fun openTask(task: IReplicationTask<*>): FramePanel<MatterPanelScreen> {
val frame = FramePanel.padded(this, null, 170f, 20f, TranslatableComponent("otm.gui.matter_panel.task"))
frame.closeOnEscape = true
frame.behaveAsWindow()
object : AbstractSlotPanel<MatterPanelScreen>(this@MatterPanelScreen, frame) {
init {
@ -299,7 +299,7 @@ class MatterPanelScreen(
private fun openPattern(pattern: IPatternState): FramePanel<MatterPanelScreen> {
val frame = FramePanel.padded(this, null, 213f, (ButtonPanel.HEIGHT + 3f) * 4f + 38f, TranslatableComponent("otm.gui.matter_panel.task"))
frame.closeOnEscape = true
frame.behaveAsWindow()
val rowTop = EditablePanel(this, frame, height = ButtonPanel.HEIGHT)
val rowInput = EditablePanel(this, frame, height = ButtonPanel.HEIGHT)