iOS: don't update frames in the background
This commit is contained in:
parent
754497ede1
commit
c027a6d698
@ -595,6 +595,11 @@ void draw_load_screen(const std::wstring &text, IrrlichtDevice* device,
|
||||
gui::IGUIEnvironment* guienv, ITextureSource *tsrc,
|
||||
float dtime, int percent, bool clouds)
|
||||
{
|
||||
#ifdef __IOS__
|
||||
if (device->isWindowMinimized())
|
||||
return;
|
||||
#endif
|
||||
|
||||
video::IVideoDriver* driver = device->getVideoDriver();
|
||||
v2u32 screensize = porting::getWindowSize();
|
||||
|
||||
|
@ -4171,6 +4171,11 @@ void Game::updateFrame(ProfilerGraph *graph, RunStats *stats, f32 dtime,
|
||||
time_of_day_smooth = time_of_day_smooth * (1.0 - todsm)
|
||||
+ time_of_day * todsm;
|
||||
|
||||
#ifdef __IOS__
|
||||
if (device->isWindowMinimized())
|
||||
return;
|
||||
#endif
|
||||
|
||||
runData.time_of_day = time_of_day;
|
||||
runData.time_of_day_smooth = time_of_day_smooth;
|
||||
|
||||
|
@ -268,6 +268,11 @@ bool GUIEngine::loadMainMenuScript()
|
||||
/******************************************************************************/
|
||||
void GUIEngine::run()
|
||||
{
|
||||
#ifdef __IOS__
|
||||
if (m_device->isWindowMinimized())
|
||||
return;
|
||||
#endif
|
||||
|
||||
// Always create clouds because they may or may not be
|
||||
// needed based on the game selected
|
||||
// NO!!!
|
||||
|
Loading…
x
Reference in New Issue
Block a user