mirror of
https://github.com/libSDL2pp/libSDL2pp.git
synced 2025-08-04 03:15:59 -04:00
Implement init/deinit/check of separate SDL subsystems
This commit is contained in:
parent
d4426eb36a
commit
dfb464ea7b
@ -35,4 +35,17 @@ SDL::~SDL() {
|
|||||||
SDL_Quit();
|
SDL_Quit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Uint32 WasInit(Uint32 flags) {
|
||||||
|
return SDL_WasInit(flags);
|
||||||
|
}
|
||||||
|
|
||||||
|
void InitSubsystem(Uint32 flags) {
|
||||||
|
if (SDL_InitSubSystem(flags) != 0)
|
||||||
|
throw Exception("SDL_InitSubsystem failed");
|
||||||
|
}
|
||||||
|
|
||||||
|
void QuitSubSystem(Uint32 flags) {
|
||||||
|
SDL_QuitSubSystem(flags);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -35,6 +35,10 @@ public:
|
|||||||
SDL(SDL&& other) = delete;
|
SDL(SDL&& other) = delete;
|
||||||
SDL& operator=(const SDL& other) = delete;
|
SDL& operator=(const SDL& other) = delete;
|
||||||
SDL& operator=(SDL&& other) = delete;
|
SDL& operator=(SDL&& other) = delete;
|
||||||
|
|
||||||
|
Uint32 WasInit(Uint32 flags);
|
||||||
|
void InitSubSystem(Uint32 flags);
|
||||||
|
void QuitSubSystem(Uint32 flags);
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user