Exemplo n.º 1
0
State::~State()
{
    UnregisterAllListeners();

    delete m_data[StateId_WindowSize].pLock;
    delete m_data[StateId_FgColor].pLock;
    delete m_data[StateId_BgColor].pLock;
    delete m_data[StateId_Brush].pLock;
    delete m_data[StateId_Font].pLock;
    delete m_data[StateId_Pen].pLock;
    delete m_data[StateId_ScrollVelocity].pLock;
    delete m_data[StateId_KineticScrollAcceleration].pLock;
    delete m_data[StateId_KineticScrollActivateVelocity].pLock;
}
Exemplo n.º 2
0
bool FLiveEditorManager::DeActivate( const FString &Name )
{
	RealWorld = GWorld;
	check( LiveEditorWorld != NULL );
	GWorld = LiveEditorWorld;

	bool bSuccess = false;

	ULiveEditorBlueprint *BP = FindActiveBlueprint(Name);
	if ( BP != NULL )
	{
		UnregisterAllListeners(BP);
		BP->OnShutdown();
		//BP->MarkPendingKill(); TODO how do we delete this without crashing?
	
		int32 i = 0;
		while( i < ActiveBlueprints.Num() )
		{
			if ( ActiveBlueprints[i].Blueprint.Get() == BP )
			{
				ActiveBlueprints.RemoveAtSwap(i);
				continue;
			}
			else
			{
				++i;
			}
		}

		bSuccess = true;
	}

	GWorld = RealWorld;
	RealWorld = NULL;

	return bSuccess;
}