summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterworldmap.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloaterworldmap.cpp')
-rw-r--r--indra/newview/llfloaterworldmap.cpp68
1 files changed, 2 insertions, 66 deletions
diff --git a/indra/newview/llfloaterworldmap.cpp b/indra/newview/llfloaterworldmap.cpp
index 88f8545877..983fd97b0b 100644
--- a/indra/newview/llfloaterworldmap.cpp
+++ b/indra/newview/llfloaterworldmap.cpp
@@ -206,7 +206,6 @@ LLFloaterWorldMap::LLFloaterWorldMap(const LLSD& key)
mFactoryMap["objects_mapview"] = LLCallbackMap(createWorldMapView, NULL);
//Called from floater reg: LLUICtrlFactory::getInstance()->buildFloater(this, "floater_world_map.xml", FALSE);
- mCommitCallbackRegistrar.add("WMap.Coordinates", boost::bind(&LLFloaterWorldMap::onCoordinatesCommit, this));
mCommitCallbackRegistrar.add("WMap.Location", boost::bind(&LLFloaterWorldMap::onLocationCommit, this));
mCommitCallbackRegistrar.add("WMap.AvatarCombo", boost::bind(&LLFloaterWorldMap::onAvatarComboCommit, this));
mCommitCallbackRegistrar.add("WMap.Landmark", boost::bind(&LLFloaterWorldMap::onLandmarkComboCommit, this));
@@ -337,6 +336,8 @@ void LLFloaterWorldMap::onOpen(const LLSD& key)
}
}
+
+
// static
void LLFloaterWorldMap::reloadIcons(void*)
{
@@ -581,10 +582,6 @@ void LLFloaterWorldMap::trackLocation(const LLVector3d& pos_global)
S32 world_y = S32(pos_global.mdV[1] / 256);
LLWorldMapMessage::getInstance()->sendMapBlockRequest(world_x, world_y, world_x, world_y, true);
setDefaultBtn("");
-
- // clicked on a non-region - turn off coord display
- enableTeleportCoordsDisplay( false );
-
return;
}
if (sim_info->isDown())
@@ -595,10 +592,6 @@ void LLFloaterWorldMap::trackLocation(const LLVector3d& pos_global)
LLWorldMap::getInstance()->setTrackingInvalid();
LLTracker::stopTracking(NULL);
setDefaultBtn("");
-
- // clicked on a down region - turn off coord display
- enableTeleportCoordsDisplay( false );
-
return;
}
@@ -616,40 +609,9 @@ void LLFloaterWorldMap::trackLocation(const LLVector3d& pos_global)
LLTracker::trackLocation(pos_global, full_name, tooltip);
LLWorldMap::getInstance()->cancelTracking(); // The floater is taking over the tracking
- LLVector3d coord_pos = LLTracker::getTrackedPositionGlobal();
- updateTeleportCoordsDisplay( coord_pos );
-
- // we have a valid region - turn on coord display
- enableTeleportCoordsDisplay( true );
-
setDefaultBtn("Teleport");
}
-// enable/disable teleport destination coordinates
-void LLFloaterWorldMap::enableTeleportCoordsDisplay( bool enabled )
-{
- childSetEnabled("teleport_coordinate_x", enabled );
- childSetEnabled("teleport_coordinate_y", enabled );
- childSetEnabled("teleport_coordinate_z", enabled );
-}
-
-// update display of teleport destination coordinates - pos is in global coordinates
-void LLFloaterWorldMap::updateTeleportCoordsDisplay( const LLVector3d& pos )
-{
- // if we're going to update their value, we should also enable them
- enableTeleportCoordsDisplay( true );
-
- // convert global specified position to a local one
- F32 region_local_x = (F32)fmod( pos.mdV[VX], (F64)REGION_WIDTH_METERS );
- F32 region_local_y = (F32)fmod( pos.mdV[VY], (F64)REGION_WIDTH_METERS );
- F32 region_local_z = (F32)fmod( pos.mdV[VZ], (F64)REGION_WIDTH_METERS );
-
- // write in the values
- childSetValue("teleport_coordinate_x", region_local_x );
- childSetValue("teleport_coordinate_y", region_local_y );
- childSetValue("teleport_coordinate_z", region_local_z );
-}
-
void LLFloaterWorldMap::updateLocation()
{
bool gotSimName;
@@ -676,9 +638,6 @@ void LLFloaterWorldMap::updateLocation()
// Fill out the location field
childSetValue("location", agent_sim_name);
- // update the coordinate display with location of avatar in region
- updateTeleportCoordsDisplay( agentPos );
-
// Figure out where user is
// Set the current SLURL
mSLURL = LLSLURL(agent_sim_name, gAgent.getPositionGlobal());
@@ -709,10 +668,6 @@ void LLFloaterWorldMap::updateLocation()
childSetValue("location", sim_name);
- // refresh coordinate display to reflect where user clicked.
- LLVector3d coord_pos = LLTracker::getTrackedPositionGlobal();
- updateTeleportCoordsDisplay( coord_pos );
-
// simNameFromPosGlobal can fail, so don't give the user an invalid SLURL
if ( gotSimName )
{
@@ -1184,22 +1139,6 @@ void LLFloaterWorldMap::onLocationCommit()
}
}
-void LLFloaterWorldMap::onCoordinatesCommit()
-{
- if( mIsClosing )
- {
- return;
- }
-
- S32 x_coord = (S32)childGetValue("teleport_coordinate_x").asReal();
- S32 y_coord = (S32)childGetValue("teleport_coordinate_y").asReal();
- S32 z_coord = (S32)childGetValue("teleport_coordinate_z").asReal();
-
- const std::string region_name = childGetValue("location").asString();
-
- trackURL( region_name, x_coord, y_coord, z_coord );
-}
-
void LLFloaterWorldMap::onClearBtn()
{
mTrackedStatus = LLTracker::TRACKING_NOTHING;
@@ -1260,9 +1199,6 @@ void LLFloaterWorldMap::centerOnTarget(BOOL animate)
else if(LLWorldMap::getInstance()->isTracking())
{
pos_global = LLWorldMap::getInstance()->getTrackedPositionGlobal() - gAgentCamera.getCameraPositionGlobal();;
-
-
-
}
else
{