From 2d0dfbca99ffa442025358ece6340b894245d3b0 Mon Sep 17 00:00:00 2001
From: Leslie Linden <leslie@lindenlab.com>
Date: Mon, 3 Oct 2011 16:37:07 -0700
Subject: [PATCH] * Added tooltips to the toolbar buttons.

Reviewed by Richard.
---
 indra/llui/lltoolbar.cpp | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/indra/llui/lltoolbar.cpp b/indra/llui/lltoolbar.cpp
index c62bbe4e715..c0058d534df 100644
--- a/indra/llui/lltoolbar.cpp
+++ b/indra/llui/lltoolbar.cpp
@@ -511,10 +511,13 @@ LLToolBarButton* LLToolBar::createButton(const LLCommandId& id)
 	LLCommand* commandp = LLCommandManager::instance().getCommand(id);
 	if (!commandp) return NULL;
 
+	std::string label = LLTrans::getString(commandp->labelRef());
+	std::string tooltip = label + "\n" + LLTrans::getString(commandp->tooltipRef());
+
 	LLToolBarButton::Params button_p;
 	button_p.name = id.name();
-	button_p.label = LLTrans::getString(commandp->labelRef());
-	button_p.tool_tip = button_p.label();
+	button_p.label = label;
+	button_p.tool_tip = tooltip;
 	button_p.image_overlay = LLUI::getUIImage(commandp->icon());
 	button_p.overwriteFrom(mButtonParams[mButtonType]);
 	LLToolBarButton* button = LLUICtrlFactory::create<LLToolBarButton>(button_p);
-- 
GitLab