|
|
|
@ -132,6 +132,19 @@ extern void selectTipsOfTheDay (uint tips);
|
|
|
|
|
// FUNCTIONS //
|
|
|
|
|
///////////////
|
|
|
|
|
|
|
|
|
|
// ***************************************************************************
|
|
|
|
|
// Saving ingame resolution when in windowed mode
|
|
|
|
|
static void saveIngameResolution()
|
|
|
|
|
{
|
|
|
|
|
if (ClientCfg.Windowed)
|
|
|
|
|
{
|
|
|
|
|
uint32 width, height;
|
|
|
|
|
Driver->getWindowSize(width, height);
|
|
|
|
|
ClientCfg.writeInt("Width", std::max((sint)width, 800));
|
|
|
|
|
ClientCfg.writeInt("Height", std::max((sint)height, 600));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ***************************************************************************
|
|
|
|
|
// 3D element release, called from both releaseMainLoopReselect() and releaseMainLoop()
|
|
|
|
|
static void releaseMainLoopScenes()
|
|
|
|
@ -209,6 +222,8 @@ void releaseMainLoopReselect()
|
|
|
|
|
{
|
|
|
|
|
ProgressBar.release();
|
|
|
|
|
|
|
|
|
|
saveIngameResolution();
|
|
|
|
|
|
|
|
|
|
CInterfaceManager *pIM= CInterfaceManager::getInstance();
|
|
|
|
|
|
|
|
|
|
// save keys loaded and interface cfg (not done in releaseMainLoop() because done at end of mainLoop()...)
|
|
|
|
@ -364,6 +379,8 @@ void releaseMainLoop(bool closeConnection)
|
|
|
|
|
{
|
|
|
|
|
ProgressBar.release();
|
|
|
|
|
|
|
|
|
|
saveIngameResolution();
|
|
|
|
|
|
|
|
|
|
// Release R2 editor if applicable
|
|
|
|
|
R2::getEditor().autoConfigRelease(IsInRingSession);
|
|
|
|
|
|
|
|
|
|