[nostalgia] Update Studio to handle tabs and open directory dialog on Mac, Update core::init

This commit is contained in:
2021-10-31 13:31:12 -05:00
parent e29f65f351
commit ad743565b2
28 changed files with 416 additions and 155 deletions
+3 -2
View File
@@ -40,9 +40,10 @@ static void initTimer() noexcept {
REG_IE = REG_IE | Int_timer0;
}
ox::Result<ox::UniquePtr<Context>> init(ox::FileSystem *fs) noexcept {
ox::Result<ox::UniquePtr<Context>> init(ox::UniquePtr<ox::FileSystem> fs, const char *appName) noexcept {
auto ctx = ox::make_unique<Context>();
ctx->rom = fs;
ctx->rom = std::move(fs);
ctx->appName = std::move(appName);
oxReturnError(initGfx(ctx.get()));
initTimer();
initIrq();
+2 -1
View File
@@ -162,7 +162,8 @@ ox::Error initConsole(Context *ctx) noexcept {
ctx = new (ox_alloca(sizeof(Context))) Context();
oxRequire(rom, loadRom());
ox::FileStore32 fs(rom, 32 * ox::units::MB);
ctx->rom = new (ox_alloca(sizeof(ox::FileSystem32))) ox::FileSystem32(fs);
auto romFs = new (ox_alloca(sizeof(ox::FileSystem32))) ox::FileSystem32(fs);
new (&ctx->rom) ox::UniquePtr<ox::FileSystem>(romFs);
}
return loadBgTileSheet(ctx, 0, TilesheetAddr, PaletteAddr);
}