From bdc2ba527bc02e7cdf977f6040f2ca85aa4f9a94 Mon Sep 17 00:00:00 2001 From: hop311 Date: Wed, 28 Aug 2024 23:16:24 +0100 Subject: Add tooltips for buttons, labels, icons, pie charts, sliders, and progress bars --- extension/src/openvic-extension/classes/GUIProgressBar.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'extension/src/openvic-extension/classes/GUIProgressBar.cpp') diff --git a/extension/src/openvic-extension/classes/GUIProgressBar.cpp b/extension/src/openvic-extension/classes/GUIProgressBar.cpp index 6021746..d13f455 100644 --- a/extension/src/openvic-extension/classes/GUIProgressBar.cpp +++ b/extension/src/openvic-extension/classes/GUIProgressBar.cpp @@ -8,7 +8,17 @@ using namespace godot; using namespace OpenVic; -void GUIProgressBar::_bind_methods() {} +GUI_TOOLTIP_IMPLEMENTATIONS(GUIProgressBar) + +void GUIProgressBar::_bind_methods() { + GUI_TOOLTIP_BIND_METHODS(GUIProgressBar) +} + +void GUIProgressBar::_notification(int what) { + _tooltip_notification(what); +} + +GUIProgressBar::GUIProgressBar() : tooltip_active { false } {} Error GUIProgressBar::set_gfx_progress_bar(GFX::ProgressBar const* progress_bar) { ERR_FAIL_NULL_V(progress_bar, FAILED); -- cgit v1.2.3-56-ga3b1