![]() |
Blamite Game Engine - Keystone
00326.06.27.21.0407.blamite
A library that enables the use of Qt in Blamite's editing tools.
|
#include <treewidget.h>
Public Member Functions | |
BlamExplorerBarTreeWidget (BlamEditorWindow *main_window, BlamEditorToolWindow *_tool_window, BlamProject *_project, bool hierarchy=true) | |
Creates a new Tree Widget for the Guerilla Explorer Bar. More... | |
BlamExplorerBarTreeWidget (BlamEditorWindow *main_window, BlamEditorToolWindow *_tool_window, BlamTagTreeNode *node, bool hierarchy, BlamProject *_project=nullptr) | |
Creates a new Tree Widget for the Guerilla Explorer Bar. More... | |
BlamExplorerBarTreeWidget (BlamEditorWindow *main_window, BlamEditorToolWindow *_tool_window, BlamPlugin *_plugin) | |
Creates a new Tree Widget for the Guerilla Explorer Bar. More... | |
~BlamExplorerBarTreeWidget () | |
Destructor which releases all pointers if they are still loaded. More... | |
bool | IsValid () |
Checks whether the node is valid. More... | |
void | Refresh () |
Refreshes all data relating to this node. More... | |
void | UpdateIcon () |
Updates the node's icon. More... | |
void | OpenTag () |
This will open the tag associated with the node, if one is present. More... | |
void | OpenBackupTag () |
This will open the backup tag associated with this node. More... | |
void | Filter (std::string search_filter, bool keep_empty_folders) |
Instructs the tree node to filter out any child items that do not contain a specified string. More... | |
void | ShowInformationDialog () |
Shows the tag information dialog. More... | |
Public Attributes | |
BlamTagTreeNode * | tag_node = nullptr |
The node associated with this widget. More... | |
BlamExplorerBarTreeWidget::BlamExplorerBarTreeWidget | ( | BlamEditorWindow * | main_window, |
BlamEditorToolWindow * | _tool_window, | ||
BlamProject * | _project, | ||
bool | hierarchy = true |
||
) |
Creates a new Tree Widget for the Guerilla Explorer Bar.
This override should ONLY be used for the root of a given project or tag folder, as it is treated differently from child nodes.
main_window | - Pointer to main editor window. |
_tool_window | - Pointer to explorer bar tool window. |
_project | - The project that this node will generate children from. |
hierarchy | - Whether or not the explorer is in hierarchy mode. Defaults to true . |
BlamExplorerBarTreeWidget::BlamExplorerBarTreeWidget | ( | BlamEditorWindow * | main_window, |
BlamEditorToolWindow * | _tool_window, | ||
BlamTagTreeNode * | node, | ||
bool | hierarchy, | ||
BlamProject * | _project = nullptr |
||
) |
Creates a new Tree Widget for the Guerilla Explorer Bar.
This override should be used for all non-root tree widgets.
main_window | - Pointer to main editor window. |
_tool_window | - Pointer to explorer bar tool window. |
node | - The node that this tree widget represents. |
hierarchy | - Whether or not the explorer is in hierarchy mode. Will use class view if this is false. |
_project | - The project that the node belongs to. Defaults to nullptr , although this is considered invalid. |
BlamExplorerBarTreeWidget::BlamExplorerBarTreeWidget | ( | BlamEditorWindow * | main_window, |
BlamEditorToolWindow * | _tool_window, | ||
BlamPlugin * | _plugin | ||
) |
Creates a new Tree Widget for the Guerilla Explorer Bar.
This override is used specifically for creating containers for tag classes when the explorer is in class view.
main_window | - Pointer to main editor window. |
_tool_window | - Pointer to explorer bar tool window. |
plugin | - Pointer to plugin that this node represents. |
BlamExplorerBarTreeWidget::~BlamExplorerBarTreeWidget | ( | ) |
Destructor which releases all pointers if they are still loaded.
void BlamExplorerBarTreeWidget::Filter | ( | std::string | search_filter, |
bool | keep_empty_folders | ||
) |
Instructs the tree node to filter out any child items that do not contain a specified string.
search_filter | - The search filter to check against. |
keep_empty_folders | - Whether or not to preserve empty folders. |
bool BlamExplorerBarTreeWidget::IsValid | ( | ) |
Checks whether the node is valid.
If all data associated with this tree node is valid, this will return true.
true
if the node data is valid, otherwise returns false
. void BlamExplorerBarTreeWidget::OpenBackupTag | ( | ) |
This will open the backup tag associated with this node.
This is done by checking if a file of the same path exists with a .bak
file extension. If there is no backup file, this will do nothing.
void BlamExplorerBarTreeWidget::OpenTag | ( | ) |
This will open the tag associated with the node, if one is present.
If the node is a directory, this will do nothing.
void BlamExplorerBarTreeWidget::Refresh | ( | ) |
Refreshes all data relating to this node.
This will reload the icon and regenerate any child widgets.
void BlamExplorerBarTreeWidget::ShowInformationDialog | ( | ) |
Shows the tag information dialog.
void BlamExplorerBarTreeWidget::UpdateIcon | ( | ) |
Updates the node's icon.
BlamTagTreeNode* BlamExplorerBarTreeWidget::tag_node = nullptr |
The node associated with this widget.