2014-03-14 14:13:41 -04:00
|
|
|
// Copyright 1998-2014 Epic Games, Inc. All Rights Reserved.
|
|
|
|
|
|
|
|
|
|
#include "AutomationWindowPrivatePCH.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Implements the AutomationWindow module.
|
|
|
|
|
*/
|
|
|
|
|
class FAutomationWindowModule
|
|
|
|
|
: public IAutomationWindowModule
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
|
2014-06-12 23:22:18 -04:00
|
|
|
// IAutomationWindowModule interface
|
2014-03-14 14:13:41 -04:00
|
|
|
|
2014-06-13 06:14:46 -04:00
|
|
|
virtual TSharedRef<class SWidget> CreateAutomationWindow( const IAutomationControllerManagerRef& AutomationController, const ISessionManagerRef& SessionManager ) override
|
2014-03-14 14:13:41 -04:00
|
|
|
{
|
|
|
|
|
return SNew(SAutomationWindow, AutomationController, SessionManager);
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-13 06:14:46 -04:00
|
|
|
virtual TWeakPtr<class SDockTab> GetAutomationWindowTab( ) override
|
2014-03-14 14:13:41 -04:00
|
|
|
{
|
|
|
|
|
return AutomationWindowTabPtr;
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-13 06:14:46 -04:00
|
|
|
virtual FOnAutomationWindowModuleShutdown& OnShutdown( ) override
|
2014-03-14 14:13:41 -04:00
|
|
|
{
|
|
|
|
|
return ShutdownDelegate;
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-13 06:14:46 -04:00
|
|
|
virtual void SetAutomationWindowTab(TWeakPtr<class SDockTab> AutomationWindowTab) override { AutomationWindowTabPtr = AutomationWindowTab; }
|
2014-03-14 14:13:41 -04:00
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
2014-06-12 23:22:18 -04:00
|
|
|
// IModuleInterface interface
|
2014-03-14 14:13:41 -04:00
|
|
|
|
2014-06-13 06:14:46 -04:00
|
|
|
virtual void StartupModule( ) override
|
2014-03-14 14:13:41 -04:00
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-13 06:14:46 -04:00
|
|
|
virtual void ShutdownModule( ) override
|
2014-03-14 14:13:41 -04:00
|
|
|
{
|
|
|
|
|
ShutdownDelegate.ExecuteIfBound();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
|
|
// Holds the DockTab for the AutomationWindow
|
|
|
|
|
TWeakPtr<class SDockTab> AutomationWindowTabPtr;
|
|
|
|
|
|
|
|
|
|
// Holds FAutomationWindowModuleShutdownCallback
|
|
|
|
|
FOnAutomationWindowModuleShutdown ShutdownDelegate;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
2014-09-21 20:35:48 -04:00
|
|
|
IMPLEMENT_MODULE(FAutomationWindowModule, AutomationWindow);
|