Files
UnrealEngineUWP/Engine/Source/Editor/WorldBrowser/Public/WorldBrowserModule.h
lauren ridge c8fe08076c Display of current level now is a button that allows you to change between filtered levels. Also, the level of the currently selected actor is displayed above.
#rb Jason.Stasik
#rnx

#ROBOMERGE-OWNER: ryan.gerleve
#ROBOMERGE-AUTHOR: lauren.ridge
#ROBOMERGE-SOURCE: CL 4847639 via CL 4850448 via CL 4850505
#ROBOMERGE-BOT: ENGINE (Main -> Dev-Networking)

[CL 4850845 by lauren ridge in Dev-Networking branch]
2019-01-30 18:55:16 -05:00

77 lines
2.0 KiB
C++

// Copyright 1998-2019 Epic Games, Inc. All Rights Reserved.
#pragma once
#include "CoreMinimal.h"
#include "Modules/ModuleInterface.h"
#include "Framework/MultiBox/MultiBoxBuilder.h"
#include "LevelEditor.h"
class FLevelCollectionModel;
/**
* The module holding all of the UI related pieces for SubLevels management
*/
class FWorldBrowserModule : public IModuleInterface
{
public:
/**
* Called right after the module DLL has been loaded and the module object has been created
*/
virtual void StartupModule();
/**
* Called before the module is unloaded, right before the module object is destroyed.
*/
virtual void ShutdownModule();
/**
* Creates a levels hierarchy widget
*/
virtual TSharedRef<class SWidget> CreateWorldBrowserHierarchy();
/**
* Creates a levels details widget
*/
virtual TSharedRef<class SWidget> CreateWorldBrowserDetails();
/**
* Creates a levels composition widget
*/
virtual TSharedRef<class SWidget> CreateWorldBrowserComposition();
/**
* @return world model shared between all World Browser editors
*/
virtual TSharedPtr<class FLevelCollectionModel> SharedWorldModel(UWorld* InWorld);
/**
*
*/
DECLARE_EVENT_OneParam(FWorldBrowserModule, FOnBrowseWorld, UWorld*);
FOnBrowseWorld OnBrowseWorld;
private:
void OnWorldCreated(UWorld* InWorld);
void OnWorldDestroyed(UWorld* InWorld);
void OnWorldCompositionChanged(UWorld* InWorld);
/** Bind world browser command delegate to the level viewport */
TSharedRef<FExtender> BindLevelMenu(const TSharedRef<FUICommandList> CommandList);
/** Fill out the level menu with entries for level operations */
void BuildLevelMenu(FMenuBuilder& MenuBuilder);
bool IsCurrentSublevel(ULevel* InLevel);
void SetCurrentSublevel(ULevel* InLevel);
private:
TWeakPtr<class FLevelCollectionModel> WorldModel;
/** Extender for the level menu */
FLevelEditorModule::FLevelEditorMenuExtender LevelMenuExtender;
/** Delegate called when the menu is created */
FDelegateHandle LevelMenuExtenderHandle;
};