void CGUIDialog::updateBackground()
{
	if( g_pBehaviorEngine->getEngine() == ENGINE_VORTICON )
	{
        initVorticonBackground();
	}
	else if( g_pBehaviorEngine->getEngine() == ENGINE_GALAXY )
	{
        initGalaxyBackround();
	}
	else
	{
		initEmptyBackround();
	}
}
Beispiel #2
0
void CGUIDialog::initBackground()
{
	if( g_pBehaviorEngine->getEngine() == ENGINE_VORTICON )
	{
		const SDL_Rect lRect = g_pVideoDriver->toBlitRect(mRect);
		mpBackgroundSfc.reset( CG_CreateRGBSurface( lRect ), &SDL_FreeSurface );
		mpBackgroundSfc.reset( SDL_DisplayFormat( mpBackgroundSfc.get() ), &SDL_FreeSurface );
		initVorticonBackground( lRect );
	}
	else if( g_pBehaviorEngine->getEngine() == ENGINE_GALAXY )
	{
		const SDL_Rect lRect = g_pVideoDriver->getGameResolution().SDLRect();
		mpBackgroundSfc.reset( CG_CreateRGBSurface( lRect ), &SDL_FreeSurface );
		mpBackgroundSfc.reset( SDL_DisplayFormat( mpBackgroundSfc.get() ), &SDL_FreeSurface );
		initGalaxyBackround( lRect );
	}
	else
	{
		const SDL_Rect lRect = g_pVideoDriver->toBlitRect(mRect);
		mpBackgroundSfc.reset( CG_CreateRGBSurface( lRect ), &SDL_FreeSurface );
		mpBackgroundSfc.reset( SDL_DisplayFormat( mpBackgroundSfc.get() ), &SDL_FreeSurface );
		initEmptyBackround();
	}
}
CMessageBoxVort::CMessageBoxVort(const std::string& Text, bool lower, bool keymsg, bool leftbound) :
CMessageBox(Text, lower, keymsg, leftbound, CGUIDialog::EXPAND)
{
   initVorticonBackground();   
}