mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-03-13 19:39:04 +07:00
2-column sector button layout
This commit is contained in:
parent
8fd08a1574
commit
82577b91d5
@ -47,15 +47,22 @@ public class SectorsDialog extends FloatingDialog{
|
||||
content().row();
|
||||
content().add(new SectorView()).grow();
|
||||
content().row();
|
||||
|
||||
buttons().addImageTextButton("$text.sector.abandon", "icon-cancel", 16*2, () ->
|
||||
ui.showConfirm("$text.confirm", "$text.sector.abandon.confirm", () -> world.sectors.abandonSector(selected)))
|
||||
.size(200f, 64f).disabled(b -> selected == null || !selected.hasSave());
|
||||
|
||||
buttons().row();
|
||||
|
||||
buttons().addImageTextButton("$text.sector.deploy", "icon-play", 10*3, () -> {
|
||||
hide();
|
||||
ui.loadLogic(() -> world.sectors.playSector(selected));
|
||||
}).size(210f, 64f).disabled(b -> selected == null)
|
||||
.update(t -> t.setText(selected != null && selected.hasSave() ? "$text.sector.resume" : "$text.sector.deploy"));
|
||||
}).disabled(b -> selected == null)
|
||||
.fillX().height(64f).colspan(2).update(t -> t.setText(selected != null && selected.hasSave() ? "$text.sector.resume" : "$text.sector.deploy"));
|
||||
|
||||
|
||||
|
||||
|
||||
buttons().addImageTextButton("$text.sector.abandon", "icon-cancel", 16*2, () ->
|
||||
ui.showConfirm("$text.confirm", "$text.sector.abandon.confirm", () -> world.sectors.abandonSector(selected)))
|
||||
.size(210f, 64f).disabled(b -> selected == null || !selected.hasSave());
|
||||
}
|
||||
|
||||
void selectSector(Sector sector){
|
||||
|
Loading…
Reference in New Issue
Block a user