aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview
diff options
context:
space:
mode:
authorPatrick Sapinski2010-08-23 04:11:27 -0400
committerMcCabe Maxsted2010-08-28 05:01:11 -0700
commit9debdb2927979b1fb57e20acf93077cd49e6319f (patch)
tree91bc5475494389d73cba0b50fc72670a85287ec1 /linden/indra/newview
parentChanged 'main console' to 'main chat' for showing IMs (diff)
downloadmeta-impy-9debdb2927979b1fb57e20acf93077cd49e6319f.zip
meta-impy-9debdb2927979b1fb57e20acf93077cd49e6319f.tar.gz
meta-impy-9debdb2927979b1fb57e20acf93077cd49e6319f.tar.bz2
meta-impy-9debdb2927979b1fb57e20acf93077cd49e6319f.tar.xz
extra tooltip info ported from Emerald
Diffstat (limited to 'linden/indra/newview')
-rw-r--r--linden/indra/newview/llhoverview.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/linden/indra/newview/llhoverview.cpp b/linden/indra/newview/llhoverview.cpp
index 8c367ab..6367380 100644
--- a/linden/indra/newview/llhoverview.cpp
+++ b/linden/indra/newview/llhoverview.cpp
@@ -480,6 +480,27 @@ void LLHoverView::updateText()
480 } 480 }
481 mText.push_back(line); 481 mText.push_back(line);
482 } 482 }
483 line.clear();
484 S32 prim_count = LLSelectMgr::getInstance()->getHoverObjects()->getObjectCount();
485 line.append(llformat("Prims: %d", prim_count));
486 mText.push_back(line);
487
488 line.clear();
489 line.append("Position: ");
490
491 LLViewerRegion *region = gAgent.getRegion();
492 LLVector3 position = region->getPosRegionFromGlobal(hit_object->getPositionGlobal());//regionp->getOriginAgent();
493 LLVector3 mypos = region->getPosRegionFromGlobal(gAgent.getPositionGlobal());
494
495
496 LLVector3 delta = position - mypos;
497 F32 distance = (F32)delta.magVec();
498
499 line.append(llformat("<%.02f,%.02f,%.02f>",position.mV[0],position.mV[1],position.mV[2]));
500 mText.push_back(line);
501 line.clear();
502 line.append(llformat("Distance: %.02fm",distance));
503 mText.push_back(line);
483 504
484 // If the hover tip shouldn't be shown, delete all the object text 505 // If the hover tip shouldn't be shown, delete all the object text
485 if (suppressObjectHoverDisplay) 506 if (suppressObjectHoverDisplay)