1
0
forked from 0ad/0ad

Fix launching Atlas from the main menu

This was SVN commit r8491.
This commit is contained in:
Ykkrosh 2010-10-29 21:04:59 +00:00
parent 4f452eccde
commit 97019c3a5a
3 changed files with 19 additions and 0 deletions

View File

@ -659,6 +659,8 @@ void Shutdown(int UNUSED(flags))
ShutdownSDL();
TIMER_END(L"shutdown SDL");
g_VideoMode.Shutdown();
TIMER_BEGIN(L"shutdown ScriptingHost");
delete &g_ScriptingHost;
TIMER_END(L"shutdown ScriptingHost");

View File

@ -198,6 +198,13 @@ bool CVideoMode::InitNonSDL()
return true;
}
void CVideoMode::Shutdown()
{
debug_assert(m_IsInitialised);
m_IsInitialised = false;
}
void CVideoMode::EnableS3TC()
{
// On Linux we have to try hard to get S3TC compressed texture support.

View File

@ -35,6 +35,11 @@ public:
*/
bool InitNonSDL();
/**
* Shut down after InitSDL/InitNonSDL, so that they can be used again.
*/
void Shutdown();
/**
* Resize the SDL window and associated graphics stuff to the new size.
*/
@ -67,6 +72,11 @@ private:
bool SetVideoMode(int w, int h, int bpp, bool fullscreen);
void EnableS3TC();
/**
* Remember whether Init has been called. (This isn't used for anything
* important, just for verifying that the callers call our methods in
* the right order.)
*/
bool m_IsInitialised;
// Initial desktop settings