[nostalgia] Make core::init take FileSystem and return Context, add core::setWindowTitle
This commit is contained in:
@@ -40,11 +40,13 @@ static void initTimer() noexcept {
|
||||
REG_IE = REG_IE | Int_timer0;
|
||||
}
|
||||
|
||||
ox::Error init(Context *ctx) noexcept {
|
||||
oxReturnError(initGfx(ctx));
|
||||
ox::Result<Context> init(ox::FileSystem *fs) noexcept {
|
||||
Context ctx;
|
||||
ctx.rom = fs;
|
||||
oxReturnError(initGfx(&ctx));
|
||||
initTimer();
|
||||
initIrq();
|
||||
return OxError(0);
|
||||
return ctx;
|
||||
}
|
||||
|
||||
void setEventHandler(Context*, event_handler h) noexcept {
|
||||
|
||||
Reference in New Issue
Block a user