From 37fcb81c4ab8806a52ef747e6a3047fff2d6eccf Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Mon, 24 Jun 2013 13:32:13 -0700 Subject: ACME-497 : Clean up the xml code for checkin to use a proper icon widget and add a decent default image for it --- indra/newview/llfloatersocial.cpp | 7 +- .../default/textures/icons/map_placeholder.jpg | Bin 0 -> 15526 bytes indra/newview/skins/default/textures/textures.xml | 2 + .../skins/default/xui/en/floater_social.xml | 103 +++++++++------------ 4 files changed, 53 insertions(+), 59 deletions(-) create mode 100644 indra/newview/skins/default/textures/icons/map_placeholder.jpg diff --git a/indra/newview/llfloatersocial.cpp b/indra/newview/llfloatersocial.cpp index cca966bb9a..361d54f696 100644 --- a/indra/newview/llfloatersocial.cpp +++ b/indra/newview/llfloatersocial.cpp @@ -42,7 +42,11 @@ static LLRegisterPanelClassWrapper t_panel_checkin("llsoci std::string get_map_url() { - LLVector3d center_agent = gAgent.getRegion()->getCenterGlobal(); + LLVector3d center_agent; + if (gAgent.getRegion()) + { + center_agent = gAgent.getRegion()->getCenterGlobal(); + } int x_pos = center_agent[0] / 256.0; int y_pos = center_agent[1] / 256.0; std::string map_url = gSavedSettings.getString("CurrentMapServerURL") + llformat("map-1-%d-%d-objects.jpg", x_pos, y_pos); @@ -104,7 +108,6 @@ void LLSocialCheckinPanel::onSend() std::string description; LLAgentUI::buildLocationString(description, LLAgentUI::LOCATION_FORMAT_NORMAL_COORDS, gAgent.getPositionAgent()); - // Optionally add the region map view bool add_map_view = getChild("add_place_view_cb")->getValue().asBoolean(); std::string map_url = (add_map_view ? mMapUrl : ""); diff --git a/indra/newview/skins/default/textures/icons/map_placeholder.jpg b/indra/newview/skins/default/textures/icons/map_placeholder.jpg new file mode 100644 index 0000000000..89f4eb88df Binary files /dev/null and b/indra/newview/skins/default/textures/icons/map_placeholder.jpg differ diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml index 64f7103ccc..731bbe8994 100755 --- a/indra/newview/skins/default/textures/textures.xml +++ b/indra/newview/skins/default/textures/textures.xml @@ -325,6 +325,8 @@ with the same filename but different name + + diff --git a/indra/newview/skins/default/xui/en/floater_social.xml b/indra/newview/skins/default/xui/en/floater_social.xml index f99044b233..fc26ba5842 100644 --- a/indra/newview/skins/default/xui/en/floater_social.xml +++ b/indra/newview/skins/default/xui/en/floater_social.xml @@ -379,36 +379,25 @@ - - - - - + + + Include overhead view of location - - - - - - - + + + -- cgit v1.2.3