Handles filtering and expanding a TreeView using an IFilter implementation. 更多...
#include <TreeFilterHandler.h>
Public 成员函数 | |
| bool | GetIsEnabled () |
| Gets whether or not filtering is enabled for the TreeView. | |
| void | OnGetFilteredChildren (ItemType Parent, TArray< ItemType > &FilteredChildren) |
| Gets the children for a node in the tree which pass the filter if filtering is enabled, or gets all children if the filter is not enabled. 更多... | |
| void | RefreshAndFilterTree () |
| Refreshes the associated TreeView, filtering items if the filter is enabled. 更多... | |
| void | RemoveCachedItem (ItemType ItemToRemove) |
| Removes any cached references to an item. | |
| void | SetFilter (IFilter< ItemType > *InFilter) |
| Sets the filter which will be used to filter the items in the TreeView. | |
| void | SetGetChildrenDelegate (FOnGetChildren InGetChildrenDelegate) |
| Sets the delegate which should be used for traversing the children of the nodes in the tree. | |
| void | SetIsEnabled (bool bInIsEnabled) |
| Sets whether or not filtering the tree is enabled. 更多... | |
| void | SetRootItems (TArray< ItemType > *InRootItems, TArray< ItemType > *InTreeRootItems) |
| Sets the root data arrays for the tree. 更多... | |
| void | SetTreeView (STreeView< ItemType > *InTreeView) |
| Sets the TreeView to be filtered. | |
Handles filtering and expanding a TreeView using an IFilter implementation.
|
inline |
Gets the children for a node in the tree which pass the filter if filtering is enabled, or gets all children if the filter is not enabled.
In order for filtering to work correctly this function must be used for the TreeView's OnGetChildren delegate.
|
inline |
Refreshes the associated TreeView, filtering items if the filter is enabled.
When filtering, the expanded state of the items is saved, and when the filter is cleared the pre-filter expand state is restored.
|
inline |
Sets whether or not filtering the tree is enabled.
Calling this DOES NOT refresh the tree, this must be done by calling RefreshAndFilterTree.
|
inline |
Sets the root data arrays for the tree.
| RootItems | An array of source root items to be displayed by the tree. |
| TreeRootItems | The array of root items which are set as the ItemsSource of the tree. This array will be modified to reflect any filtering. |