Skip to content
Snippets Groups Projects
Commit a618a391 authored by angela's avatar angela
Browse files
parents dc44d2dc e48f56fe
Branches
No related tags found
No related merge requests found
...@@ -901,6 +901,16 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l ...@@ -901,6 +901,16 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l
|| !existing_inspector->getVisible() || !existing_inspector->getVisible()
|| existing_inspector->getKey()["object_id"].asUUID() != hover_object->getID())) || existing_inspector->getKey()["object_id"].asUUID() != hover_object->getID()))
{ {
// Add price to tooltip for items on sale
bool for_sale = for_sale_selection(nodep);
if(for_sale)
{
LLStringUtil::format_map_t args;
args["[PRICE]"] = llformat ("%d", nodep->mSaleInfo.getSalePrice());
tooltip_msg.append(LLTrans::getString("TooltipPrice", args) );
}
if (nodep->mName.empty()) if (nodep->mName.empty())
{ {
tooltip_msg.append(LLTrans::getString("TooltipNoName")); tooltip_msg.append(LLTrans::getString("TooltipNoName"));
...@@ -931,7 +941,7 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l ...@@ -931,7 +941,7 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l
if (media_impl.notNull() && (media_impl->hasMedia())) if (media_impl.notNull() && (media_impl->hasMedia()))
{ {
is_media_displaying = true; is_media_displaying = true;
LLStringUtil::format_map_t args; //LLStringUtil::format_map_t args;
media_plugin = media_impl->getMediaPlugin(); media_plugin = media_impl->getMediaPlugin();
if(media_plugin) if(media_plugin)
...@@ -955,10 +965,13 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l ...@@ -955,10 +965,13 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l
} }
} }
// Avoid showing tip over media that's displaying
// Avoid showing tip over media that's displaying unless it's for sale
// also check the primary node since sometimes it can have an action even though // also check the primary node since sometimes it can have an action even though
// the root node doesn't // the root node doesn't
bool needs_tip = !is_media_displaying &&
bool needs_tip = (!is_media_displaying ||
for_sale) &&
(has_media || (has_media ||
needs_tooltip(nodep) || needs_tooltip(nodep) ||
needs_tooltip(LLSelectMgr::getInstance()->getPrimaryHoverNode())); needs_tooltip(LLSelectMgr::getInstance()->getPrimaryHoverNode()));
......
...@@ -77,6 +77,8 @@ ...@@ -77,6 +77,8 @@
<string name="TooltipMapUrl">Click to view this location on a map</string> <string name="TooltipMapUrl">Click to view this location on a map</string>
<string name="TooltipSLAPP">Click to run the secondlife:// command</string> <string name="TooltipSLAPP">Click to run the secondlife:// command</string>
<string name="CurrentURL" value=" CurrentURL: [CurrentURL]" /> <string name="CurrentURL" value=" CurrentURL: [CurrentURL]" />
<string name="TooltipPrice" value=" L$[PRICE]-" />
<!-- text for SLURL labels --> <!-- text for SLURL labels -->
<string name="SLurlLabelTeleport">Teleport to</string> <string name="SLurlLabelTeleport">Teleport to</string>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment