summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llfloaterworldmap.cpp68
-rw-r--r--indra/newview/llfloaterworldmap.h7
-rw-r--r--indra/newview/llinventoryicon.cpp1
-rw-r--r--indra/newview/llpaneloutfitedit.cpp29
-rw-r--r--indra/newview/skins/default/xui/en/floater_buy_land.xml24
-rw-r--r--indra/newview/skins/default/xui/en/floater_world_map.xml123
6 files changed, 175 insertions, 77 deletions
diff --git a/indra/newview/llfloaterworldmap.cpp b/indra/newview/llfloaterworldmap.cpp
index 983fd97b0b..031294ad56 100644
--- a/indra/newview/llfloaterworldmap.cpp
+++ b/indra/newview/llfloaterworldmap.cpp
@@ -206,6 +206,7 @@ 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));
@@ -336,8 +337,6 @@ void LLFloaterWorldMap::onOpen(const LLSD& key)
}
}
-
-
// static
void LLFloaterWorldMap::reloadIcons(void*)
{
@@ -582,6 +581,10 @@ 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())
@@ -592,6 +595,10 @@ 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;
}
@@ -609,9 +616,40 @@ 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;
@@ -638,6 +676,9 @@ 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());
@@ -668,6 +709,10 @@ 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 )
{
@@ -1139,6 +1184,22 @@ void LLFloaterWorldMap::onLocationCommit()
}
}
+void LLFloaterWorldMap::onCoordinatesCommit()
+{
+ if( mIsClosing )
+ {
+ return;
+ }
+
+ F32 x_coord = (F32)childGetValue("teleport_coordinate_x").asReal();
+ F32 y_coord = (F32)childGetValue("teleport_coordinate_y").asReal();
+ F32 z_coord = (F32)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;
@@ -1199,6 +1260,9 @@ void LLFloaterWorldMap::centerOnTarget(BOOL animate)
else if(LLWorldMap::getInstance()->isTracking())
{
pos_global = LLWorldMap::getInstance()->getTrackedPositionGlobal() - gAgentCamera.getCameraPositionGlobal();;
+
+
+
}
else
{
diff --git a/indra/newview/llfloaterworldmap.h b/indra/newview/llfloaterworldmap.h
index 550b4ef689..e31bafaf9b 100644
--- a/indra/newview/llfloaterworldmap.h
+++ b/indra/newview/llfloaterworldmap.h
@@ -149,6 +149,7 @@ protected:
void updateSearchEnabled();
void onLocationFocusChanged( LLFocusableElement* ctrl );
void onLocationCommit();
+ void onCoordinatesCommit();
void onCommitSearchResult();
void cacheLandmarkPosition();
@@ -160,6 +161,12 @@ private:
F32 mCurZoomVal;
LLFrameTimer mZoomTimer;
+ // update display of teleport destination coordinates - pos is in global coordinates
+ void updateTeleportCoordsDisplay( const LLVector3d& pos );
+
+ // enable/disable teleport destination coordinates
+ void enableTeleportCoordsDisplay( bool enabled );
+
LLDynamicArray<LLUUID> mLandmarkAssetIDList;
LLDynamicArray<LLUUID> mLandmarkItemIDList;
diff --git a/indra/newview/llinventoryicon.cpp b/indra/newview/llinventoryicon.cpp
index 3090371a73..2201481df3 100644
--- a/indra/newview/llinventoryicon.cpp
+++ b/indra/newview/llinventoryicon.cpp
@@ -117,6 +117,7 @@ const std::string& LLInventoryIcon::getIconName(LLAssetType::EType asset_type,
if (item_is_multi)
{
idx = ICONNAME_OBJECT_MULTI;
+ return getIconName(idx);
}
switch(asset_type)
diff --git a/indra/newview/llpaneloutfitedit.cpp b/indra/newview/llpaneloutfitedit.cpp
index 38f637cabf..58a5529505 100644
--- a/indra/newview/llpaneloutfitedit.cpp
+++ b/indra/newview/llpaneloutfitedit.cpp
@@ -841,15 +841,38 @@ void LLPanelOutfitEdit::filterWearablesBySelectedItem(void)
bool more_than_one_selected = ids.size() > 1;
bool is_dummy_item = (ids.size() && dynamic_cast<LLPanelDummyClothingListItem*>(mCOFWearables->getSelectedItem()));
- //selected and expanded accordion tabs determine filtering when no item is selected
+ // selected, expanded accordion tabs and selection in flat list view determine filtering when no item is selected in COF
+ // selection in flat list view participates in determining filtering because of EXT-7963
+ // So the priority of criterions in is:
+ // 1. Selected accordion tab | IF (any accordion selected)
+ // | filter_type = selected_accordion_type
+ // 2. Selected item in flat list view | ELSEIF (any item in flat list view selected)
+ // | filter_type = selected_item_type
+ // 3. Expanded accordion tab | ELSEIF (any accordion expanded)
+ // | filter_type = expanded accordion_type
if (nothing_selected)
{
showWearablesListView();
- //selected accordion tab is more priority than expanded tab when determining filtering
+ //selected accordion tab is more priority than expanded tab
+ //and selected item in flat list view of 'Add more' panel when
+ //determining filtering
LLAssetType::EType type = mCOFWearables->getSelectedAccordionAssetType();
if (type == LLAssetType::AT_NONE)
- {
+ { //no accordion selected
+
+ // when no accordion selected then selected item from flat list view
+ // has more priority than expanded when determining filtering
+ LLUUID selected_item_id = mWearableItemsList->getSelectedUUID();
+ LLViewerInventoryItem* item = gInventory.getLinkedItem(selected_item_id);
+ if(item)
+ {
+ showFilteredWearablesListView(item->getWearableType());
+ return;
+ }
+
+ // when no accordion selected and no selected items in flat list view
+ // determine filtering according to expanded accordion
type = mCOFWearables->getExpandedAccordionAssetType();
}
diff --git a/indra/newview/skins/default/xui/en/floater_buy_land.xml b/indra/newview/skins/default/xui/en/floater_buy_land.xml
index 0ad4fbc967..c88de878f4 100644
--- a/indra/newview/skins/default/xui/en/floater_buy_land.xml
+++ b/indra/newview/skins/default/xui/en/floater_buy_land.xml
@@ -529,13 +529,14 @@ sold with objects
length="1"
follows="top|left"
font="SansSerifBig"
- height="16"
+ height="32"
layout="topleft"
left="72"
name="account_action"
right="438"
top="200"
- width="218">
+ width="218"
+ wrap="true">
Upgrade you to premium membership.
</text>
<text
@@ -577,19 +578,21 @@ sold with objects
layout="topleft"
left="0"
name="step_2"
+ top_pad="-10"
width="64" />
<text
type="string"
length="1"
follows="top|left"
font="SansSerifBig"
- height="16"
+ height="32"
layout="topleft"
left="72"
name="land_use_action"
right="438"
top="284"
- width="218">
+ width="218"
+ wrap="true">
Increase your monthly land use fees to US$ 40/month.
</text>
<text
@@ -620,14 +623,15 @@ This parcel is 512 m² of land.
<text
type="string"
length="1"
- bottom_delta="-38"
+ bottom_delta="-22"
follows="top|left"
font="SansSerifBig"
- height="16"
+ height="32"
layout="topleft"
left="72"
name="purchase_action"
- right="438">
+ right="438"
+ wrap="true">
Pay Joe Resident L$ 4000 for the land
</text>
<text
@@ -665,7 +669,7 @@ This parcel is 512 m² of land.
layout="topleft"
left="170"
name="currency_amt"
- top="408"
+ top="424"
width="80">
1000
</line_editor>
@@ -681,7 +685,7 @@ This parcel is 512 m² of land.
layout="topleft"
left="260"
name="currency_est"
- top="409"
+ top="425"
width="178">
for approx. [LOCAL_AMOUNT]
</text>
@@ -713,7 +717,7 @@ This parcel is 512 m² of land.
layout="topleft"
left="70"
name="buy_btn"
- top="448"
+ top="460"
width="100" />
<button
follows="bottom|right"
diff --git a/indra/newview/skins/default/xui/en/floater_world_map.xml b/indra/newview/skins/default/xui/en/floater_world_map.xml
index a59db1420f..20629018e2 100644
--- a/indra/newview/skins/default/xui/en/floater_world_map.xml
+++ b/indra/newview/skins/default/xui/en/floater_world_map.xml
@@ -395,7 +395,7 @@
<panel
follows="right|top|bottom"
- height="310"
+ height="330"
top_pad="0"
width="238"
name="layout_panel_4">
@@ -534,7 +534,66 @@
<scroll_list.commit_callback
function="WMap.SearchResult" />
</scroll_list>
- <button
+ <text
+ type="string"
+ length="1"
+ follows="right|bottom"
+ halign="right"
+ height="16"
+ layout="topleft"
+ left="25"
+ name="events_label"
+ top_pad="16"
+ width="70">
+ Location:
+ </text>
+ <spinner
+ control_name="Teleport_Coordinate_X"
+ decimal_digits="0"
+ follows="right|bottom"
+ height="23"
+ increment="1"
+ initial_value="128"
+ layout="topleft"
+ left_delta="74"
+ max_val="255"
+ min_val="0"
+ name="teleport_coordinate_x"
+ width="44" >
+ <spinner.commit_callback
+ function="WMap.Coordinates" />
+ </spinner>
+ <spinner
+ control_name="Teleport_Coordinate_Y"
+ decimal_digits="0"
+ follows="right|bottom"
+ height="23"
+ increment="1"
+ initial_value="128"
+ layout="topleft"
+ left_delta="47"
+ max_val="255"
+ min_val="0"
+ name="teleport_coordinate_y" >
+ <spinner.commit_callback
+ function="WMap.Coordinates" />
+ </spinner>
+ <spinner
+ control_name="Teleport_Coordinate_Z"
+ decimal_digits="0"
+ follows="right|bottom"
+ height="23"
+ increment="1"
+ initial_value="128"
+ layout="topleft"
+ left_delta="47"
+ max_val="255"
+ min_val="0"
+ name="teleport_coordinate_z">
+ <spinner.commit_callback
+ function="WMap.Coordinates" />
+ </spinner>
+ <button
follows="right|bottom"
height="23"
image_unselected="PushButton_On"
@@ -574,66 +633,6 @@
<button.commit_callback
function="WMap.ShowTarget" />
</button>
-
-<!-- <text
- type="string"
- length="1"
- follows="bottom|right"
- halign="left"
- height="16"
- top_pad="4"
- left="25"
- layout="topleft"
- name="land_sale_label"
- width="250">
- Location:
- </text>
- <spinner
- decimal_digits="0"
- follows="bottom|right"
- increment="1"
- initial_value="128"
- layout="topleft"
- top_pad="0"
- left="25"
- max_val="255"
- name="spin x"
- tool_tip="X coordinate of location to show on map"
- width="48">
- <spinner.commit_callback
- function="WMap.CommitLocation" />
- </spinner>
- <spinner
- decimal_digits="0"
- follows="bottom|right"
- height="16"
- increment="1"
- initial_value="128"
- layout="topleft"
- left_pad="2"
- max_val="255"
- name="spin y"
- tool_tip="Y coordinate of location to show on map"
- top_delta="0"
- width="48" >
- <spinner.commit_callback
- function="WMap.CommitLocation" />
- </spinner>
- <spinner
- decimal_digits="0"
- follows="bottom|right"
- increment="1"
- initial_value="0"
- layout="topleft"
- left_pad="2"
- max_val="4096"
- name="spin z"
- tool_tip="Z coordinate of location to show on map"
- top_delta="0"
- width="48">
- <spinner.commit_callback
- function="WMap.CommitLocation" />
- </spinner>-->
</panel>
<panel
follows="right|bottom"