mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-08 04:21:50 +00:00
added tooltips
This commit is contained in:
parent
1c45236693
commit
eb10904069
10 changed files with 146 additions and 11 deletions
|
|
@ -109,6 +109,8 @@ namespace gui {
|
|||
ActionsSet actions;
|
||||
/// @brief 'ondoubleclick' callbacks
|
||||
ActionsSet doubleClickCallbacks;
|
||||
/// @brief element tooltip text
|
||||
std::wstring tooltip;
|
||||
|
||||
UINode(glm::vec2 size);
|
||||
public:
|
||||
|
|
@ -197,6 +199,9 @@ namespace gui {
|
|||
virtual void setResizing(bool flag);
|
||||
virtual bool isResizing() const;
|
||||
|
||||
virtual void setTooltip(const std::wstring& text);
|
||||
virtual const std::wstring getTooltip() const;
|
||||
|
||||
virtual glm::vec4 calcColor() const;
|
||||
|
||||
/// @brief Get inner content offset. Used for scroll
|
||||
|
|
@ -237,9 +242,14 @@ namespace gui {
|
|||
|
||||
/// @brief collect all nodes having id
|
||||
static void getIndices(
|
||||
std::shared_ptr<UINode> node,
|
||||
const std::shared_ptr<UINode> node,
|
||||
std::unordered_map<std::string, std::shared_ptr<UINode>>& map
|
||||
);
|
||||
|
||||
static std::shared_ptr<UINode> find(
|
||||
const std::shared_ptr<UINode> node,
|
||||
const std::string& id
|
||||
);
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue