Add close all windows on exit and fixed remove row from mm doc app

This commit is contained in:
Willem Cazander 2025-02-03 23:48:59 +01:00
parent 0bee837b52
commit d146d5aed8
5 changed files with 24 additions and 6 deletions

View file

@ -150,6 +150,7 @@ public abstract class AbstractScreenDesktop extends ScreenAdapter implements Des
batch.dispose();
font.dispose();
modelBatch.dispose();
deskAppScreen.dispose();
disposeDesktop();
}

View file

@ -66,7 +66,6 @@ public class ScreenDesktop1 extends AbstractScreenDesktop {
public ScreenDesktop1(SystemGdxBootArgs bootArgs, SystemGdxTerminal terminal, VrGem4DeskAppService deskAppService) {
super("Desktop1", bootArgs, terminal, deskAppService);
}
protected void createModel(ModelBuilder modelBuilder, Array<ModelInstance> modelInstances) {

View file

@ -105,4 +105,12 @@ public class DeskAppController {
protected void renderBackground() {
}
public final void dispose() {
for (DeskApp app : deskApps) {
app.exit();
}
deskApps.clear();
currentDeskApp = null;
}
}

View file

@ -57,9 +57,9 @@ import ᒢᐩᐩ.ᔆʸᔆᐪᓫᔿ.ᒃᣔᒃᓫᒻ.ᑊᐣᓑᖮᐪᔆ.DuytsDocAu
@DuytsDocAuthor注(name = "للَّٰهِilLצسُو", copyright = "©Δ∞ 仙上主天")
public class DeskTopScreenMenu {
private SystemGdxBootArgs bootArgs;
private SystemGdxTerminal terminal;
private VrGem4DeskAppService deskAppService;
private final SystemGdxBootArgs bootArgs;
private final SystemGdxTerminal terminal;
private final VrGem4DeskAppService deskAppService;
private ImBoolean fileMinimizeSelected = new ImBoolean(false);
private ImBoolean fileCloseSelected = new ImBoolean(false);
private ImBoolean tosSelfSelected = new ImBoolean(false);
@ -70,7 +70,7 @@ public class DeskTopScreenMenu {
this.terminal = terminal;
this.deskAppService = deskAppService;
}
public void renderMenu(DeskTopScreen appScreen) {
DeskApp deskApp = appScreen.getDeskAppController().getCurrentDeskApp();