diff options
| author | Merov Linden <merov@lindenlab.com> | 2013-10-14 17:25:24 -0700 |
|---|---|---|
| committer | Merov Linden <merov@lindenlab.com> | 2013-10-14 17:25:24 -0700 |
| commit | f6c7b906e1f1d1bcc56a1e71b1867a58c5b2381a (patch) | |
| tree | ec9226508d7a3e1555b774fde915a8b299b35cd7 /indra/newview/llworldmap.cpp | |
| parent | c2f5365f986aab49d5c7cfa2834a68f5b35c09c2 (diff) | |
| parent | 04b84ce07dd5bc8364f948ef0004e3dc5328f1b4 (diff) | |
Pull merge with lindenlab/viewer-bear
Diffstat (limited to 'indra/newview/llworldmap.cpp')
| -rwxr-xr-x | indra/newview/llworldmap.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/indra/newview/llworldmap.cpp b/indra/newview/llworldmap.cpp index 5fa380e0e3..fd9cdd95a3 100755 --- a/indra/newview/llworldmap.cpp +++ b/indra/newview/llworldmap.cpp @@ -518,10 +518,17 @@ bool LLWorldMap::insertItem(U32 x_world, U32 y_world, std::string& name, LLUUID& case MAP_ITEM_LAND_FOR_SALE: // land for sale case MAP_ITEM_LAND_FOR_SALE_ADULT: // adult land for sale { + F32 cost_per_sqm = 0.0f; + if ((F32)extra > 0) + { + cost_per_sqm = (F32)extra2 / (F32)extra; + } + static LLUIString tooltip_fmt = LLTrans::getString("worldmap_item_tooltip_format"); tooltip_fmt.setArg("[AREA]", llformat("%d", extra)); tooltip_fmt.setArg("[PRICE]", llformat("%d", extra2)); + tooltip_fmt.setArg("[PRICE_PER_SQM]", llformat("%.1f", cost_per_sqm)); new_item.setTooltip(tooltip_fmt.getString()); if (type == MAP_ITEM_LAND_FOR_SALE) |
