Don't poll irrlicht device without graphics
It fixed crashes for joystick event which does XResetScreenSaver
This commit is contained in:
parent
310caebc34
commit
148dc49817
@ -1425,9 +1425,12 @@ namespace GUIEngine
|
|||||||
// This will avoid no response in windows, also allow showing loading
|
// This will avoid no response in windows, also allow showing loading
|
||||||
// icon in apple device, because apple device only update render
|
// icon in apple device, because apple device only update render
|
||||||
// buffer if you poll the mainloop
|
// buffer if you poll the mainloop
|
||||||
g_device->setEventReceiver(NULL);
|
if (!ProfileWorld::isNoGraphics())
|
||||||
g_device->run();
|
{
|
||||||
g_device->setEventReceiver(EventHandler::get());
|
g_device->setEventReceiver(NULL);
|
||||||
|
g_device->run();
|
||||||
|
g_device->setEventReceiver(EventHandler::get());
|
||||||
|
}
|
||||||
|
|
||||||
// If launch is finished, pause & display the story mode timers
|
// If launch is finished, pause & display the story mode timers
|
||||||
if ( !launching)
|
if ( !launching)
|
||||||
|
@ -641,8 +641,9 @@ void MainLoop::renderGUI(int phase, int loop_index, int loop_size)
|
|||||||
#ifdef SERVER_ONLY
|
#ifdef SERVER_ONLY
|
||||||
return;
|
return;
|
||||||
#else
|
#else
|
||||||
if (NetworkConfig::get()->isNetworking() &&
|
if ((NetworkConfig::get()->isNetworking() &&
|
||||||
NetworkConfig::get()->isServer() )
|
NetworkConfig::get()->isServer()) ||
|
||||||
|
ProfileWorld::isNoGraphics())
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user