engine init/shutdown OSystem methods
|Reported by:||SF/knakos||Owned by:||fingolfin|
purpose: The backends get a chance to init/de-init
specifically for the engine being brought up/shutdown.
practical reasoning: The ce backend creates the audio
device just before the engine starts, so that the
mixing rate matches the ogg/mp3 playback rate,
supposedly for performance reasons. The way it was
currently being done, was that the SetWindowCaption
OSystem method (!) was overloaded. By taking a look at
RunGame, we see that it's one of the last OSystem
calls before engine->init and run. The gameid has been
set at this point, so the backend can check out what
engine is coming up. This is tacky to say the least.
Enclosing engine init+go with two system->engineinit/
done calls is much cleaner. I have no use for the
engineDone but it's there for symmetry.
possible future use: this scheme could be useful when/
if we implement the quit+return to launcher capability.
In current svn for ce, I'm still using the
windowcaption overload to cleanly build.
Ticket imported from: #1595026. Ticket imported from: patches/690.