engine
 
载入中...
搜索中...
未找到
Public 成员函数 | 所有成员列表
IToolsContextTransactionsAPI类 参考abstract

Users of the Tools Framework need to implement IToolsContextTransactionsAPI so that the Tools have the ability to create Transactions and emit Changes. 更多...

#include <ToolContextInterfaces.h>

Public 成员函数

virtual void AppendChange (UObject *TargetObject, TUniquePtr< FToolCommandChange > Change, const FText &Description)=0
 Insert an FChange into the transaction history in the current Context. 更多...
 
virtual void BeginUndoTransaction (const FText &Description)=0
 Begin a Transaction, whatever this means in the current Context. 更多...
 
virtual void DisplayMessage (const FText &Message, EToolMessageLevel Level)=0
 Request that context display message information. 更多...
 
virtual void EndUndoTransaction ()=0
 Complete the Transaction. 更多...
 
virtual void PostInvalidation ()=0
 Forward an invalidation request from Tools framework, to cause repaint/etc. 更多...
 
virtual bool RequestSelectionChange (const FSelectedOjectsChangeList &SelectionChange)=0
 Request a modification to the current selected objects 更多...
 

详细描述

Users of the Tools Framework need to implement IToolsContextTransactionsAPI so that the Tools have the ability to create Transactions and emit Changes.

Note that this is technically optional, but that undo/redo won't be supported without it.

成员函数说明

◆ AppendChange()

virtual void IToolsContextTransactionsAPI::AppendChange ( UObject *  TargetObject,
TUniquePtr< FToolCommandChange >  Change,
const FText &  Description 
)
pure virtual

Insert an FChange into the transaction history in the current Context.

This cannot be called between Begin/EndUndoTransaction, the FChange should be automatically inserted into a Transaction.

参数
TargetObjectThe UObject this Change is applied to
ChangeThe Change implementation
Descriptiontext description of the transaction that could be shown to user

◆ BeginUndoTransaction()

virtual void IToolsContextTransactionsAPI::BeginUndoTransaction ( const FText &  Description)
pure virtual

Begin a Transaction, whatever this means in the current Context.

For example in the Editor it means open a GEditor Transaction. You must call EndUndoTransaction() after calling this.

参数
Descriptiontext description of the transaction that could be shown to user

◆ DisplayMessage()

virtual void IToolsContextTransactionsAPI::DisplayMessage ( const FText &  Message,
EToolMessageLevel  Level 
)
pure virtual

Request that context display message information.

参数
Messagetext of message
Levelseverity level of message

◆ EndUndoTransaction()

virtual void IToolsContextTransactionsAPI::EndUndoTransaction ( )
pure virtual

Complete the Transaction.

Assumption is that Begin/End are called in pairs.

◆ PostInvalidation()

virtual void IToolsContextTransactionsAPI::PostInvalidation ( )
pure virtual

Forward an invalidation request from Tools framework, to cause repaint/etc.

This is not always necessary but in some situations (eg in Non-Realtime mode in Editor) a redraw will not happen every frame. See UInputRouter for options to enable auto-invalidation.

◆ RequestSelectionChange()

virtual bool IToolsContextTransactionsAPI::RequestSelectionChange ( const FSelectedOjectsChangeList &  SelectionChange)
pure virtual

Request a modification to the current selected objects

参数
SelectionChangedesired modification to current selection
返回
true if the selection change could be applied

该类的文档由以下文件生成: