summaryrefslogtreecommitdiff
path: root/indra/newview/llteleporthistory.cpp
diff options
context:
space:
mode:
authorSteven Bennetts <steve@lindenlab.com>2009-08-26 20:47:27 +0000
committerSteven Bennetts <steve@lindenlab.com>2009-08-26 20:47:27 +0000
commitaf98aad98d43ec8b128ecac3089426d6ae6edc3f (patch)
tree5971f87afc04580df470a003793dcc8c974e29a7 /indra/newview/llteleporthistory.cpp
parent6a364e6f32c12c1ab2c0f33e8ef07d885a8765a2 (diff)
svn merge https://svn.aws.productengine.com/secondlife/export-from-ll/viewer-2-0@1471 https://svn.aws.productengine.com/secondlife/pe/stable-1@1476 -> viewer-2.0.0-3
EXT-65 EXT-270 EXT-359 EXT-361 EXT-367 EXT-367 EXT-368 EXT-455 EXT-468 EXT-530 EXT-539 EXT-540 EXT-542 EXT-545 EXT-555 EXT-557 EXT-558 EXT-559 EXT-559 EXT-560 EXT-561 EXT-562 EXT-563 EXT-564 EXT-566 EXT-568 EXT-569 EXT-570 EXT-571 EXT-581 EXT-590 EXT-594 EXT-596 EXT-597 EXT-601 EXT-602 EXT-603 EXT-613 EXT-620 EXT-624 EXT-628 EXT-630 EXT-631 EXT-632 EXT-639 EXT-640 EXT-641 EXT-642 EXT-662 EXT-671 EXT-672 EXT-676 EXT-682 EXT-692 EXT-703 EXT-717
Diffstat (limited to 'indra/newview/llteleporthistory.cpp')
-rw-r--r--indra/newview/llteleporthistory.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/indra/newview/llteleporthistory.cpp b/indra/newview/llteleporthistory.cpp
index 9754568f56..5235dc9358 100644
--- a/indra/newview/llteleporthistory.cpp
+++ b/indra/newview/llteleporthistory.cpp
@@ -43,6 +43,7 @@
#include "llviewerparcelmgr.h"
#include "llviewerregion.h"
#include "llworldmap.h"
+#include "llagentui.h"
//////////////////////////////////////////////////////////////////////////////
// LLTeleportHistoryItem
@@ -74,7 +75,7 @@ LLTeleportHistory::LLTeleportHistory():
mGotInitialUpdate(false)
{
mTeleportFinishedConn = LLViewerParcelMgr::getInstance()->
- setTeleportFinishedCallback(boost::bind(&LLTeleportHistory::updateCurrentLocation, this));
+ setTeleportFinishedCallback(boost::bind(&LLTeleportHistory::updateCurrentLocation, this, _1));
mTeleportFailedConn = LLViewerParcelMgr::getInstance()->
setTeleportFailedCallback(boost::bind(&LLTeleportHistory::onTeleportFailed, this));
}
@@ -118,7 +119,7 @@ void LLTeleportHistory::onTeleportFailed()
}
}
-void LLTeleportHistory::updateCurrentLocation()
+void LLTeleportHistory::updateCurrentLocation(const LLVector3d& new_pos)
{
if (mRequestedItem != -1) // teleport within the history in progress?
{
@@ -149,7 +150,7 @@ void LLTeleportHistory::updateCurrentLocation()
return;
}
mItems[mCurrentItem].mTitle = getCurrentLocationTitle();
- mItems[mCurrentItem].mGlobalPos = gAgent.getPositionGlobal();
+ mItems[mCurrentItem].mGlobalPos = new_pos;
mItems[mCurrentItem].mRegionID = gAgent.getRegion()->getRegionID();
}
@@ -184,10 +185,7 @@ void LLTeleportHistory::purgeItems()
std::string LLTeleportHistory::getCurrentLocationTitle()
{
std::string location_name;
-
- if (!gAgent.buildLocationString(location_name, LLAgent::LOCATION_FORMAT_NORMAL))
- location_name = "Unknown";
-
+ if (!LLAgentUI::buildLocationString(location_name, LLAgent::LOCATION_FORMAT_NORMAL)) location_name = "Unknown";
return location_name;
}
@@ -201,6 +199,7 @@ void LLTeleportHistory::dump() const
line << ((i == mCurrentItem) ? " * " : " ");
line << i << ": " << mItems[i].mTitle;
line << " REGION_ID: " << mItems[i].mRegionID;
+ line << ", pos: " << mItems[i].mGlobalPos;
llinfos << line.str() << llendl;
}
}