move window handling to its own class #121
Yeah, this looks good, IMHO. I like it.
I especially like the use of an enum for the renderer type; that's probably what I should have done in the first place, yes.
Two things I noticed (but are not a fault of your code, just general observations for the TODO list):
Do you want this to be merged now or should this wait for after @mirv-sillyfish's stuff? #123 rebases cleanly (with an automatic 3-way merge) on top of this change, but then needs a little fix in graphics.cpp to replace _width/_height by WindowMan.getWindowWidth()/WindowMan.getWindowHeight() to make it compile again.
This class does a few things differently to their current implementation in GfxMan. Notably it fixes the following flaws in the current implementation: * Switching from FS to windowed mode didnt work * Resolution switching in FS mode didnt work * Max FSAA level would always be determined to be 16x * Error handling was missing or wrong
I did, however, remove the SDL_WINDOW_RESIZABLE flag since it's currently not working anyway. I added "Let the user resize the xoreos window" as a TODO. If you have a working implementation, please do a PR for it. I'm really not sure how well it'll work though, what with OpenGL needing to be recreated for every change, but yeah, if I see it working, sure.
Also note that Sonic, as a Nintendo DS game, is inherently fixed-size. Currently, the engine code even overrides a user config choice there. In the future, we might add something to scale the 2D images? But even that would probably work best in full integer steps. So an engine might explictly want to disable user scaling.