![]() |
Blamite Game Engine - Keystone
00390.07.02.23.1947.blamite
A library that enables the use of Qt in Blamite's editing tools.
|
Class representing a draggable widget container. More...
#include <drag_container.h>
Public Member Functions | |
drag_container (drag_list *_parent_list, tag_designer *_designer) | |
Creates a new drag_container instance. More... | |
~drag_container () | |
void | mousePressEvent (QMouseEvent *mouse_event) override |
void | mouseMoveEvent (QMouseEvent *event) override |
void | mouseReleaseEvent (QMouseEvent *mouse_event) override |
void | OnEditorThemeChangeEvent (EditorThemeChangeEvent *event) override |
void | AddContentWidget (QWidget *widget) |
Adds a widget to this drag container. More... | |
void | SetIconVisiblity (bool icon_visible_state) |
Sets whether or not the drag container's sidebar icon should be visible. More... | |
void | SetIcon (std::string group_id, std::string resource_id) |
Sets the drag container's sidebar icon. More... | |
void | SetFocusState (bool focus_state, bool force_update=false) |
Sets the drag container's focus state. More... | |
void | RebuildFieldTypeOptions () |
Public Attributes | |
BlamPluginField * | field_data = nullptr |
The plugin field that belongs to this container. More... | |
BlamEditorTagFieldControl * | tag_field_control = nullptr |
The tag field widget that belongs to this container. More... | |
tag_designer * | designer = nullptr |
The Tag Designer that this container exists within. More... | |
Class representing a draggable widget container.
Currently, this is only used for the Tag Designer - however in the future, it could be adapted to be used as a general purpose drag-and-drop widget.
drag_container::drag_container | ( | drag_list * | _parent_list, |
tag_designer * | _designer | ||
) |
Creates a new drag_container instance.
_parent_list | - The drag list that this container belongs to. |
drag_container::~drag_container | ( | ) |
void drag_container::AddContentWidget | ( | QWidget * | widget | ) |
Adds a widget to this drag container.
widget | - Pointer to the widget to add to the container. |
|
override |
|
override |
|
override |
|
override |
void drag_container::RebuildFieldTypeOptions | ( | ) |
void drag_container::SetFocusState | ( | bool | focus_state, |
bool | force_update = false |
||
) |
Sets the drag container's focus state.
When focused, the drag container will display slightly differently - exposing certain editing controls to the user.
focus_state | - Whether or not the container should be focused. |
force_update | - Whether or not to force a UI update. Note that this is only required if the container already has the specified focus state - if the focus state is actually being changed from this method, the UI will update regardless. Defaults to false . |
void drag_container::SetIcon | ( | std::string | group_id, |
std::string | resource_id | ||
) |
Sets the drag container's sidebar icon.
group_id | - The ID of the resource group to pull the icon from. |
resource_id | - The ID of the resource to use for the icon. |
void drag_container::SetIconVisiblity | ( | bool | icon_visible_state | ) |
Sets whether or not the drag container's sidebar icon should be visible.
icon_visible_state | - Whether or not the icon should be visible. |
tag_designer* drag_container::designer = nullptr |
The Tag Designer that this container exists within.
BlamPluginField* drag_container::field_data = nullptr |
The plugin field that belongs to this container.
BlamEditorTagFieldControl* drag_container::tag_field_control = nullptr |
The tag field widget that belongs to this container.