summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/llui/lltextbase.cpp28
-rw-r--r--indra/llui/lltextbase.h6
-rw-r--r--indra/llui/lltexteditor.cpp69
-rw-r--r--indra/llui/lltexteditor.h1
-rw-r--r--indra/llui/llurlentry.cpp20
-rw-r--r--indra/llui/llurlentry.h13
-rw-r--r--indra/llui/llurlregistry.cpp3
-rw-r--r--indra/llui/tests/llurlentry_test.cpp305
-rw-r--r--indra/newview/installers/darwin/firstlook-dmg/_DS_Storebin12292 -> 12292 bytes
-rw-r--r--indra/newview/installers/darwin/fix_application_icon_position.sh17
-rw-r--r--indra/newview/installers/darwin/publicnightly-dmg/_DS_Storebin12292 -> 12292 bytes
-rw-r--r--indra/newview/installers/darwin/release-dmg/_DS_Storebin12292 -> 12292 bytes
-rw-r--r--indra/newview/installers/darwin/releasecandidate-dmg/_DS_Storebin12292 -> 12292 bytes
-rw-r--r--indra/newview/llchathistory.cpp19
-rw-r--r--indra/newview/lldrawable.h1
-rw-r--r--indra/newview/llfloateranimpreview.cpp64
-rw-r--r--indra/newview/llfloaterland.cpp22
-rw-r--r--indra/newview/llfloaterscriptlimits.cpp987
-rw-r--r--indra/newview/llfloaterscriptlimits.h76
-rw-r--r--indra/newview/llfolderviewitem.cpp4
-rw-r--r--indra/newview/llinspectremoteobject.cpp5
-rw-r--r--indra/newview/llinventorymodel.cpp6
-rw-r--r--indra/newview/llpreviewscript.cpp2
-rw-r--r--indra/newview/llsidepanelinventory.cpp2
-rw-r--r--indra/newview/llstartup.cpp2
-rw-r--r--indra/newview/lltoolplacer.h1
-rw-r--r--indra/newview/llviewermessage.cpp5
-rw-r--r--indra/newview/llvoiceclient.cpp8
-rw-r--r--indra/newview/skins/default/textures/build/Object_Cone_Selected.pngbin0 -> 576 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Cube_Selected.pngbin0 -> 477 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Cylinder_Selected.pngbin0 -> 443 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Grass_Selected.pngbin0 -> 757 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Hemi_Cone_Selected.pngbin0 -> 531 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Hemi_Cylinder_Selected.pngbin0 -> 463 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Hemi_Sphere_Selected.pngbin0 -> 696 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Prism_Selected.pngbin0 -> 485 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Pyramid_Selected.pngbin0 -> 594 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Ring_Selected.pngbin0 -> 738 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Sphere_Selected.pngbin0 -> 1003 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Tetrahedron_Selected.pngbin0 -> 558 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Torus_Selected.pngbin0 -> 825 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Tree_Selected.pngbin0 -> 839 bytes
-rw-r--r--indra/newview/skins/default/textures/build/Object_Tube_Selected.pngbin0 -> 552 bytes
-rw-r--r--indra/newview/skins/default/textures/textures.xml20
-rw-r--r--indra/newview/skins/default/xui/en/floater_aaa.xml2
-rw-r--r--indra/newview/skins/default/xui/en/floater_animation_preview.xml6
-rw-r--r--indra/newview/skins/default/xui/en/floater_script_limits.xml1
-rw-r--r--indra/newview/skins/default/xui/en/floater_tools.xml41
-rw-r--r--indra/newview/skins/default/xui/en/panel_im_control_panel.xml1
-rw-r--r--indra/newview/skins/default/xui/en/panel_places.xml5
-rw-r--r--indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml45
-rw-r--r--indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml38
-rw-r--r--indra/newview/skins/default/xui/en/strings.xml1
-rw-r--r--indra/newview/skins/default/xui/en/widgets/location_input.xml4
54 files changed, 1017 insertions, 813 deletions
diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp
index b977e50bc1..75ca6d8895 100644
--- a/indra/llui/lltextbase.cpp
+++ b/indra/llui/lltextbase.cpp
@@ -185,7 +185,7 @@ LLTextBase::LLTextBase(const LLTextBase::Params &p)
mWriteableBgColor(p.bg_writeable_color),
mReadOnlyBgColor(p.bg_readonly_color),
mFocusBgColor(p.bg_focus_color),
- mReflowNeeded(FALSE),
+ mReflowIndex(S32_MAX),
mCursorPos( 0 ),
mScrollNeeded(FALSE),
mDesiredXPixel(-1),
@@ -660,7 +660,7 @@ S32 LLTextBase::insertStringNoUndo(S32 pos, const LLWString &wstr, LLTextBase::s
}
onValueChange(pos, pos + insert_len);
- needsReflow();
+ needsReflow(pos);
return insert_len;
}
@@ -720,7 +720,7 @@ S32 LLTextBase::removeStringNoUndo(S32 pos, S32 length)
createDefaultSegment();
onValueChange(pos, pos);
- needsReflow();
+ needsReflow(pos);
return -length; // This will be wrong if someone calls removeStringNoUndo with an excessive length
}
@@ -736,7 +736,7 @@ S32 LLTextBase::overwriteCharNoUndo(S32 pos, llwchar wc)
getViewModel()->setDisplay(text);
onValueChange(pos, pos + 1);
- needsReflow();
+ needsReflow(pos);
return 1;
}
@@ -762,15 +762,18 @@ void LLTextBase::insertSegment(LLTextSegmentPtr segment_to_insert)
}
segment_set_t::iterator cur_seg_iter = getSegIterContaining(segment_to_insert->getStart());
+ S32 reflow_start_index = 0;
if (cur_seg_iter == mSegments.end())
{
mSegments.insert(segment_to_insert);
segment_to_insert->linkToDocument(this);
+ reflow_start_index = segment_to_insert->getStart();
}
else
{
LLTextSegmentPtr cur_segmentp = *cur_seg_iter;
+ reflow_start_index = cur_segmentp->getStart();
if (cur_segmentp->getStart() < segment_to_insert->getStart())
{
S32 old_segment_end = cur_segmentp->getEnd();
@@ -829,7 +832,7 @@ void LLTextBase::insertSegment(LLTextSegmentPtr segment_to_insert)
}
// layout potentially changed
- needsReflow();
+ needsReflow(reflow_start_index);
}
BOOL LLTextBase::handleMouseDown(S32 x, S32 y, MASK mask)
@@ -1084,15 +1087,16 @@ S32 LLTextBase::getLeftOffset(S32 width)
static LLFastTimer::DeclareTimer FTM_TEXT_REFLOW ("Text Reflow");
-void LLTextBase::reflow(S32 start_index)
+void LLTextBase::reflow()
{
LLFastTimer ft(FTM_TEXT_REFLOW);
updateSegments();
- while(mReflowNeeded)
+ while(mReflowIndex < S32_MAX)
{
- mReflowNeeded = false;
+ S32 start_index = mReflowIndex;
+ mReflowIndex = S32_MAX;
// shrink document to minimum size (visible portion of text widget)
// to force inlined widgets with follows set to shrink
@@ -1619,6 +1623,12 @@ void LLTextBase::appendText(const std::string &new_text, bool prepend_newline, c
}
}
+void LLTextBase::needsReflow(S32 index)
+{
+ lldebugs << "reflow on object " << (void*)this << " index = " << mReflowIndex << ", new index = " << index << llendl;
+ mReflowIndex = llmin(mReflowIndex, index);
+}
+
void LLTextBase::appendAndHighlightText(const std::string &new_text, bool prepend_newline, S32 highlight_part, const LLStyle::Params& style_params)
{
if (new_text.empty()) return;
@@ -2260,7 +2270,7 @@ LLNormalTextSegment::LLNormalTextSegment( LLStyleConstSP style, S32 start, S32 e
LLUIImagePtr image = mStyle->getImage();
if (image.notNull())
{
- mImageLoadedConnection = image->addLoadedCallback(boost::bind(&LLTextBase::needsReflow, &mEditor));
+ mImageLoadedConnection = image->addLoadedCallback(boost::bind(&LLTextBase::needsReflow, &mEditor, start));
}
}
diff --git a/indra/llui/lltextbase.h b/indra/llui/lltextbase.h
index ed2f239476..3dda6f4cc8 100644
--- a/indra/llui/lltextbase.h
+++ b/indra/llui/lltextbase.h
@@ -150,7 +150,7 @@ public:
void appendText(const std::string &new_text, bool prepend_newline, const LLStyle::Params& input_params = LLStyle::Params());
// force reflow of text
- void needsReflow() { mReflowNeeded = TRUE; }
+ void needsReflow(S32 index = 0);
S32 getLength() const { return getWText().length(); }
S32 getLineCount() const { return mLineInfoList.size(); }
@@ -292,7 +292,7 @@ protected:
S32 getFirstVisibleLine() const;
std::pair<S32, S32> getVisibleLines(bool fully_visible = false);
S32 getLeftOffset(S32 width);
- void reflow(S32 start_index = 0);
+ void reflow();
// cursor
void updateCursorXPos();
@@ -362,7 +362,7 @@ protected:
class LLScrollContainer* mScroller;
// transient state
- bool mReflowNeeded; // need to reflow text because of change to text contents or display region
+ S32 mReflowIndex; // index at which to start reflow. S32_MAX indicates no reflow needed.
bool mScrollNeeded; // need to change scroll region because of change to cursor position
S32 mScrollIndex; // index of first character to keep visible in scroll region
diff --git a/indra/llui/lltexteditor.cpp b/indra/llui/lltexteditor.cpp
index e76fee9f17..7a19b7427c 100644
--- a/indra/llui/lltexteditor.cpp
+++ b/indra/llui/lltexteditor.cpp
@@ -1285,8 +1285,6 @@ void LLTextEditor::cut()
gClipboard.copyFromSubstring( getWText(), left_pos, length, mSourceID );
deleteSelection( FALSE );
- needsReflow();
-
onKeyStroke();
}
@@ -1391,8 +1389,6 @@ void LLTextEditor::pasteHelper(bool is_primary)
setCursorPos(mCursorPos + insert(mCursorPos, clean_string, FALSE, LLTextSegmentPtr()));
deselect();
- needsReflow();
-
onKeyStroke();
}
@@ -1787,8 +1783,6 @@ BOOL LLTextEditor::handleKeyHere(KEY key, MASK mask )
if(text_may_have_changed)
{
- needsReflow();
-
onKeyStroke();
}
needsScroll();
@@ -1831,8 +1825,6 @@ BOOL LLTextEditor::handleUnicodeCharHere(llwchar uni_char)
// Most keystrokes will make the selection box go away, but not all will.
deselect();
- needsReflow();
-
onKeyStroke();
}
@@ -1891,8 +1883,6 @@ void LLTextEditor::doDelete()
}
onKeyStroke();
-
- needsReflow();
}
//----------------------------------------------------------------------------
@@ -1935,8 +1925,6 @@ void LLTextEditor::undo()
setCursorPos(pos);
- needsReflow();
-
onKeyStroke();
}
@@ -1979,8 +1967,6 @@ void LLTextEditor::redo()
setCursorPos(pos);
- needsReflow();
-
onKeyStroke();
}
@@ -2339,8 +2325,6 @@ void LLTextEditor::insertText(const std::string &new_text)
setCursorPos(mCursorPos + insert( mCursorPos, utf8str_to_wstring(new_text), FALSE, LLTextSegmentPtr() ));
- needsReflow();
-
setEnabled( enabled );
}
@@ -2363,8 +2347,6 @@ void LLTextEditor::appendWidget(const LLInlineViewSegment::Params& params, const
LLTextSegmentPtr segment = new LLInlineViewSegment(params, old_length, old_length + widget_wide_text.size());
insert(getLength(), widget_wide_text, FALSE, segment);
- needsReflow();
-
// Set the cursor and scroll position
if( selection_start != selection_end )
{
@@ -2389,52 +2371,6 @@ void LLTextEditor::appendWidget(const LLInlineViewSegment::Params& params, const
}
}
-
-void LLTextEditor::replaceUrlLabel(const std::string &url,
- const std::string &label)
-{
- // get the full (wide) text for the editor so we can change it
- LLWString text = getWText();
- LLWString wlabel = utf8str_to_wstring(label);
- bool modified = false;
- S32 seg_start = 0;
-
- // iterate through each segment looking for ones styled as links
- segment_set_t::iterator it;
- for (it = mSegments.begin(); it != mSegments.end(); ++it)
- {
- LLTextSegment *seg = *it;
- LLStyleConstSP style = seg->getStyle();
-
- // update segment start/end length in case we replaced text earlier
- S32 seg_length = seg->getEnd() - seg->getStart();
- seg->setStart(seg_start);
- seg->setEnd(seg_start + seg_length);
-
- // if we find a link with our Url, then replace the label
- if (style->isLink() && style->getLinkHREF() == url)
- {
- S32 start = seg->getStart();
- S32 end = seg->getEnd();
- text = text.substr(0, start) + wlabel + text.substr(end, text.size() - end + 1);
- seg->setEnd(start + wlabel.size());
- modified = true;
- }
-
- // work out the character offset for the next segment
- seg_start = seg->getEnd();
- }
-
- // update the editor with the new (wide) text string
- if (modified)
- {
- getViewModel()->setDisplay(text);
- deselect();
- setCursorPos(mCursorPos);
- needsReflow();
- }
-}
-
void LLTextEditor::removeTextFromEnd(S32 num_chars)
{
if (num_chars <= 0) return;
@@ -2446,7 +2382,6 @@ void LLTextEditor::removeTextFromEnd(S32 num_chars)
mSelectionStart = llclamp(mSelectionStart, 0, len);
mSelectionEnd = llclamp(mSelectionEnd, 0, len);
- needsReflow();
needsScroll();
}
@@ -2505,8 +2440,6 @@ BOOL LLTextEditor::tryToRevertToPristineState()
i--;
}
}
-
- needsReflow();
}
return isPristine(); // TRUE => success
@@ -2681,7 +2614,6 @@ BOOL LLTextEditor::importBuffer(const char* buffer, S32 length )
startOfDoc();
deselect();
- needsReflow();
return success;
}
@@ -2785,7 +2717,6 @@ void LLTextEditor::updatePreedit(const LLWString &preedit_string,
mPreeditStandouts = preedit_standouts;
- needsReflow();
setCursorPos(insert_preedit_at + caret_position);
// Update of the preedit should be caused by some key strokes.
diff --git a/indra/llui/lltexteditor.h b/indra/llui/lltexteditor.h
index 043dda8fa6..a136f9ccce 100644
--- a/indra/llui/lltexteditor.h
+++ b/indra/llui/lltexteditor.h
@@ -149,7 +149,6 @@ public:
void selectNext(const std::string& search_text_in, BOOL case_insensitive, BOOL wrap = TRUE);
BOOL replaceText(const std::string& search_text, const std::string& replace_text, BOOL case_insensitive, BOOL wrap = TRUE);
void replaceTextAll(const std::string& search_text, const std::string& replace_text, BOOL case_insensitive);
- void replaceUrlLabel(const std::string &url, const std::string &label);
// Undo/redo stack
void blockUndo();
diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp
index 58148ad2aa..b20de914a0 100644
--- a/indra/llui/llurlentry.cpp
+++ b/indra/llui/llurlentry.cpp
@@ -49,7 +49,7 @@ LLUrlEntryBase::~LLUrlEntryBase()
{
}
-std::string LLUrlEntryBase::getUrl(const std::string &string)
+std::string LLUrlEntryBase::getUrl(const std::string &string) const
{
return escapeUrl(string);
}
@@ -89,7 +89,7 @@ std::string LLUrlEntryBase::escapeUrl(const std::string &url) const
return LLURI::escape(url, no_escape_chars, true);
}
-std::string LLUrlEntryBase::getLabelFromWikiLink(const std::string &url)
+std::string LLUrlEntryBase::getLabelFromWikiLink(const std::string &url) const
{
// return the label part from [http://www.example.org Label]
const char *text = url.c_str();
@@ -105,7 +105,7 @@ std::string LLUrlEntryBase::getLabelFromWikiLink(const std::string &url)
return unescapeUrl(url.substr(start, url.size()-start-1));
}
-std::string LLUrlEntryBase::getUrlFromWikiLink(const std::string &string)
+std::string LLUrlEntryBase::getUrlFromWikiLink(const std::string &string) const
{
// return the url part from [http://www.example.org Label]
const char *text = string.c_str();
@@ -192,7 +192,7 @@ std::string LLUrlEntryHTTPLabel::getLabel(const std::string &url, const LLUrlLab
return getLabelFromWikiLink(url);
}
-std::string LLUrlEntryHTTPLabel::getUrl(const std::string &string)
+std::string LLUrlEntryHTTPLabel::getUrl(const std::string &string) const
{
return getUrlFromWikiLink(string);
}
@@ -217,7 +217,7 @@ std::string LLUrlEntryHTTPNoProtocol::getLabel(const std::string &url, const LLU
return unescapeUrl(url);
}
-std::string LLUrlEntryHTTPNoProtocol::getUrl(const std::string &string)
+std::string LLUrlEntryHTTPNoProtocol::getUrl(const std::string &string) const
{
if (string.find("://") == std::string::npos)
{
@@ -597,7 +597,7 @@ std::string LLUrlEntrySLLabel::getLabel(const std::string &url, const LLUrlLabel
return getLabelFromWikiLink(url);
}
-std::string LLUrlEntrySLLabel::getUrl(const std::string &string)
+std::string LLUrlEntrySLLabel::getUrl(const std::string &string) const
{
return getUrlFromWikiLink(string);
}
@@ -648,14 +648,18 @@ std::string LLUrlEntryWorldMap::getLocation(const std::string &url) const
//
LLUrlEntryNoLink::LLUrlEntryNoLink()
{
- mPattern = boost::regex("<nolink>[^[:space:]<]+</nolink>",
+ mPattern = boost::regex("<nolink>[^<]*</nolink>",
boost::regex::perl|boost::regex::icase);
mDisabledLink = true;
}
-std::string LLUrlEntryNoLink::getLabel(const std::string &url, const LLUrlLabelCallback &cb)
+std::string LLUrlEntryNoLink::getUrl(const std::string &url) const
{
// return the text between the <nolink> and </nolink> tags
return url.substr(8, url.size()-8-9);
}
+std::string LLUrlEntryNoLink::getLabel(const std::string &url, const LLUrlLabelCallback &cb)
+{
+ return getUrl(url);
+}
diff --git a/indra/llui/llurlentry.h b/indra/llui/llurlentry.h
index 94455ac247..3abada0f24 100644
--- a/indra/llui/llurlentry.h
+++ b/indra/llui/llurlentry.h
@@ -71,7 +71,7 @@ public:
boost::regex getPattern() const { return mPattern; }
/// Return the url from a string that matched the regex
- virtual std::string getUrl(const std::string &string);
+ virtual std::string getUrl(const std::string &string) const;
/// Given a matched Url, return a label for the Url
virtual std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb) { return url; }
@@ -98,8 +98,8 @@ protected:
std::string getIDStringFromUrl(const std::string &url) const;
std::string escapeUrl(const std::string &url) const;
std::string unescapeUrl(const std::string &url) const;
- std::string getLabelFromWikiLink(const std::string &url);
- std::string getUrlFromWikiLink(const std::string &string);
+ std::string getLabelFromWikiLink(const std::string &url) const;
+ std::string getUrlFromWikiLink(const std::string &string) const;
void addObserver(const std::string &id, const std::string &url, const LLUrlLabelCallback &cb);
void callObservers(const std::string &id, const std::string &label);
@@ -135,7 +135,7 @@ class LLUrlEntryHTTPLabel : public LLUrlEntryBase
public:
LLUrlEntryHTTPLabel();
/*virtual*/ std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb);
- /*virtual*/ std::string getUrl(const std::string &string);
+ /*virtual*/ std::string getUrl(const std::string &string) const;
};
///
@@ -146,7 +146,7 @@ class LLUrlEntryHTTPNoProtocol : public LLUrlEntryBase
public:
LLUrlEntryHTTPNoProtocol();
/*virtual*/ std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb);
- /*virtual*/ std::string getUrl(const std::string &string);
+ /*virtual*/ std::string getUrl(const std::string &string) const;
};
///
@@ -256,7 +256,7 @@ class LLUrlEntrySLLabel : public LLUrlEntryBase
public:
LLUrlEntrySLLabel();
/*virtual*/ std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb);
- /*virtual*/ std::string getUrl(const std::string &string);
+ /*virtual*/ std::string getUrl(const std::string &string) const;
};
///
@@ -279,6 +279,7 @@ class LLUrlEntryNoLink : public LLUrlEntryBase
public:
LLUrlEntryNoLink();
/*virtual*/ std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb);
+ /*virtual*/ std::string getUrl(const std::string &string) const;
};
#endif
diff --git a/indra/llui/llurlregistry.cpp b/indra/llui/llurlregistry.cpp
index 55eb8950e9..722dbe41b3 100644
--- a/indra/llui/llurlregistry.cpp
+++ b/indra/llui/llurlregistry.cpp
@@ -132,7 +132,8 @@ static bool stringHasUrl(const std::string &text)
text.find(".com") != std::string::npos ||
text.find(".net") != std::string::npos ||
text.find(".edu") != std::string::npos ||
- text.find(".org") != std::string::npos);
+ text.find(".org") != std::string::npos ||
+ text.find("<nolink>") != std::string::npos);
}
bool LLUrlRegistry::findUrl(const std::string &text, LLUrlMatch &match, const LLUrlLabelCallback &cb)
diff --git a/indra/llui/tests/llurlentry_test.cpp b/indra/llui/tests/llurlentry_test.cpp
index bc97cf3df2..cbb303a059 100644
--- a/indra/llui/tests/llurlentry_test.cpp
+++ b/indra/llui/tests/llurlentry_test.cpp
@@ -52,9 +52,10 @@ namespace
namespace tut
{
- void testRegex(const std::string &testname, boost::regex regex,
+ void testRegex(const std::string &testname, LLUrlEntryBase &entry,
const char *text, const std::string &expected)
{
+ boost::regex regex = entry.getPattern();
std::string url = "";
boost::cmatch result;
bool found = boost::regex_search(text, result, regex);
@@ -62,7 +63,7 @@ namespace tut
{
S32 start = static_cast<U32>(result[0].first - text);
S32 end = static_cast<U32>(result[0].second - text);
- url = std::string(text+start, end-start);
+ url = entry.getUrl(std::string(text+start, end-start));
}
ensure_equals(testname, url, expected);
}
@@ -74,74 +75,73 @@ namespace tut
// test LLUrlEntryHTTP - standard http Urls
//
LLUrlEntryHTTP url;
- boost::regex r = url.getPattern();
- testRegex("no valid url", r,
+ testRegex("no valid url", url,
"htp://slurl.com/",
"");
- testRegex("simple http (1)", r,
+ testRegex("simple http (1)", url,
"http://slurl.com/",
"http://slurl.com/");
- testRegex("simple http (2)", r,
+ testRegex("simple http (2)", url,
"http://slurl.com",
"http://slurl.com");
- testRegex("simple http (3)", r,
+ testRegex("simple http (3)", url,
"http://slurl.com/about.php",
"http://slurl.com/about.php");
- testRegex("simple https", r,
+ testRegex("simple https", url,
"https://slurl.com/about.php",
"https://slurl.com/about.php");
- testRegex("http in text (1)", r,
+ testRegex("http in text (1)", url,
"XX http://slurl.com/ XX",
"http://slurl.com/");
- testRegex("http in text (2)", r,
+ testRegex("http in text (2)", url,
"XX http://slurl.com/about.php XX",
"http://slurl.com/about.php");
- testRegex("https in text", r,
+ testRegex("https in text", url,
"XX https://slurl.com/about.php XX",
"https://slurl.com/about.php");
- testRegex("two http urls", r,
+ testRegex("two http urls", url,
"XX http://slurl.com/about.php http://secondlife.com/ XX",
"http://slurl.com/about.php");
- testRegex("http url with port and username", r,
+ testRegex("http url with port and username", url,
"XX http://nobody@slurl.com:80/about.php http://secondlife.com/ XX",
"http://nobody@slurl.com:80/about.php");
- testRegex("http url with port, username, and query string", r,
+ testRegex("http url with port, username, and query string", url,
"XX http://nobody@slurl.com:80/about.php?title=hi%20there http://secondlife.com/ XX",
"http://nobody@slurl.com:80/about.php?title=hi%20there");
// note: terminating commas will be removed by LLUrlRegistry:findUrl()
- testRegex("http url with commas in middle and terminating", r,
+ testRegex("http url with commas in middle and terminating", url,
"XX http://slurl.com/?title=Hi,There, XX",
"http://slurl.com/?title=Hi,There,");
// note: terminating periods will be removed by LLUrlRegistry:findUrl()
- testRegex("http url with periods in middle and terminating", r,
+ testRegex("http url with periods in middle and terminating", url,
"XX http://slurl.com/index.php. XX",
"http://slurl.com/index.php.");
// DEV-19842: Closing parenthesis ")" breaks urls
- testRegex("http url with brackets (1)", r,
+ testRegex("http url with brackets (1)", url,
"XX http://en.wikipedia.org/wiki/JIRA_(software) XX",
"http://en.wikipedia.org/wiki/JIRA_(software)");
// DEV-19842: Closing parenthesis ")" breaks urls
- testRegex("http url with brackets (2)", r,
+ testRegex("http url with brackets (2)", url,
"XX http://jira.secondlife.com/secure/attachment/17990/eggy+avs+in+1.21.0+(93713)+public+nightly.jpg XX",
"http://jira.secondlife.com/secure/attachment/17990/eggy+avs+in+1.21.0+(93713)+public+nightly.jpg");
// DEV-10353: URLs in chat log terminated incorrectly when newline in chat
- testRegex("http url with newlines", r,
+ testRegex("http url with newlines", url,
"XX\nhttp://www.secondlife.com/\nXX",
"http://www.secondlife.com/");
}
@@ -153,39 +153,38 @@ namespace tut
// test LLUrlEntryHTTPLabel - wiki-style http Urls with labels
//
LLUrlEntryHTTPLabel url;
- boost::regex r = url.getPattern();
- testRegex("invalid wiki url [1]", r,
+ testRegex("invalid wiki url [1]", url,
"[http://www.example.org]",
"");
- testRegex("invalid wiki url [2]", r,
+ testRegex("invalid wiki url [2]", url,
"[http://www.example.org",
"");
- testRegex("invalid wiki url [3]", r,
+ testRegex("invalid wiki url [3]", url,
"[http://www.example.org Label",
"");
- testRegex("example.org with label (spaces)", r,
+ testRegex("example.org with label (spaces)", url,
"[http://www.example.org Text]",
- "[http://www.example.org Text]");
+ "http://www.example.org");
- testRegex("example.org with label (tabs)", r,
+ testRegex("example.org with label (tabs)", url,
"[http://www.example.org\t Text]",
- "[http://www.example.org\t Text]");
+ "http://www.example.org");
- testRegex("SL http URL with label", r,
+ testRegex("SL http URL with label", url,
"[http://www.secondlife.com/ Second Life]",
- "[http://www.secondlife.com/ Second Life]");
+ "http://www.secondlife.com/");
- testRegex("SL https URL with label", r,
+ testRegex("SL https URL with label", url,
"XXX [https://www.secondlife.com/ Second Life] YYY",
- "[https://www.secondlife.com/ Second Life]");
+ "https://www.secondlife.com/");
- testRegex("SL http URL with label", r,
+ testRegex("SL http URL with label", url,
"[http://www.secondlife.com/?test=Hi%20There Second Life]",
- "[http://www.secondlife.com/?test=Hi%20There Second Life]");
+ "http://www.secondlife.com/?test=Hi%20There");
}
template<> template<>
@@ -195,69 +194,68 @@ namespace tut
// test LLUrlEntrySLURL - second life URLs
//
LLUrlEntrySLURL url;
- boost::regex r = url.getPattern();
- testRegex("no valid slurl [1]", r,
+ testRegex("no valid slurl [1]", url,
"htp://slurl.com/secondlife/Ahern/50/50/50/",
"");
- testRegex("no valid slurl [2]", r,
+ testRegex("no valid slurl [2]", url,
"http://slurl.com/secondlife/",
"");
- testRegex("no valid slurl [3]", r,
+ testRegex("no valid slurl [3]", url,
"hhtp://slurl.com/secondlife/Ahern/50/FOO/50/",
"");
- testRegex("Ahern (50,50,50) [1]", r,
+ testRegex("Ahern (50,50,50) [1]", url,
"http://slurl.com/secondlife/Ahern/50/50/50/",
"http://slurl.com/secondlife/Ahern/50/50/50/");
- testRegex("Ahern (50,50,50) [2]", r,
+ testRegex("Ahern (50,50,50) [2]", url,
"XXX http://slurl.com/secondlife/Ahern/50/50/50/ XXX",
"http://slurl.com/secondlife/Ahern/50/50/50/");
- testRegex("Ahern (50,50,50) [3]", r,
+ testRegex("Ahern (50,50,50) [3]", url,
"XXX http://slurl.com/secondlife/Ahern/50/50/50 XXX",
"http://slurl.com/secondlife/Ahern/50/50/50");
- testRegex("Ahern (50,50,50) multicase", r,
+ testRegex("Ahern (50,50,50) multicase", url,
"XXX http://SLUrl.com/SecondLife/Ahern/50/50/50/ XXX",
"http://SLUrl.com/SecondLife/Ahern/50/50/50/");
- testRegex("Ahern (50,50) [1]", r,
+ testRegex("Ahern (50,50) [1]", url,
"XXX http://slurl.com/secondlife/Ahern/50/50/ XXX",
"http://slurl.com/secondlife/Ahern/50/50/");
- testRegex("Ahern (50,50) [2]", r,
+ testRegex("Ahern (50,50) [2]", url,
"XXX http://slurl.com/secondlife/Ahern/50/50 XXX",
"http://slurl.com/secondlife/Ahern/50/50");
- testRegex("Ahern (50)", r,
+ testRegex("Ahern (50)", url,
"XXX http://slurl.com/secondlife/Ahern/50 XXX",
"http://slurl.com/secondlife/Ahern/50");
- testRegex("Ahern", r,
+ testRegex("Ahern", url,
"XXX http://slurl.com/secondlife/Ahern/ XXX",
"http://slurl.com/secondlife/Ahern/");
- testRegex("Ahern SLURL with title", r,
+ testRegex("Ahern SLURL with title", url,
"XXX http://slurl.com/secondlife/Ahern/50/50/50/?title=YOUR%20TITLE%20HERE! XXX",
"http://slurl.com/secondlife/Ahern/50/50/50/?title=YOUR%20TITLE%20HERE!");
- testRegex("Ahern SLURL with msg", r,
+ testRegex("Ahern SLURL with msg", url,
"XXX http://slurl.com/secondlife/Ahern/50/50/50/?msg=Your%20text%20here. XXX",
"http://slurl.com/secondlife/Ahern/50/50/50/?msg=Your%20text%20here.");
// DEV-21577: In-world SLURLs containing "(" or ")" are not treated as a hyperlink in chat
- testRegex("SLURL with brackets", r,
+ testRegex("SLURL with brackets", url,
"XXX http://slurl.com/secondlife/Burning%20Life%20(Hyper)/27/210/30 XXX",
"http://slurl.com/secondlife/Burning%20Life%20(Hyper)/27/210/30");
// DEV-35459: SLURLs and teleport Links not parsed properly
- testRegex("SLURL with quote", r,
+ testRegex("SLURL with quote", url,
"XXX http://slurl.com/secondlife/A'ksha%20Oasis/41/166/701 XXX",
- "http://slurl.com/secondlife/A'ksha%20Oasis/41/166/701");
+ "http://slurl.com/secondlife/A%27ksha%20Oasis/41/166/701");
}
template<> template<>
@@ -267,25 +265,24 @@ namespace tut
// test LLUrlEntryAgent - secondlife://app/agent Urls
//
LLUrlEntryAgent url;
- boost::regex r = url.getPattern();
- testRegex("Invalid Agent Url", r,
+ testRegex("Invalid Agent Url", url,
"secondlife:///app/agent/0e346d8b-4433-4d66-XXXX-fd37083abc4c/about",
"");
- testRegex("Agent Url ", r,
+ testRegex("Agent Url ", url,
"secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about",
"secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about");
- testRegex("Agent Url in text", r,
+ testRegex("Agent Url in text", url,
"XXX secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about XXX",
"secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about");
- testRegex("Agent Url multicase", r,
+ testRegex("Agent Url multicase", url,
"XXX secondlife:///App/AGENT/0E346D8B-4433-4d66-a6b0-fd37083abc4c/About XXX",
"secondlife:///App/AGENT/0E346D8B-4433-4d66-a6b0-fd37083abc4c/About");
- testRegex("Agent Url alternate command", r,
+ testRegex("Agent Url alternate command", url,
"XXX secondlife:///App/AGENT/0E346D8B-4433-4d66-a6b0-fd37083abc4c/foobar",
"secondlife:///App/AGENT/0E346D8B-4433-4d66-a6b0-fd37083abc4c/foobar");
@@ -298,25 +295,24 @@ namespace tut
// test LLUrlEntryGroup - secondlife://app/group Urls
//
LLUrlEntryGroup url;
- boost::regex r = url.getPattern();
- testRegex("Invalid Group Url", r,
+ testRegex("Invalid Group Url", url,
"secondlife:///app/group/00005ff3-4044-c79f-XXXX-fb28ae0df991/about",
"");
- testRegex("Group Url ", r,
+ testRegex("Group Url ", url,
"secondlife:///app/group/00005ff3-4044-c79f-9de8-fb28ae0df991/about",
"secondlife:///app/group/00005ff3-4044-c79f-9de8-fb28ae0df991/about");
- testRegex("Group Url ", r,
+ testRegex("Group Url ", url,
"secondlife:///app/group/00005ff3-4044-c79f-9de8-fb28ae0df991/inspect",
"secondlife:///app/group/00005ff3-4044-c79f-9de8-fb28ae0df991/inspect");
- testRegex("Group Url in text", r,
+ testRegex("Group Url in text", url,
"XXX secondlife:///app/group/00005ff3-4044-c79f-9de8-fb28ae0df991/about XXX",
"secondlife:///app/group/00005ff3-4044-c79f-9de8-fb28ae0df991/about");
- testRegex("Group Url multicase", r,
+ testRegex("Group Url multicase", url,
"XXX secondlife:///APP/Group/00005FF3-4044-c79f-9de8-fb28ae0df991/About XXX",
"secondlife:///APP/Group/00005FF3-4044-c79f-9de8-fb28ae0df991/About");
}
@@ -328,45 +324,44 @@ namespace tut
// test LLUrlEntryPlace - secondlife://<location> URLs
//
LLUrlEntryPlace url;
- boost::regex r = url.getPattern();
- testRegex("no valid slurl [1]", r,
+ testRegex("no valid slurl [1]", url,
"secondlife://Ahern/FOO/50/",
"");
- testRegex("Ahern (50,50,50) [1]", r,
+ testRegex("Ahern (50,50,50) [1]", url,
"secondlife://Ahern/50/50/50/",
"secondlife://Ahern/50/50/50/");
- testRegex("Ahern (50,50,50) [2]", r,
+ testRegex("Ahern (50,50,50) [2]", url,
"XXX secondlife://Ahern/50/50/50/ XXX",
"secondlife://Ahern/50/50/50/");
- testRegex("Ahern (50,50,50) [3]", r,
+ testRegex("Ahern (50,50,50) [3]", url,
"XXX secondlife://Ahern/50/50/50 XXX",
"secondlife://Ahern/50/50/50");
- testRegex("Ahern (50,50,50) multicase", r,
+ testRegex("Ahern (50,50,50) multicase", url,
"XXX SecondLife://Ahern/50/50/50/ XXX",
"SecondLife://Ahern/50/50/50/");
- testRegex("Ahern (50,50) [1]", r,
+ testRegex("Ahern (50,50) [1]", url,
"XXX secondlife://Ahern/50/50/ XXX",
"secondlife://Ahern/50/50/");
- testRegex("Ahern (50,50) [2]", r,
+ testRegex("Ahern (50,50) [2]", url,
"XXX secondlife://Ahern/50/50 XXX",
"secondlife://Ahern/50/50");
// DEV-21577: In-world SLURLs containing "(" or ")" are not treated as a hyperlink in chat
- testRegex("SLURL with brackets", r,
+ testRegex("SLURL with brackets", url,
"XXX secondlife://Burning%20Life%20(Hyper)/27/210/30 XXX",
"secondlife://Burning%20Life%20(Hyper)/27/210/30");
// DEV-35459: SLURLs and teleport Links not parsed properly
- testRegex("SLURL with quote", r,
+ testRegex("SLURL with quote", url,
"XXX secondlife://A'ksha%20Oasis/41/166/701 XXX",
- "secondlife://A'ksha%20Oasis/41/166/701");
+ "secondlife://A%27ksha%20Oasis/41/166/701");
}
template<> template<>
@@ -376,21 +371,20 @@ namespace tut
// test LLUrlEntryParcel - secondlife://app/parcel Urls
//
LLUrlEntryParcel url;
- boost::regex r = url.getPattern();
- testRegex("Invalid Classified Url", r,
+ testRegex("Invalid Classified Url", url,
"secondlife:///app/parcel/0000060e-4b39-e00b-XXXX-d98b1934e3a8/about",
"");
- testRegex("Classified Url ", r,
+ testRegex("Classified Url ", url,
"secondlife:///app/parcel/0000060e-4b39-e00b-d0c3-d98b1934e3a8/about",
"secondlife:///app/parcel/0000060e-4b39-e00b-d0c3-d98b1934e3a8/about");
- testRegex("Classified Url in text", r,
+ testRegex("Classified Url in text", url,
"XXX secondlife:///app/parcel/0000060e-4b39-e00b-d0c3-d98b1934e3a8/about XXX",
"secondlife:///app/parcel/0000060e-4b39-e00b-d0c3-d98b1934e3a8/about");
- testRegex("Classified Url multicase", r,
+ testRegex("Classified Url multicase", url,
"XXX secondlife:///APP/Parcel/0000060e-4b39-e00b-d0c3-d98b1934e3a8/About XXX",
"secondlife:///APP/Parcel/0000060e-4b39-e00b-d0c3-d98b1934e3a8/About");
}
@@ -401,73 +395,72 @@ namespace tut
// test LLUrlEntryTeleport - secondlife://app/teleport URLs
//
LLUrlEntryTeleport url;
- boost::regex r = url.getPattern();
- testRegex("no valid teleport [1]", r,
+ testRegex("no valid teleport [1]", url,
"http://slurl.com/secondlife/Ahern/50/50/50/",
"");
- testRegex("no valid teleport [2]", r,
+ testRegex("no valid teleport [2]", url,
"secondlife:///app/teleport/",
"");
- testRegex("no valid teleport [3]", r,
+ testRegex("no valid teleport [3]", url,
"second-life:///app/teleport/Ahern/50/50/50/",
"");
- testRegex("no valid teleport [3]", r,
+ testRegex("no valid teleport [3]", url,
"hhtp://slurl.com/secondlife/Ahern/50/FOO/50/",
"");
- testRegex("Ahern (50,50,50) [1]", r,
+ testRegex("Ahern (50,50,50) [1]", url,
"secondlife:///app/teleport/Ahern/50/50/50/",
"secondlife:///app/teleport/Ahern/50/50/50/");
- testRegex("Ahern (50,50,50) [2]", r,
+ testRegex("Ahern (50,50,50) [2]", url,
"XXX secondlife:///app/teleport/Ahern/50/50/50/ XXX",
"secondlife:///app/teleport/Ahern/50/50/50/");
- testRegex("Ahern (50,50,50) [3]", r,
+ testRegex("Ahern (50,50,50) [3]", url,
"XXX secondlife:///app/teleport/Ahern/50/50/50 XXX",
"secondlife:///app/teleport/Ahern/50/50/50");
- testRegex("Ahern (50,50,50) multicase", r,
+ testRegex("Ahern (50,50,50) multicase", url,
"XXX secondlife:///app/teleport/Ahern/50/50/50/ XXX",
"secondlife:///app/teleport/Ahern/50/50/50/");
- testRegex("Ahern (50,50) [1]", r,
+ testRegex("Ahern (50,50) [1]", url,
"XXX secondlife:///app/teleport/Ahern/50/50/ XXX",
"secondlife:///app/teleport/Ahern/50/50/");
- testRegex("Ahern (50,50) [2]", r,
+ testRegex("Ahern (50,50) [2]", url,
"XXX secondlife:///app/teleport/Ahern/50/50 XXX",
"secondlife:///app/teleport/Ahern/50/50");
- testRegex("Ahern (50)", r,
+ testRegex("Ahern (50)", url,
"XXX secondlife:///app/teleport/Ahern/50 XXX",
"secondlife:///app/teleport/Ahern/50");
- testRegex("Ahern", r,
+ testRegex("Ahern", url,
"XXX secondlife:///app/teleport/Ahern/ XXX",
"secondlife:///app/teleport/Ahern/");
- testRegex("Ahern teleport with title", r,
+ testRegex("Ahern teleport with title", url,
"XXX secondlife:///app/teleport/Ahern/50/50/50/?title=YOUR%20TITLE%20HERE! XXX",
"secondlife:///app/teleport/Ahern/50/50/50/?title=YOUR%20TITLE%20HERE!");
- testRegex("Ahern teleport with msg", r,
+ testRegex("Ahern teleport with msg", url,
"XXX secondlife:///app/teleport/Ahern/50/50/50/?msg=Your%20text%20here. XXX",
"secondlife:///app/teleport/Ahern/50/50/50/?msg=Your%20text%20here.");
// DEV-21577: In-world SLURLs containing "(" or ")" are not treated as a hyperlink in chat
- testRegex("Teleport with brackets", r,
+ testRegex("Teleport with brackets", url,
"XXX secondlife:///app/teleport/Burning%20Life%20(Hyper)/27/210/30 XXX",
"secondlife:///app/teleport/Burning%20Life%20(Hyper)/27/210/30");
// DEV-35459: SLURLs and teleport Links not parsed properly
- testRegex("Teleport url with quote", r,
+ testRegex("Teleport url with quote", url,
"XXX secondlife:///app/teleport/A'ksha%20Oasis/41/166/701 XXX",
- "secondlife:///app/teleport/A'ksha%20Oasis/41/166/701");
+ "secondlife:///app/teleport/A%27ksha%20Oasis/41/166/701");
}
template<> template<>
@@ -477,33 +470,32 @@ namespace tut
// test LLUrlEntrySL - general secondlife:// URLs
//
LLUrlEntrySL url;
- boost::regex r = url.getPattern();
- testRegex("no valid slapp [1]", r,
+ testRegex("no valid slapp [1]", url,
"http:///app/",
"");
- testRegex("valid slapp [1]", r,
+ testRegex("valid slapp [1]", url,
"secondlife:///app/",
"secondlife:///app/");
- testRegex("valid slapp [2]", r,
+ testRegex("valid slapp [2]", url,
"secondlife:///app/teleport/Ahern/50/50/50/",
"secondlife:///app/teleport/Ahern/50/50/50/");
- testRegex("valid slapp [3]", r,
+ testRegex("valid slapp [3]", url,
"secondlife:///app/foo",
"secondlife:///app/foo");
- testRegex("valid slapp [4]", r,
+ testRegex("valid slapp [4]", url,
"secondlife:///APP/foo?title=Hi%20There",
"secondlife:///APP/foo?title=Hi%20There");
- testRegex("valid slapp [5]", r,
+ testRegex("valid slapp [5]", url,
"secondlife://host/app/",
"secondlife://host/app/");
- testRegex("valid slapp [6]", r,
+ testRegex("valid slapp [6]", url,
"secondlife://host:8080/foo/bar",
"secondlife://host:8080/foo/bar");
}
@@ -515,35 +507,34 @@ namespace tut
// test LLUrlEntrySLLabel - general secondlife:// URLs with labels
//
LLUrlEntrySLLabel url;
- boost::regex r = url.getPattern();
- testRegex("invalid wiki url [1]", r,
+ testRegex("invalid wiki url [1]", url,
"[secondlife:///app/]",
"");
- testRegex("invalid wiki url [2]", r,
+ testRegex("invalid wiki url [2]", url,
"[secondlife:///app/",
"");
- testRegex("invalid wiki url [3]", r,
+ testRegex("invalid wiki url [3]", url,
"[secondlife:///app/ Label",
"");
- testRegex("agent slurl with label (spaces)", r,
+ testRegex("agent slurl with label (spaces)", url,
"[secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about Text]",
- "[secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about Text]");
+ "secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about");
- testRegex("agent slurl with label (tabs)", r,
+ testRegex("agent slurl with label (tabs)", url,
"[secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about\t Text]",
- "[secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about\t Text]");
+ "secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about");
- testRegex("agent slurl with label", r,
+ testRegex("agent slurl with label", url,
"[secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about FirstName LastName]",
- "[secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about FirstName LastName]");
+ "secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about");
- testRegex("teleport slurl with label", r,
+ testRegex("teleport slurl with label", url,
"XXX [secondlife:///app/teleport/Ahern/50/50/50/ Teleport to Ahern] YYY",
- "[secondlife:///app/teleport/Ahern/50/50/50/ Teleport to Ahern]");
+ "secondlife:///app/teleport/Ahern/50/50/50/");
}
template<> template<>
@@ -553,70 +544,98 @@ namespace tut
// test LLUrlEntryHTTPNoProtocol - general URLs without a protocol
//
LLUrlEntryHTTPNoProtocol url;
- boost::regex r = url.getPattern();
- testRegex("naked .com URL", r,
+ testRegex("naked .com URL", url,
"see google.com",
- "google.com");
+ "http://google.com");
- testRegex("naked .org URL", r,
+ testRegex("naked .org URL", url,
"see en.wikipedia.org for details",
- "en.wikipedia.org");
+ "http://en.wikipedia.org");
- testRegex("naked .net URL", r,
+ testRegex("naked .net URL", url,
"example.net",
- "example.net");
+ "http://example.net");
- testRegex("naked .edu URL (2 instances)", r,
+ testRegex("naked .edu URL (2 instances)", url,
"MIT web site is at web.mit.edu and also www.mit.edu",
- "web.mit.edu");
+ "http://web.mit.edu");
- testRegex("don't match e-mail addresses", r,
+ testRegex("don't match e-mail addresses", url,
"test@lindenlab.com",
"");
- testRegex(".com URL with path", r,
+ testRegex(".com URL with path", url,
"see secondlife.com/status for grid status",
- "secondlife.com/status");
+ "http://secondlife.com/status");
- testRegex(".com URL with port", r,
+ testRegex(".com URL with port", url,
"secondlife.com:80",
- "secondlife.com:80");
+ "http://secondlife.com:80");
- testRegex(".com URL with port and path", r,
+ testRegex(".com URL with port and path", url,
"see secondlife.com:80/status",
- "secondlife.com:80/status");
+ "http://secondlife.com:80/status");
- testRegex("www.*.com URL with port and path", r,
+ testRegex("www.*.com URL with port and path", url,
"see www.secondlife.com:80/status",
- "www.secondlife.com:80/status");
+ "http://www.secondlife.com:80/status");
- testRegex("invalid .com URL [1]", r,
+ testRegex("invalid .com URL [1]", url,
"..com",
"");
- testRegex("invalid .com URL [2]", r,
+ testRegex("invalid .com URL [2]", url,
"you.come",
"");
- testRegex("invalid .com URL [3]", r,
+ testRegex("invalid .com URL [3]", url,
"recommended",
"");
- testRegex("invalid .edu URL", r,
+ testRegex("invalid .edu URL", url,
"hi there scheduled maitenance has begun",
"");
- testRegex("invalid .net URL", r,
+ testRegex("invalid .net URL", url,
"foo.netty",
"");
- testRegex("XML tags around URL [1]", r,
+ testRegex("XML tags around URL [1]", url,
"<foo>secondlife.com</foo>",
- "secondlife.com");
+ "http://secondlife.com");
- testRegex("XML tags around URL [2]", r,
+ testRegex("XML tags around URL [2]", url,
"<foo>secondlife.com/status?bar=1</foo>",
- "secondlife.com/status?bar=1");
+ "http://secondlife.com/status?bar=1");
+ }
+
+ template<> template<>
+ void object::test<12>()
+ {
+ //
+ // test LLUrlEntryNoLink - turn off hyperlinking
+ //
+ LLUrlEntryNoLink url;
+
+ testRegex("<nolink> [1]", url,
+ "<nolink>google.com</nolink>",
+ "google.com");
+
+ testRegex("<nolink> [2]", url,
+ "<nolink>google.com",
+ "");
+
+ testRegex("<nolink> [3]", url,
+ "google.com</nolink>",
+ "");
+
+ testRegex("<nolink> [4]", url,
+ "<nolink>Hello World</nolink>",
+ "Hello World");
+
+ testRegex("<nolink> [5]", url,
+ "<nolink>My Object</nolink>",
+ "My Object");
}
}
diff --git a/indra/newview/installers/darwin/firstlook-dmg/_DS_Store b/indra/newview/installers/darwin/firstlook-dmg/_DS_Store
index 9d9fd897e7..495ec37f53 100644
--- a/indra/newview/installers/darwin/firstlook-dmg/_DS_Store
+++ b/indra/newview/installers/darwin/firstlook-dmg/_DS_Store
Binary files differ
diff --git a/indra/newview/installers/darwin/fix_application_icon_position.sh b/indra/newview/installers/darwin/fix_application_icon_position.sh
index a0b72a89f2..c6b92589db 100644
--- a/indra/newview/installers/darwin/fix_application_icon_position.sh
+++ b/indra/newview/installers/darwin/fix_application_icon_position.sh
@@ -4,11 +4,14 @@ cp -r ./../../../build-darwin-i386/newview/*.dmg ~/Desktop/TempBuild.dmg
hdid ~/Desktop/TempBuild.dmg
open -a finder /Volumes/Second\ Life\ Installer
osascript dmg-cleanup.applescript
-cp /Volumes/Second\ Life\ Installer/.DS_Store ~/Desktop/_DS_Store
-chflags nohidden ~/Desktop/_DS_Store
-cp ~/Desktop/_DS_Store ./firstlook-dmg/_DS_Store
-cp ~/Desktop/_DS_Store ./publicnightly-dmg/_DS_Store
-cp ~/Desktop/_DS_Store ./release-dmg/_DS_Store
-cp ~/Desktop/_DS_Store ./releasecandidate-dmg/_DS_Store
umount /Volumes/Second\ Life\ Installer/
-rm ~/Desktop/_DS_Store ~/Desktop/TempBuild.dmg
+hdid ~/Desktop/TempBuild.dmg
+open -a finder /Volumes/Second\ Life\ Installer
+#cp /Volumes/Second\ Life\ Installer/.DS_Store ~/Desktop/_DS_Store
+#chflags nohidden ~/Desktop/_DS_Store
+#cp ~/Desktop/_DS_Store ./firstlook-dmg/_DS_Store
+#cp ~/Desktop/_DS_Store ./publicnightly-dmg/_DS_Store
+#cp ~/Desktop/_DS_Store ./release-dmg/_DS_Store
+#cp ~/Desktop/_DS_Store ./releasecandidate-dmg/_DS_Store
+#umount /Volumes/Second\ Life\ Installer/
+#rm ~/Desktop/_DS_Store ~/Desktop/TempBuild.dmg
diff --git a/indra/newview/installers/darwin/publicnightly-dmg/_DS_Store b/indra/newview/installers/darwin/publicnightly-dmg/_DS_Store
index 9d9fd897e7..495ec37f53 100644
--- a/indra/newview/installers/darwin/publicnightly-dmg/_DS_Store
+++ b/indra/newview/installers/darwin/publicnightly-dmg/_DS_Store
Binary files differ
diff --git a/indra/newview/installers/darwin/release-dmg/_DS_Store b/indra/newview/installers/darwin/release-dmg/_DS_Store
index 9d9fd897e7..495ec37f53 100644
--- a/indra/newview/installers/darwin/release-dmg/_DS_Store
+++ b/indra/newview/installers/darwin/release-dmg/_DS_Store
Binary files differ
diff --git a/indra/newview/installers/darwin/releasecandidate-dmg/_DS_Store b/indra/newview/installers/darwin/releasecandidate-dmg/_DS_Store
index 9d9fd897e7..495ec37f53 100644
--- a/indra/newview/installers/darwin/releasecandidate-dmg/_DS_Store
+++ b/indra/newview/installers/darwin/releasecandidate-dmg/_DS_Store
Binary files differ
diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp
index a351c52ce2..1dc0e8c0a7 100644
--- a/indra/newview/llchathistory.cpp
+++ b/indra/newview/llchathistory.cpp
@@ -610,19 +610,26 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL
url += "?name=" + chat.mFromName;
url += "&owner=" + args["owner_id"].asString();
- LLViewerRegion *region = LLWorld::getInstance()->getRegionFromPosAgent(chat.mPosAgent);
- if (region)
+ std::string slurl = args["slurl"].asString();
+ if (slurl.empty())
{
- S32 x, y, z;
- LLSLURL::globalPosToXYZ(LLVector3d(chat.mPosAgent), x, y, z);
- url += "&slurl=" + region->getName() + llformat("/%d/%d/%d", x, y, z);
+ LLViewerRegion *region = LLWorld::getInstance()->getRegionFromPosAgent(chat.mPosAgent);
+ if (region)
+ {
+ S32 x, y, z;
+ LLSLURL::globalPosToXYZ(LLVector3d(chat.mPosAgent), x, y, z);
+ slurl = region->getName() + llformat("/%d/%d/%d", x, y, z);
+ }
}
+ url += "&slurl=" + slurl;
// set the link for the object name to be the objectim SLapp
+ // (don't let object names with hyperlinks override our objectim Url)
LLStyle::Params link_params(style_params);
link_params.color.control = "HTMLLinkColor";
link_params.link_href = url;
- mEditor->appendText(chat.mFromName + delimiter, false, link_params);
+ mEditor->appendText("<nolink>" + chat.mFromName + "</nolink>" + delimiter,
+ false, link_params);
}
else if ( chat.mFromName != SYSTEM_FROM && chat.mFromID.notNull() )
{
diff --git a/indra/newview/lldrawable.h b/indra/newview/lldrawable.h
index 5a10b688da..651dabff9e 100644
--- a/indra/newview/lldrawable.h
+++ b/indra/newview/lldrawable.h
@@ -44,7 +44,6 @@
#include "llquaternion.h"
#include "xform.h"
#include "llmemtype.h"
-#include "llprimitive.h"
#include "lldarray.h"
#include "llviewerobject.h"
#include "llrect.h"
diff --git a/indra/newview/llfloateranimpreview.cpp b/indra/newview/llfloateranimpreview.cpp
index 60f150bd96..904655cdc8 100644
--- a/indra/newview/llfloateranimpreview.cpp
+++ b/indra/newview/llfloateranimpreview.cpp
@@ -86,38 +86,40 @@ const F32 BASE_ANIM_TIME_OFFSET = 5.f;
std::string STATUS[] =
{
- "E_ST_OK",
- "E_ST_EOF",
- "E_ST_NO_CONSTRAINT",
- "E_ST_NO_FILE",
-"E_ST_NO_HIER",
-"E_ST_NO_JOINT",
-"E_ST_NO_NAME",
-"E_ST_NO_OFFSET",
-"E_ST_NO_CHANNELS",
-"E_ST_NO_ROTATION",
-"E_ST_NO_AXIS",
-"E_ST_NO_MOTION",
-"E_ST_NO_FRAMES",
-"E_ST_NO_FRAME_TIME",
-"E_ST_NO_POS",
-"E_ST_NO_ROT",
-"E_ST_NO_XLT_FILE",
-"E_ST_NO_XLT_HEADER",
-"E_ST_NO_XLT_NAME",
-"E_ST_NO_XLT_IGNORE",
-"E_ST_NO_XLT_RELATIVE",
-"E_ST_NO_XLT_OUTNAME",
-"E_ST_NO_XLT_MATRIX",
-"E_ST_NO_XLT_MERGECHILD",
-"E_ST_NO_XLT_MERGEPARENT",
-"E_ST_NO_XLT_PRIORITY",
-"E_ST_NO_XLT_LOOP",
-"E_ST_NO_XLT_EASEIN",
-"E_ST_NO_XLT_EASEOUT",
-"E_ST_NO_XLT_HAND",
-"E_ST_NO_XLT_EMOTE",
+ "E_ST_OK",
+ "E_ST_EOF",
+ "E_ST_NO_CONSTRAINT",
+ "E_ST_NO_FILE",
+ "E_ST_NO_HIER",
+ "E_ST_NO_JOINT",
+ "E_ST_NO_NAME",
+ "E_ST_NO_OFFSET",
+ "E_ST_NO_CHANNELS",
+ "E_ST_NO_ROTATION",
+ "E_ST_NO_AXIS",
+ "E_ST_NO_MOTION",
+ "E_ST_NO_FRAMES",
+ "E_ST_NO_FRAME_TIME",
+ "E_ST_NO_POS",
+ "E_ST_NO_ROT",
+ "E_ST_NO_XLT_FILE",
+ "E_ST_NO_XLT_HEADER",
+ "E_ST_NO_XLT_NAME",
+ "E_ST_NO_XLT_IGNORE",
+ "E_ST_NO_XLT_RELATIVE",
+ "E_ST_NO_XLT_OUTNAME",
+ "E_ST_NO_XLT_MATRIX",
+ "E_ST_NO_XLT_MERGECHILD",
+ "E_ST_NO_XLT_MERGEPARENT",
+ "E_ST_NO_XLT_PRIORITY",
+ "E_ST_NO_XLT_LOOP",
+ "E_ST_NO_XLT_EASEIN",
+ "E_ST_NO_XLT_EASEOUT",
+ "E_ST_NO_XLT_HAND",
+ "E_ST_NO_XLT_EMOTE",
+ "E_ST_BAD_ROOT"
};
+
//-----------------------------------------------------------------------------
// LLFloaterAnimPreview()
//-----------------------------------------------------------------------------
diff --git a/indra/newview/llfloaterland.cpp b/indra/newview/llfloaterland.cpp
index 0ad283d7c6..8cd63deebe 100644
--- a/indra/newview/llfloaterland.cpp
+++ b/indra/newview/llfloaterland.cpp
@@ -427,8 +427,26 @@ BOOL LLPanelLandGeneral::postBuild()
mBtnBuyLand = getChild<LLButton>("Buy Land...");
mBtnBuyLand->setClickedCallback(onClickBuyLand, (void*)&BUY_PERSONAL_LAND);
- mBtnScriptLimits = getChild<LLButton>("Scripts...");
- mBtnScriptLimits->setClickedCallback(onClickScriptLimits, this);
+ // note: on region change this will not be re checked, should not matter on Agni as
+ // 99% of the time all regions will return the same caps. In case of an erroneous setting
+ // to enabled the floater will just throw an error when trying to get it's cap
+ std::string url = gAgent.getRegion()->getCapability("LandResources");
+ if (!url.empty())
+ {
+ mBtnScriptLimits = getChild<LLButton>("Scripts...");
+ if(mBtnScriptLimits)
+ {
+ mBtnScriptLimits->setClickedCallback(onClickScriptLimits, this);
+ }
+ }
+ else
+ {
+ mBtnScriptLimits = getChild<LLButton>("Scripts...");
+ if(mBtnScriptLimits)
+ {
+ mBtnScriptLimits->setVisible(false);
+ }
+ }
mBtnBuyGroupLand = getChild<LLButton>("Buy For Group...");
mBtnBuyGroupLand->setClickedCallback(onClickBuyLand, (void*)&BUY_GROUP_LAND);
diff --git a/indra/newview/llfloaterscriptlimits.cpp b/indra/newview/llfloaterscriptlimits.cpp
index 8875e35821..4194416a01 100644
--- a/indra/newview/llfloaterscriptlimits.cpp
+++ b/indra/newview/llfloaterscriptlimits.cpp
@@ -59,10 +59,30 @@
/// LLFloaterScriptLimits
///----------------------------------------------------------------------------
-// due to server side bugs the full summary display is not possible
-// until they are fixed this define creates a simple version of the
-// summary which only shows available & correct information
-#define USE_SIMPLE_SUMMARY
+// debug switches, won't work in release
+#ifndef LL_RELEASE_FOR_DOWNLOAD
+
+// dump responder replies to llinfos for debugging
+//#define DUMP_REPLIES_TO_LLINFOS
+
+#ifdef DUMP_REPLIES_TO_LLINFOS
+#include "llsdserialize.h"
+#include "llwindow.h"
+#endif
+
+// use fake LLSD responses to check the viewer side is working correctly
+// I'm syncing this with the server side efforts so hopfully we can keep
+// the to-ing and fro-ing between the two teams to a minimum
+//#define USE_FAKE_RESPONSES
+
+#ifdef USE_FAKE_RESPONSES
+const S32 FAKE_NUMBER_OF_URLS = 329;
+const S32 FAKE_AVAILABLE_URLS = 731;
+const S32 FAKE_AMOUNT_OF_MEMORY = 66741;
+const S32 FAKE_AVAILABLE_MEMORY = 895577;
+#endif
+
+#endif
const S32 SIZE_OF_ONE_KB = 1024;
@@ -87,32 +107,41 @@ BOOL LLFloaterScriptLimits::postBuild()
}
mTab = getChild<LLTabContainer>("scriptlimits_panels");
+
+ if(!mTab)
+ {
+ llinfos << "Error! couldn't get scriptlimits_panels, aborting Script Information setup" << llendl;
+ return FALSE;
+ }
// contruct the panels
- LLPanelScriptLimitsRegionMemory* panel_memory;
- panel_memory = new LLPanelScriptLimitsRegionMemory;
- mInfoPanels.push_back(panel_memory);
+ std::string land_url = gAgent.getRegion()->getCapability("LandResources");
+ if (!land_url.empty())
+ {
+ LLPanelScriptLimitsRegionMemory* panel_memory;
+ panel_memory = new LLPanelScriptLimitsRegionMemory;
+ mInfoPanels.push_back(panel_memory);
+ LLUICtrlFactory::getInstance()->buildPanel(panel_memory, "panel_script_limits_region_memory.xml");
+ mTab->addTabPanel(panel_memory);
+ }
- LLUICtrlFactory::getInstance()->buildPanel(panel_memory, "panel_script_limits_region_memory.xml");
- mTab->addTabPanel(panel_memory);
-
- LLPanelScriptLimitsRegionURLs* panel_urls = new LLPanelScriptLimitsRegionURLs;
- mInfoPanels.push_back(panel_urls);
- LLUICtrlFactory::getInstance()->buildPanel(panel_urls, "panel_script_limits_region_urls.xml");
- mTab->addTabPanel(panel_urls);
-
- LLPanelScriptLimitsAttachment* panel_attachments = new LLPanelScriptLimitsAttachment;
- mInfoPanels.push_back(panel_attachments);
- LLUICtrlFactory::getInstance()->buildPanel(panel_attachments, "panel_script_limits_my_avatar.xml");
- mTab->addTabPanel(panel_attachments);
-
- if(selectParcelPanel)
+ std::string attachment_url = gAgent.getRegion()->getCapability("AttachmentResources");
+ if (!attachment_url.empty())
+ {
+ LLPanelScriptLimitsAttachment* panel_attachments = new LLPanelScriptLimitsAttachment;
+ mInfoPanels.push_back(panel_attachments);
+ LLUICtrlFactory::getInstance()->buildPanel(panel_attachments, "panel_script_limits_my_avatar.xml");
+ mTab->addTabPanel(panel_attachments);
+ }
+
+ if(mInfoPanels.size() > 0)
{
mTab->selectTab(0);
}
- else
+
+ if(!selectParcelPanel && (mInfoPanels.size() > 1))
{
- mTab->selectTab(2);
+ mTab->selectTab(1);
}
return TRUE;
@@ -160,6 +189,20 @@ void LLPanelScriptLimitsInfo::updateChild(LLUICtrl* child_ctr)
void fetchScriptLimitsRegionInfoResponder::result(const LLSD& content)
{
+ //we don't need to test with a fake respose here (shouldn't anyway)
+
+#ifdef DUMP_REPLIES_TO_LLINFOS
+
+ LLSDNotationStreamer notation_streamer(content);
+ std::ostringstream nice_llsd;
+ nice_llsd << notation_streamer;
+
+ OSMessageBox(nice_llsd.str(), "main cap response:", 0);
+
+ llinfos << "main cap response:" << content << llendl;
+
+#endif
+
// at this point we have an llsd which should contain ether one or two urls to the services we want.
// first we look for the details service:
if(content.has("ScriptResourceDetails"))
@@ -173,24 +216,6 @@ void fetchScriptLimitsRegionInfoResponder::result(const LLSD& content)
{
llinfos << "Failed to get llfloaterscriptlimits instance" << llendl;
}
- else
- {
-
-// temp - only show info if we get details - there's nothing to show if not until the sim gets fixed
-#ifdef USE_SIMPLE_SUMMARY
-
- LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel_memory = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
- std::string msg = LLTrans::getString("ScriptLimitsRequestDontOwnParcel");
- panel_memory->childSetValue("loading_text", LLSD(msg));
- LLPanelScriptLimitsRegionURLs* panel_urls = (LLPanelScriptLimitsRegionURLs*)tab->getChild<LLPanel>("script_limits_region_urls_panel");
- panel_urls->childSetValue("loading_text", LLSD(msg));
-
- // intentional early out as we dont want the resource summary if we are using the "simple summary"
- // and the details are missing
- return;
-#endif
- }
}
// then the summary service:
@@ -205,8 +230,61 @@ void fetchScriptLimitsRegionInfoResponder::error(U32 status, const std::string&
llinfos << "Error from responder " << reason << llendl;
}
-void fetchScriptLimitsRegionSummaryResponder::result(const LLSD& content)
+void fetchScriptLimitsRegionSummaryResponder::result(const LLSD& content_ref)
{
+#ifdef USE_FAKE_RESPONSES
+
+ LLSD fake_content;
+ LLSD summary = LLSD::emptyMap();
+ LLSD available = LLSD::emptyArray();
+ LLSD available_urls = LLSD::emptyMap();
+ LLSD available_memory = LLSD::emptyMap();
+ LLSD used = LLSD::emptyArray();
+ LLSD used_urls = LLSD::emptyMap();
+ LLSD used_memory = LLSD::emptyMap();
+
+ used_urls["type"] = "urls";
+ used_urls["amount"] = FAKE_NUMBER_OF_URLS;
+ available_urls["type"] = "urls";
+ available_urls["amount"] = FAKE_AVAILABLE_URLS;
+ used_memory["type"] = "memory";
+ used_memory["amount"] = FAKE_AMOUNT_OF_MEMORY;
+ available_memory["type"] = "memory";
+ available_memory["amount"] = FAKE_AVAILABLE_MEMORY;
+
+//summary response:{'summary':{'available':[{'amount':i731,'type':'urls'},{'amount':i895577,'type':'memory'},{'amount':i731,'type':'urls'},{'amount':i895577,'type':'memory'}],'used':[{'amount':i329,'type':'urls'},{'amount':i66741,'type':'memory'}]}}
+
+ used.append(used_urls);
+ used.append(used_memory);
+ available.append(available_urls);
+ available.append(available_memory);
+
+ summary["available"] = available;
+ summary["used"] = used;
+
+ fake_content["summary"] = summary;
+
+ const LLSD& content = fake_content;
+
+#else
+
+ const LLSD& content = content_ref;
+
+#endif
+
+
+#ifdef DUMP_REPLIES_TO_LLINFOS
+
+ LLSDNotationStreamer notation_streamer(content);
+ std::ostringstream nice_llsd;
+ nice_llsd << notation_streamer;
+
+ OSMessageBox(nice_llsd.str(), "summary response:", 0);
+
+ llinfos << "summary response:" << *content << llendl;
+
+#endif
+
LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
if(!instance)
{
@@ -217,8 +295,6 @@ void fetchScriptLimitsRegionSummaryResponder::result(const LLSD& content)
LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
LLPanelScriptLimitsRegionMemory* panel_memory = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
panel_memory->setRegionSummary(content);
- LLPanelScriptLimitsRegionURLs* panel_urls = (LLPanelScriptLimitsRegionURLs*)tab->getChild<LLPanel>("script_limits_region_urls_panel");
- panel_urls->setRegionSummary(content);
}
}
@@ -227,8 +303,82 @@ void fetchScriptLimitsRegionSummaryResponder::error(U32 status, const std::strin
llinfos << "Error from responder " << reason << llendl;
}
-void fetchScriptLimitsRegionDetailsResponder::result(const LLSD& content)
+void fetchScriptLimitsRegionDetailsResponder::result(const LLSD& content_ref)
{
+#ifdef USE_FAKE_RESPONSES
+/*
+Updated detail service, ** denotes field added:
+
+result (map)
++-parcels (array of maps)
+ +-id (uuid)
+ +-local_id (S32)**
+ +-name (string)
+ +-owner_id (uuid) (in ERS as owner, but owner_id in code)
+ +-objects (array of maps)
+ +-id (uuid)
+ +-name (string)
+ +-owner_id (uuid) (in ERS as owner, in code as owner_id)
+ +-owner_name (sting)**
+ +-location (map)**
+ +-x (float)
+ +-y (float)
+ +-z (float)
+ +-resources (map) (this is wrong in the ERS but right in code)
+ +-type (string)
+ +-amount (int)
+*/
+ LLSD fake_content;
+ LLSD resource = LLSD::emptyMap();
+ LLSD location = LLSD::emptyMap();
+ LLSD object = LLSD::emptyMap();
+ LLSD objects = LLSD::emptyArray();
+ LLSD parcel = LLSD::emptyMap();
+ LLSD parcels = LLSD::emptyArray();
+
+ resource["urls"] = FAKE_NUMBER_OF_URLS;
+ resource["memory"] = FAKE_AMOUNT_OF_MEMORY;
+
+ location["x"] = 128.0f;
+ location["y"] = 128.0f;
+ location["z"] = 0.0f;
+
+ object["id"] = LLUUID("d574a375-0c6c-fe3d-5733-da669465afc7");
+ object["name"] = "Gabs fake Object!";
+ object["owner_id"] = LLUUID("8dbf2d41-69a0-4e5e-9787-0c9d297bc570");
+ object["owner_name"] = "Gabs Linden";
+ object["location"] = location;
+ object["resources"] = resource;
+
+ objects.append(object);
+
+ parcel["id"] = LLUUID("da05fb28-0d20-e593-2728-bddb42dd0160");
+ parcel["local_id"] = 42;
+ parcel["name"] = "Gabriel Linden\'s Sub Plot";
+ parcel["objects"] = objects;
+ parcels.append(parcel);
+
+ fake_content["parcels"] = parcels;
+ const LLSD& content = fake_content;
+
+#else
+
+ const LLSD& content = content_ref;
+
+#endif
+
+#ifdef DUMP_REPLIES_TO_LLINFOS
+
+ LLSDNotationStreamer notation_streamer(content);
+ std::ostringstream nice_llsd;
+ nice_llsd << notation_streamer;
+
+ OSMessageBox(nice_llsd.str(), "details response:", 0);
+
+ llinfos << "details response:" << content << llendl;
+
+#endif
+
LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
if(!instance)
@@ -238,11 +388,22 @@ void fetchScriptLimitsRegionDetailsResponder::result(const LLSD& content)
else
{
LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel_memory = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
- panel_memory->setRegionDetails(content);
-
- LLPanelScriptLimitsRegionURLs* panel_urls = (LLPanelScriptLimitsRegionURLs*)tab->getChild<LLPanel>("script_limits_region_urls_panel");
- panel_urls->setRegionDetails(content);
+ if(tab)
+ {
+ LLPanelScriptLimitsRegionMemory* panel_memory = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
+ if(panel_memory)
+ {
+ panel_memory->setRegionDetails(content);
+ }
+ else
+ {
+ llinfos << "Failed to get scriptlimits memory panel" << llendl;
+ }
+ }
+ else
+ {
+ llinfos << "Failed to get scriptlimits_panels" << llendl;
+ }
}
}
@@ -251,8 +412,61 @@ void fetchScriptLimitsRegionDetailsResponder::error(U32 status, const std::strin
llinfos << "Error from responder " << reason << llendl;
}
-void fetchScriptLimitsAttachmentInfoResponder::result(const LLSD& content)
+void fetchScriptLimitsAttachmentInfoResponder::result(const LLSD& content_ref)
{
+
+#ifdef USE_FAKE_RESPONSES
+
+ // just add the summary, as that's all I'm testing currently!
+ LLSD fake_content = LLSD::emptyMap();
+ LLSD summary = LLSD::emptyMap();
+ LLSD available = LLSD::emptyArray();
+ LLSD available_urls = LLSD::emptyMap();
+ LLSD available_memory = LLSD::emptyMap();
+ LLSD used = LLSD::emptyArray();
+ LLSD used_urls = LLSD::emptyMap();
+ LLSD used_memory = LLSD::emptyMap();
+
+ used_urls["type"] = "urls";
+ used_urls["amount"] = FAKE_NUMBER_OF_URLS;
+ available_urls["type"] = "urls";
+ available_urls["amount"] = FAKE_AVAILABLE_URLS;
+ used_memory["type"] = "memory";
+ used_memory["amount"] = FAKE_AMOUNT_OF_MEMORY;
+ available_memory["type"] = "memory";
+ available_memory["amount"] = FAKE_AVAILABLE_MEMORY;
+
+ used.append(used_urls);
+ used.append(used_memory);
+ available.append(available_urls);
+ available.append(available_memory);
+
+ summary["available"] = available;
+ summary["used"] = used;
+
+ fake_content["summary"] = summary;
+ fake_content["attachments"] = content_ref["attachments"];
+
+ const LLSD& content = fake_content;
+
+#else
+
+ const LLSD& content = content_ref;
+
+#endif
+
+#ifdef DUMP_REPLIES_TO_LLINFOS
+
+ LLSDNotationStreamer notation_streamer(content);
+ std::ostringstream nice_llsd;
+ nice_llsd << notation_streamer;
+
+ OSMessageBox(nice_llsd.str(), "attachment response:", 0);
+
+ llinfos << "attachment response:" << content << llendl;
+
+#endif
+
LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
if(!instance)
@@ -262,8 +476,22 @@ void fetchScriptLimitsAttachmentInfoResponder::result(const LLSD& content)
else
{
LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsAttachment* panel = (LLPanelScriptLimitsAttachment*)tab->getChild<LLPanel>("script_limits_my_avatar_panel");
- panel->setAttachmentDetails(content);
+ if(tab)
+ {
+ LLPanelScriptLimitsAttachment* panel = (LLPanelScriptLimitsAttachment*)tab->getChild<LLPanel>("script_limits_my_avatar_panel");
+ if(panel)
+ {
+ panel->setAttachmentDetails(content);
+ }
+ else
+ {
+ llinfos << "Failed to get script_limits_my_avatar_panel" << llendl;
+ }
+ }
+ else
+ {
+ llinfos << "Failed to get scriptlimits_panels" << llendl;
+ }
}
}
@@ -309,7 +537,7 @@ void LLPanelScriptLimitsRegionMemory::processParcelInfo(const LLParcelData& parc
{
std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestWaiting");
childSetValue("loading_text", LLSD(msg_waiting));
- }
+ }
}
void LLPanelScriptLimitsRegionMemory::setParcelID(const LLUUID& parcel_id)
@@ -341,6 +569,11 @@ void LLPanelScriptLimitsRegionMemory::onNameCache(
std::string name = first_name + " " + last_name;
LLScrollListCtrl *list = getChild<LLScrollListCtrl>("scripts_list");
+ if(!list)
+ {
+ return;
+ }
+
std::vector<LLSD>::iterator id_itor;
for (id_itor = mObjectListItems.begin(); id_itor != mObjectListItems.end(); ++id_itor)
{
@@ -351,33 +584,8 @@ void LLPanelScriptLimitsRegionMemory::onNameCache(
if(item)
{
- item->getColumn(2)->setValue(LLSD(name));
- element["columns"][2]["value"] = name;
- }
- }
- }
-
- // fill in the url's tab if needed, all urls must have memory so we can do it all here
- LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
- if(instance)
- {
- LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_urls_panel");
-
- LLScrollListCtrl *list = panel->getChild<LLScrollListCtrl>("scripts_list");
- std::vector<LLSD>::iterator id_itor;
- for (id_itor = mObjectListItems.begin(); id_itor != mObjectListItems.end(); ++id_itor)
- {
- LLSD element = *id_itor;
- if(element["owner_id"].asUUID() == id)
- {
- LLScrollListItem* item = list->getItem(element["id"].asUUID());
-
- if(item)
- {
- item->getColumn(2)->setValue(LLSD(name));
- element["columns"][2]["value"] = name;
- }
+ item->getColumn(3)->setValue(LLSD(name));
+ element["columns"][3]["value"] = name;
}
}
}
@@ -386,6 +594,12 @@ void LLPanelScriptLimitsRegionMemory::onNameCache(
void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content)
{
LLScrollListCtrl *list = getChild<LLScrollListCtrl>("scripts_list");
+
+ if(!list)
+ {
+ llinfos << "Error getting the scripts_list control" << llendl;
+ return;
+ }
S32 number_parcels = content["parcels"].size();
@@ -394,130 +608,197 @@ void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content)
std::string msg_parcels = LLTrans::getString("ScriptLimitsParcelsOwned", args_parcels);
childSetValue("parcels_listed", LLSD(msg_parcels));
- S32 total_objects = 0;
- S32 total_size = 0;
-
std::vector<LLUUID> names_requested;
+ // This makes the assumption that all objects will have the same set
+ // of attributes, ie they will all have, or none will have locations
+ // This is a pretty safe assumption as it's reliant on server version.
+ bool has_locations = false;
+ bool has_local_ids = false;
+
for(S32 i = 0; i < number_parcels; i++)
{
std::string parcel_name = content["parcels"][i]["name"].asString();
LLUUID parcel_id = content["parcels"][i]["id"].asUUID();
S32 number_objects = content["parcels"][i]["objects"].size();
+
+ S32 local_id = 0;
+ if(content["parcels"][i].has("local_id"))
+ {
+ // if any locations are found flag that we can use them and turn on the highlight button
+ has_local_ids = true;
+ local_id = content["parcels"][i]["local_id"].asInteger();
+ }
+
for(S32 j = 0; j < number_objects; j++)
{
S32 size = content["parcels"][i]["objects"][j]["resources"]["memory"].asInteger() / SIZE_OF_ONE_KB;
- total_size += size;
+
+ S32 urls = content["parcels"][i]["objects"][j]["resources"]["urls"].asInteger();
std::string name_buf = content["parcels"][i]["objects"][j]["name"].asString();
LLUUID task_id = content["parcels"][i]["objects"][j]["id"].asUUID();
LLUUID owner_id = content["parcels"][i]["objects"][j]["owner_id"].asUUID();
-
+
+ F32 location_x = 0.0f;
+ F32 location_y = 0.0f;
+ F32 location_z = 0.0f;
+
+ if(content["parcels"][i]["objects"][j].has("location"))
+ {
+ // if any locations are found flag that we can use them and turn on the highlight button
+ LLVector3 vec = ll_vector3_from_sd(content["parcels"][i]["objects"][j]["location"]);
+ has_locations = true;
+ location_x = vec.mV[0];
+ location_y = vec.mV[1];
+ location_z = vec.mV[2];
+ }
+
std::string owner_buf;
-
- BOOL name_is_cached = gCacheName->getFullName(owner_id, owner_buf);
- if(!name_is_cached)
+
+ // in the future the server will give us owner names, so see if we're there yet:
+ if(content["parcels"][i]["objects"][j].has("owner_name"))
+ {
+ owner_buf = content["parcels"][i]["objects"][j]["owner_name"].asString();
+ }
+ // ...and if not use the slightly more painful method of disovery:
+ else
{
- if(std::find(names_requested.begin(), names_requested.end(), owner_id) == names_requested.end())
+ BOOL name_is_cached = gCacheName->getFullName(owner_id, owner_buf);
+ if(!name_is_cached)
{
- names_requested.push_back(owner_id);
- gCacheName->get(owner_id, TRUE,
- boost::bind(&LLPanelScriptLimitsRegionMemory::onNameCache,
- this, _1, _2, _3));
+ if(std::find(names_requested.begin(), names_requested.end(), owner_id) == names_requested.end())
+ {
+ names_requested.push_back(owner_id);
+ gCacheName->get(owner_id, TRUE,
+ boost::bind(&LLPanelScriptLimitsRegionMemory::onNameCache,
+ this, _1, _2, _3));
+ }
}
}
LLSD element;
element["id"] = task_id;
- element["owner_id"] = owner_id;
element["columns"][0]["column"] = "size";
element["columns"][0]["value"] = llformat("%d", size);
element["columns"][0]["font"] = "SANSSERIF";
- element["columns"][1]["column"] = "name";
- element["columns"][1]["value"] = name_buf;
+ element["columns"][1]["column"] = "urls";
+ element["columns"][1]["value"] = llformat("%d", urls);
element["columns"][1]["font"] = "SANSSERIF";
- element["columns"][2]["column"] = "owner";
- element["columns"][2]["value"] = owner_buf;
+ element["columns"][2]["column"] = "name";
+ element["columns"][2]["value"] = name_buf;
element["columns"][2]["font"] = "SANSSERIF";
- element["columns"][3]["column"] = "location";
- element["columns"][3]["value"] = parcel_name;
+ element["columns"][3]["column"] = "owner";
+ element["columns"][3]["value"] = owner_buf;
element["columns"][3]["font"] = "SANSSERIF";
+ element["columns"][4]["column"] = "parcel";
+ element["columns"][4]["value"] = parcel_name;
+ element["columns"][4]["font"] = "SANSSERIF";
+ element["columns"][5]["column"] = "location";
+ if(has_locations)
+ {
+ element["columns"][5]["value"] = llformat("<%0.1f,%0.1f,%0.1f>", location_x, location_y, location_z);
+ }
+ else
+ {
+ element["columns"][5]["value"] = "";
+ }
+ element["columns"][5]["font"] = "SANSSERIF";
list->addElement(element, ADD_SORTED);
+
+ element["owner_id"] = owner_id;
+ element["local_id"] = local_id;
mObjectListItems.push_back(element);
- total_objects++;
}
}
- mParcelMemoryUsed =total_size;
- mGotParcelMemoryUsed = TRUE;
- populateParcelMemoryText();
-}
+ if (has_locations)
+ {
+ LLButton* btn = getChild<LLButton>("highlight_btn");
+ if(btn)
+ {
+ btn->setVisible(true);
+ }
+ }
-void LLPanelScriptLimitsRegionMemory::populateParcelMemoryText()
-{
- if(mGotParcelMemoryUsed && mGotParcelMemoryMax)
+ if (has_local_ids)
{
-#ifdef USE_SIMPLE_SUMMARY
- LLStringUtil::format_map_t args_parcel_memory;
- args_parcel_memory["[COUNT]"] = llformat ("%d", mParcelMemoryUsed);
- std::string msg_parcel_memory = LLTrans::getString("ScriptLimitsMemoryUsedSimple", args_parcel_memory);
- childSetValue("memory_used", LLSD(msg_parcel_memory));
-#else
- S32 parcel_memory_available = mParcelMemoryMax - mParcelMemoryUsed;
+ LLButton* btn = getChild<LLButton>("return_btn");
+ if(btn)
+ {
+ btn->setVisible(true);
+ }
+ }
- LLStringUtil::format_map_t args_parcel_memory;
- args_parcel_memory["[COUNT]"] = llformat ("%d", mParcelMemoryUsed);
- args_parcel_memory["[MAX]"] = llformat ("%d", mParcelMemoryMax);
- args_parcel_memory["[AVAILABLE]"] = llformat ("%d", parcel_memory_available);
- std::string msg_parcel_memory = LLTrans::getString("ScriptLimitsMemoryUsed", args_parcel_memory);
- childSetValue("memory_used", LLSD(msg_parcel_memory));
-#endif
+ // save the structure to make object return easier
+ mContent = content;
- childSetValue("loading_text", LLSD(std::string("")));
- }
+ childSetValue("loading_text", LLSD(std::string("")));
}
void LLPanelScriptLimitsRegionMemory::setRegionSummary(LLSD content)
{
- if(content["summary"]["available"][0]["type"].asString() == std::string("memory"))
+ if(content["summary"]["used"][0]["type"].asString() == std::string("memory"))
{
- mParcelMemoryMax = content["summary"]["available"][0]["amount"].asInteger();
- mGotParcelMemoryMax = TRUE;
+ mParcelMemoryUsed = content["summary"]["used"][0]["amount"].asInteger() / SIZE_OF_ONE_KB;
+ mParcelMemoryMax = content["summary"]["available"][0]["amount"].asInteger() / SIZE_OF_ONE_KB;
+ mGotParcelMemoryUsed = TRUE;
}
- else if(content["summary"]["available"][1]["type"].asString() == std::string("memory"))
+ else if(content["summary"]["used"][1]["type"].asString() == std::string("memory"))
{
- mParcelMemoryMax = content["summary"]["available"][1]["amount"].asInteger();
- mGotParcelMemoryMax = TRUE;
+ mParcelMemoryUsed = content["summary"]["used"][1]["amount"].asInteger() / SIZE_OF_ONE_KB;
+ mParcelMemoryMax = content["summary"]["available"][1]["amount"].asInteger() / SIZE_OF_ONE_KB;
+ mGotParcelMemoryUsed = TRUE;
}
else
{
llinfos << "summary doesn't contain memory info" << llendl;
return;
}
-/*
- currently this is broken on the server, so we get this value from the details section
- and update via populateParcelMemoryText() when both sets of information have been returned
-
- when the sim is fixed this should be used instead:
- if(content["summary"]["used"][0]["type"].asString() == std::string("memory"))
+
+ if(content["summary"]["used"][0]["type"].asString() == std::string("urls"))
{
- mParcelMemoryUsed = content["summary"]["used"][0]["amount"].asInteger();
- mGotParcelMemoryUsed = TRUE;
+ mParcelURLsUsed = content["summary"]["used"][0]["amount"].asInteger();
+ mParcelURLsMax = content["summary"]["available"][0]["amount"].asInteger();
+ mGotParcelURLsUsed = TRUE;
}
- else if(content["summary"]["used"][1]["type"].asString() == std::string("memory"))
+ else if(content["summary"]["used"][1]["type"].asString() == std::string("urls"))
{
- mParcelMemoryUsed = content["summary"]["used"][1]["amount"].asInteger();
- mGotParcelMemoryUsed = TRUE;
+ mParcelURLsUsed = content["summary"]["used"][1]["amount"].asInteger();
+ mParcelURLsMax = content["summary"]["available"][1]["amount"].asInteger();
+ mGotParcelURLsUsed = TRUE;
}
else
{
- //ERROR!!!
+ llinfos << "summary doesn't contain urls info" << llendl;
return;
- }*/
+ }
- populateParcelMemoryText();
+ if((mParcelMemoryUsed >= 0) && (mParcelMemoryMax >= 0))
+ {
+ S32 parcel_memory_available = mParcelMemoryMax - mParcelMemoryUsed;
+
+ LLStringUtil::format_map_t args_parcel_memory;
+ args_parcel_memory["[COUNT]"] = llformat ("%d", mParcelMemoryUsed);
+ args_parcel_memory["[MAX]"] = llformat ("%d", mParcelMemoryMax);
+ args_parcel_memory["[AVAILABLE]"] = llformat ("%d", parcel_memory_available);
+ std::string msg_parcel_memory = LLTrans::getString("ScriptLimitsMemoryUsed", args_parcel_memory);
+ childSetValue("memory_used", LLSD(msg_parcel_memory));
+ }
+
+ if((mParcelURLsUsed >= 0) && (mParcelURLsMax >= 0))
+ {
+ S32 parcel_urls_available = mParcelURLsMax - mParcelURLsUsed;
+
+ LLStringUtil::format_map_t args_parcel_urls;
+ args_parcel_urls["[COUNT]"] = llformat ("%d", mParcelURLsUsed);
+ args_parcel_urls["[MAX]"] = llformat ("%d", mParcelURLsMax);
+ args_parcel_urls["[AVAILABLE]"] = llformat ("%d", parcel_urls_available);
+ std::string msg_parcel_urls = LLTrans::getString("ScriptLimitsURLsUsed", args_parcel_urls);
+ childSetValue("urls_used", LLSD(msg_parcel_urls));
+ }
}
BOOL LLPanelScriptLimitsRegionMemory::postBuild()
@@ -530,6 +811,10 @@ BOOL LLPanelScriptLimitsRegionMemory::postBuild()
childSetValue("loading_text", LLSD(msg_waiting));
LLScrollListCtrl *list = getChild<LLScrollListCtrl>("scripts_list");
+ if(!list)
+ {
+ return FALSE;
+ }
//set all columns to resizable mode even if some columns will be empty
for(S32 column = 0; column < list->getNumColumns(); column++)
@@ -548,18 +833,11 @@ BOOL LLPanelScriptLimitsRegionMemory::StartRequestChain()
LLFloaterLand* instance = LLFloaterReg::getTypedInstance<LLFloaterLand>("about_land");
if(!instance)
{
- //this isnt really an error...
-// llinfos << "Failed to get about land instance" << llendl;
-// std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestError");
childSetValue("loading_text", LLSD(std::string("")));
//might have to do parent post build here
//if not logic below could use early outs
return FALSE;
}
-
- LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionURLs* panel_urls = (LLPanelScriptLimitsRegionURLs*)tab->getChild<LLPanel>("script_limits_region_urls_panel");
-
LLParcel* parcel = instance->getCurrentSelectedParcel();
LLViewerRegion* region = LLViewerParcelMgr::getInstance()->getSelectionRegion();
@@ -575,7 +853,6 @@ BOOL LLPanelScriptLimitsRegionMemory::StartRequestChain()
{
std::string msg_wrong_region = LLTrans::getString("ScriptLimitsRequestWrongRegion");
childSetValue("loading_text", LLSD(msg_wrong_region));
- panel_urls->childSetValue("loading_text", LLSD(msg_wrong_region));
return FALSE;
}
@@ -605,14 +882,12 @@ BOOL LLPanelScriptLimitsRegionMemory::StartRequestChain()
std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestError");
childSetValue("loading_text", LLSD(msg_waiting));
- panel_urls->childSetValue("loading_text", LLSD(msg_waiting));
}
}
else
{
- std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestError");
+ std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestNoParcelSelected");
childSetValue("loading_text", LLSD(msg_waiting));
- panel_urls->childSetValue("loading_text", LLSD(msg_waiting));
}
return LLPanelScriptLimitsInfo::postBuild();
@@ -629,10 +904,13 @@ void LLPanelScriptLimitsRegionMemory::clearList()
mGotParcelMemoryUsed = FALSE;
mGotParcelMemoryMax = FALSE;
+ mGotParcelURLsUsed = FALSE;
+ mGotParcelURLsMax = FALSE;
LLStringUtil::format_map_t args_parcel_memory;
std::string msg_empty_string("");
childSetValue("memory_used", LLSD(msg_empty_string));
+ childSetValue("urls_used", LLSD(msg_empty_string));
childSetValue("parcels_listed", LLSD(msg_empty_string));
mObjectListItems.clear();
@@ -647,13 +925,16 @@ void LLPanelScriptLimitsRegionMemory::onClickRefresh(void* userdata)
if(instance)
{
LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel_memory = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
- panel_memory->clearList();
-
- LLPanelScriptLimitsRegionURLs* panel_urls = (LLPanelScriptLimitsRegionURLs*)tab->getChild<LLPanel>("script_limits_region_urls_panel");
- panel_urls->clearList();
+ if(tab)
+ {
+ LLPanelScriptLimitsRegionMemory* panel_memory = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
+ if(panel_memory)
+ {
+ panel_memory->clearList();
- panel_memory->StartRequestChain();
+ panel_memory->StartRequestChain();
+ }
+ }
return;
}
else
@@ -665,78 +946,80 @@ void LLPanelScriptLimitsRegionMemory::onClickRefresh(void* userdata)
void LLPanelScriptLimitsRegionMemory::showBeacon()
{
-/* LLScrollListCtrl* list = getChild<LLScrollListCtrl>("scripts_list");
+ LLScrollListCtrl* list = getChild<LLScrollListCtrl>("scripts_list");
if (!list) return;
LLScrollListItem* first_selected = list->getFirstSelected();
if (!first_selected) return;
- std::string name = first_selected->getColumn(1)->getValue().asString();
- std::string pos_string = first_selected->getColumn(3)->getValue().asString();
+ std::string name = first_selected->getColumn(2)->getValue().asString();
+ std::string pos_string = first_selected->getColumn(5)->getValue().asString();
- llinfos << ">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>" <<llendl;
- llinfos << "name = " << name << " pos = " << pos_string << llendl;
-
F32 x, y, z;
S32 matched = sscanf(pos_string.c_str(), "<%g,%g,%g>", &x, &y, &z);
if (matched != 3) return;
LLVector3 pos_agent(x, y, z);
LLVector3d pos_global = gAgent.getPosGlobalFromAgent(pos_agent);
- llinfos << "name = " << name << " pos = " << pos_string << llendl;
+
std::string tooltip("");
- LLTracker::trackLocation(pos_global, name, tooltip, LLTracker::LOCATION_ITEM);*/
+ LLTracker::trackLocation(pos_global, name, tooltip, LLTracker::LOCATION_ITEM);
}
// static
void LLPanelScriptLimitsRegionMemory::onClickHighlight(void* userdata)
{
-/* llinfos << "LLPanelRegionGeneralInfo::onClickHighlight" << llendl;
+ llinfos << "LLPanelRegionGeneralInfo::onClickHighlight" << llendl;
LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
if(instance)
{
LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
- panel->showBeacon();
+ if(tab)
+ {
+ LLPanelScriptLimitsRegionMemory* panel = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
+ if(panel)
+ {
+ panel->showBeacon();
+ }
+ }
return;
}
else
{
llwarns << "could not find LLPanelScriptLimitsRegionMemory instance after highlight button clicked" << llendl;
-// std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestError");
-// panel->childSetValue("loading_text", LLSD(msg_waiting));
return;
- }*/
+ }
}
-void LLPanelScriptLimitsRegionMemory::returnObjects()
+void LLPanelScriptLimitsRegionMemory::returnObjectsFromParcel(S32 local_id)
{
-/* llinfos << "started" << llendl;
LLMessageSystem *msg = gMessageSystem;
LLViewerRegion* region = gAgent.getRegion();
if (!region) return;
- llinfos << "got region" << llendl;
LLCtrlListInterface *list = childGetListInterface("scripts_list");
if (!list || list->getItemCount() == 0) return;
- llinfos << "got list" << llendl;
- std::vector<LLUUID>::iterator id_itor;
+ std::vector<LLSD>::iterator id_itor;
bool start_message = true;
- for (id_itor = mObjectListIDs.begin(); id_itor != mObjectListIDs.end(); ++id_itor)
+ for (id_itor = mObjectListItems.begin(); id_itor != mObjectListItems.end(); ++id_itor)
{
- LLUUID task_id = *id_itor;
- llinfos << task_id << llendl;
- if (!list->isSelected(task_id))
+ LLSD element = *id_itor;
+ if (!list->isSelected(element["id"].asUUID()))
{
- llinfos << "not selected" << llendl;
// Selected only
continue;
}
- llinfos << "selected" << llendl;
+
+ if(element["local_id"].asInteger() != local_id)
+ {
+ // Not the parcel we are looking for
+ continue;
+ }
+
if (start_message)
{
msg->newMessageFast(_PREHASH_ParcelReturnObjects);
@@ -744,285 +1027,74 @@ void LLPanelScriptLimitsRegionMemory::returnObjects()
msg->addUUIDFast(_PREHASH_AgentID, gAgent.getID());
msg->addUUIDFast(_PREHASH_SessionID,gAgent.getSessionID());
msg->nextBlockFast(_PREHASH_ParcelData);
- msg->addS32Fast(_PREHASH_LocalID, -1); // Whole region
- msg->addS32Fast(_PREHASH_ReturnType, RT_LIST);
+ msg->addS32Fast(_PREHASH_LocalID, element["local_id"].asInteger());
+ msg->addU32Fast(_PREHASH_ReturnType, RT_LIST);
start_message = false;
- llinfos << "start message" << llendl;
}
msg->nextBlockFast(_PREHASH_TaskIDs);
- msg->addUUIDFast(_PREHASH_TaskID, task_id);
- llinfos << "added id" << llendl;
+ msg->addUUIDFast(_PREHASH_TaskID, element["id"].asUUID());
if (msg->isSendFullFast(_PREHASH_TaskIDs))
{
msg->sendReliable(region->getHost());
start_message = true;
- llinfos << "sent 1" << llendl;
}
}
if (!start_message)
{
msg->sendReliable(region->getHost());
- llinfos << "sent 2" << llendl;
- }*/
+ }
}
-// static
-void LLPanelScriptLimitsRegionMemory::onClickReturn(void* userdata)
+void LLPanelScriptLimitsRegionMemory::returnObjects()
{
-/* llinfos << "LLPanelRegionGeneralInfo::onClickReturn" << llendl;
- LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
- if(instance)
+ if(!mContent.has("parcels"))
{
- LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
- panel->returnObjects();
return;
}
- else
- {
- llwarns << "could not find LLPanelScriptLimitsRegionMemory instance after highlight button clicked" << llendl;
-// std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestError");
-// panel->childSetValue("loading_text", LLSD(msg_waiting));
- return;
- }*/
-}
-
-///----------------------------------------------------------------------------
-// URLs Panel
-///----------------------------------------------------------------------------
-
-void LLPanelScriptLimitsRegionURLs::setRegionDetails(LLSD content)
-{
- LLScrollListCtrl *list = getChild<LLScrollListCtrl>("scripts_list");
-
- S32 number_parcels = content["parcels"].size();
-
- LLStringUtil::format_map_t args_parcels;
- args_parcels["[PARCELS]"] = llformat ("%d", number_parcels);
- std::string msg_parcels = LLTrans::getString("ScriptLimitsParcelsOwned", args_parcels);
- childSetValue("parcels_listed", LLSD(msg_parcels));
-
- S32 total_objects = 0;
- S32 total_size = 0;
+ S32 number_parcels = mContent["parcels"].size();
+
+ // a message per parcel containing all objects to be returned from that parcel
for(S32 i = 0; i < number_parcels; i++)
{
- std::string parcel_name = content["parcels"][i]["name"].asString();
- llinfos << parcel_name << llendl;
-
- S32 number_objects = content["parcels"][i]["objects"].size();
- for(S32 j = 0; j < number_objects; j++)
+ S32 local_id = 0;
+ if(mContent["parcels"][i].has("local_id"))
{
- if(content["parcels"][i]["objects"][j]["resources"].has("urls"))
- {
- S32 size = content["parcels"][i]["objects"][j]["resources"]["urls"].asInteger();
- total_size += size;
-
- std::string name_buf = content["parcels"][i]["objects"][j]["name"].asString();
- LLUUID task_id = content["parcels"][i]["objects"][j]["id"].asUUID();
- LLUUID owner_id = content["parcels"][i]["objects"][j]["owner_id"].asUUID();
-
- std::string owner_buf;
- gCacheName->getFullName(owner_id, owner_buf); //dont care if this fails as the memory tab will request and fill the field
-
- LLSD element;
-
- element["id"] = task_id;
- element["columns"][0]["column"] = "urls";
- element["columns"][0]["value"] = llformat("%d", size);
- element["columns"][0]["font"] = "SANSSERIF";
- element["columns"][1]["column"] = "name";
- element["columns"][1]["value"] = name_buf;
- element["columns"][1]["font"] = "SANSSERIF";
- element["columns"][2]["column"] = "owner";
- element["columns"][2]["value"] = owner_buf;
- element["columns"][2]["font"] = "SANSSERIF";
- element["columns"][3]["column"] = "location";
- element["columns"][3]["value"] = parcel_name;
- element["columns"][3]["font"] = "SANSSERIF";
-
- list->addElement(element);
- mObjectListItems.push_back(element);
- total_objects++;
- }
+ local_id = mContent["parcels"][i]["local_id"].asInteger();
+ returnObjectsFromParcel(local_id);
}
}
-
- mParcelURLsUsed =total_size;
- mGotParcelURLsUsed = TRUE;
- populateParcelURLsText();
-}
-
-void LLPanelScriptLimitsRegionURLs::populateParcelURLsText()
-{
- if(mGotParcelURLsUsed && mGotParcelURLsMax)
- {
-
-#ifdef USE_SIMPLE_SUMMARY
- LLStringUtil::format_map_t args_parcel_urls;
- args_parcel_urls["[COUNT]"] = llformat ("%d", mParcelURLsUsed);
- std::string msg_parcel_urls = LLTrans::getString("ScriptLimitsURLsUsedSimple", args_parcel_urls);
- childSetValue("urls_used", LLSD(msg_parcel_urls));
-#else
- S32 parcel_urls_available = mParcelURLsMax - mParcelURLsUsed;
- LLStringUtil::format_map_t args_parcel_urls;
- args_parcel_urls["[COUNT]"] = llformat ("%d", mParcelURLsUsed);
- args_parcel_urls["[MAX]"] = llformat ("%d", mParcelURLsMax);
- args_parcel_urls["[AVAILABLE]"] = llformat ("%d", parcel_urls_available);
- std::string msg_parcel_urls = LLTrans::getString("ScriptLimitsURLsUsed", args_parcel_urls);
- childSetValue("urls_used", LLSD(msg_parcel_urls));
-#endif
-
- childSetValue("loading_text", LLSD(std::string("")));
-
- }
+ onClickRefresh(NULL);
}
-void LLPanelScriptLimitsRegionURLs::setRegionSummary(LLSD content)
-{
- if(content["summary"]["available"][0]["type"].asString() == std::string("urls"))
- {
- mParcelURLsMax = content["summary"]["available"][0]["amount"].asInteger();
- mGotParcelURLsMax = TRUE;
- }
- else if(content["summary"]["available"][1]["type"].asString() == std::string("urls"))
- {
- mParcelURLsMax = content["summary"]["available"][1]["amount"].asInteger();
- mGotParcelURLsMax = TRUE;
- }
- else
- {
- llinfos << "summary contains no url info" << llendl;
- return;
- }
-/*
- currently this is broken on the server, so we get this value from the details section
- and update via populateParcelMemoryText() when both sets of information have been returned
-
- when the sim is fixed this should be used instead:
- if(content["summary"]["used"][0]["type"].asString() == std::string("urls"))
- {
- mParcelURLsUsed = content["summary"]["used"][0]["amount"].asInteger();
- mGotParcelURLsUsed = TRUE;
- }
- else if(content["summary"]["used"][1]["type"].asString() == std::string("urls"))
- {
- mParcelURLsUsed = content["summary"]["used"][1]["amount"].asInteger();
- mGotParcelURLsUsed = TRUE;
- }
- else
- {
- //ERROR!!!
- return;
- }*/
-
- populateParcelURLsText();
-}
-
-BOOL LLPanelScriptLimitsRegionURLs::postBuild()
-{
- childSetAction("refresh_list_btn", onClickRefresh, this);
- childSetAction("highlight_btn", onClickHighlight, this);
- childSetAction("return_btn", onClickReturn, this);
-
- std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestWaiting");
- childSetValue("loading_text", LLSD(msg_waiting));
- return FALSE;
-}
-
-void LLPanelScriptLimitsRegionURLs::clearList()
-{
- LLCtrlListInterface *list = childGetListInterface("scripts_list");
-
- if (list)
- {
- list->operateOnAll(LLCtrlListInterface::OP_DELETE);
- }
-
- mGotParcelURLsUsed = FALSE;
- mGotParcelURLsMax = FALSE;
-
- LLStringUtil::format_map_t args_parcel_urls;
- std::string msg_empty_string("");
- childSetValue("urls_used", LLSD(msg_empty_string));
- childSetValue("parcels_listed", LLSD(msg_empty_string));
-
- mObjectListItems.clear();
-}
-
-// static
-void LLPanelScriptLimitsRegionURLs::onClickRefresh(void* userdata)
-{
- llinfos << "Refresh clicked" << llendl;
-
- LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
- if(instance)
- {
- LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel_memory = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
- // use the memory panel to re-request all the info
- panel_memory->clearList();
-
- LLPanelScriptLimitsRegionURLs* panel_urls = (LLPanelScriptLimitsRegionURLs*)tab->getChild<LLPanel>("script_limits_region_urls_panel");
- // but the urls panel to clear itself
- panel_urls->clearList();
-
- panel_memory->StartRequestChain();
- return;
- }
- else
- {
- llwarns << "could not find LLPanelScriptLimitsRegionMemory instance after refresh button clicked" << llendl;
- return;
- }
-}
// static
-void LLPanelScriptLimitsRegionURLs::onClickHighlight(void* userdata)
+void LLPanelScriptLimitsRegionMemory::onClickReturn(void* userdata)
{
-/* llinfos << "Highlight clicked" << llendl;
+ llinfos << "LLPanelRegionGeneralInfo::onClickReturn" << llendl;
LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
if(instance)
{
LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
- // use the beacon function from the memory panel
- panel->showBeacon();
+ if(tab)
+ {
+ LLPanelScriptLimitsRegionMemory* panel = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
+ if(panel)
+ {
+ panel->returnObjects();
+ }
+ }
return;
}
else
{
llwarns << "could not find LLPanelScriptLimitsRegionMemory instance after highlight button clicked" << llendl;
-// std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestError");
-// panel->childSetValue("loading_text", LLSD(msg_waiting));
- return;
- }*/
-}
-
-// static
-void LLPanelScriptLimitsRegionURLs::onClickReturn(void* userdata)
-{
-/* llinfos << "Return clicked" << llendl;
- LLFloaterScriptLimits* instance = LLFloaterReg::getTypedInstance<LLFloaterScriptLimits>("script_limits");
- if(instance)
- {
- LLTabContainer* tab = instance->getChild<LLTabContainer>("scriptlimits_panels");
- LLPanelScriptLimitsRegionMemory* panel = (LLPanelScriptLimitsRegionMemory*)tab->getChild<LLPanel>("script_limits_region_memory_panel");
- // use the return function from the memory panel
- panel->returnObjects();
return;
}
- else
- {
- llwarns << "could not find LLPanelScriptLimitsRegionMemory instance after highlight button clicked" << llendl;
-// std::string msg_waiting = LLTrans::getString("ScriptLimitsRequestError");
-// panel->childSetValue("loading_text", LLSD(msg_waiting));
- return;
- }*/
}
///----------------------------------------------------------------------------
@@ -1047,6 +1119,12 @@ BOOL LLPanelScriptLimitsAttachment::requestAttachmentDetails()
void LLPanelScriptLimitsAttachment::setAttachmentDetails(LLSD content)
{
LLScrollListCtrl *list = getChild<LLScrollListCtrl>("scripts_list");
+
+ if(!list)
+ {
+ return;
+ }
+
S32 number_attachments = content["attachments"].size();
for(int i = 0; i < number_attachments; i++)
@@ -1096,6 +1174,8 @@ void LLPanelScriptLimitsAttachment::setAttachmentDetails(LLSD content)
list->addElement(element);
}
}
+
+ setAttachmentSummary(content);
childSetValue("loading_text", LLSD(std::string("")));
}
@@ -1122,6 +1202,69 @@ void LLPanelScriptLimitsAttachment::clearList()
childSetValue("loading_text", LLSD(msg_waiting));
}
+void LLPanelScriptLimitsAttachment::setAttachmentSummary(LLSD content)
+{
+ if(content["summary"]["used"][0]["type"].asString() == std::string("memory"))
+ {
+ mAttachmentMemoryUsed = content["summary"]["used"][0]["amount"].asInteger() / SIZE_OF_ONE_KB;
+ mAttachmentMemoryMax = content["summary"]["available"][0]["amount"].asInteger() / SIZE_OF_ONE_KB;
+ mGotAttachmentMemoryUsed = TRUE;
+ }
+ else if(content["summary"]["used"][1]["type"].asString() == std::string("memory"))
+ {
+ mAttachmentMemoryUsed = content["summary"]["used"][1]["amount"].asInteger() / SIZE_OF_ONE_KB;
+ mAttachmentMemoryMax = content["summary"]["available"][1]["amount"].asInteger() / SIZE_OF_ONE_KB;
+ mGotAttachmentMemoryUsed = TRUE;
+ }
+ else
+ {
+ llinfos << "attachment details don't contain memory summary info" << llendl;
+ return;
+ }
+
+ if(content["summary"]["used"][0]["type"].asString() == std::string("urls"))
+ {
+ mAttachmentURLsUsed = content["summary"]["used"][0]["amount"].asInteger();
+ mAttachmentURLsMax = content["summary"]["available"][0]["amount"].asInteger();
+ mGotAttachmentURLsUsed = TRUE;
+ }
+ else if(content["summary"]["used"][1]["type"].asString() == std::string("urls"))
+ {
+ mAttachmentURLsUsed = content["summary"]["used"][1]["amount"].asInteger();
+ mAttachmentURLsMax = content["summary"]["available"][1]["amount"].asInteger();
+ mGotAttachmentURLsUsed = TRUE;
+ }
+ else
+ {
+ llinfos << "attachment details don't contain urls summary info" << llendl;
+ return;
+ }
+
+ if((mAttachmentMemoryUsed >= 0) && (mAttachmentMemoryMax >= 0))
+ {
+ S32 attachment_memory_available = mAttachmentMemoryMax - mAttachmentMemoryUsed;
+
+ LLStringUtil::format_map_t args_attachment_memory;
+ args_attachment_memory["[COUNT]"] = llformat ("%d", mAttachmentMemoryUsed);
+ args_attachment_memory["[MAX]"] = llformat ("%d", mAttachmentMemoryMax);
+ args_attachment_memory["[AVAILABLE]"] = llformat ("%d", attachment_memory_available);
+ std::string msg_attachment_memory = LLTrans::getString("ScriptLimitsMemoryUsed", args_attachment_memory);
+ childSetValue("memory_used", LLSD(msg_attachment_memory));
+ }
+
+ if((mAttachmentURLsUsed >= 0) && (mAttachmentURLsMax >= 0))
+ {
+ S32 attachment_urls_available = mAttachmentURLsMax - mAttachmentURLsUsed;
+
+ LLStringUtil::format_map_t args_attachment_urls;
+ args_attachment_urls["[COUNT]"] = llformat ("%d", mAttachmentURLsUsed);
+ args_attachment_urls["[MAX]"] = llformat ("%d", mAttachmentURLsMax);
+ args_attachment_urls["[AVAILABLE]"] = llformat ("%d", attachment_urls_available);
+ std::string msg_attachment_urls = LLTrans::getString("ScriptLimitsURLsUsed", args_attachment_urls);
+ childSetValue("urls_used", LLSD(msg_attachment_urls));
+ }
+}
+
// static
void LLPanelScriptLimitsAttachment::onClickRefresh(void* userdata)
{
diff --git a/indra/newview/llfloaterscriptlimits.h b/indra/newview/llfloaterscriptlimits.h
index e675d14515..4c1ecc1019 100644
--- a/indra/newview/llfloaterscriptlimits.h
+++ b/indra/newview/llfloaterscriptlimits.h
@@ -166,10 +166,10 @@ public:
BOOL StartRequestChain();
- void populateParcelMemoryText();
BOOL getLandScriptResources();
void clearList();
void showBeacon();
+ void returnObjectsFromParcel(S32 local_id);
void returnObjects();
private:
@@ -178,69 +178,30 @@ private:
const std::string& first_name,
const std::string& last_name);
+ LLSD mContent;
LLUUID mParcelId;
BOOL mGotParcelMemoryUsed;
+ BOOL mGotParcelMemoryUsedDetails;
BOOL mGotParcelMemoryMax;
S32 mParcelMemoryMax;
S32 mParcelMemoryUsed;
+ S32 mParcelMemoryUsedDetails;
- std::vector<LLSD> mObjectListItems;
-
-protected:
-
-// LLRemoteParcelInfoObserver interface:
-/*virtual*/ void processParcelInfo(const LLParcelData& parcel_data);
-/*virtual*/ void setParcelID(const LLUUID& parcel_id);
-/*virtual*/ void setErrorStatus(U32 status, const std::string& reason);
-
- static void onClickRefresh(void* userdata);
- static void onClickHighlight(void* userdata);
- static void onClickReturn(void* userdata);
-};
-
-/////////////////////////////////////////////////////////////////////////////
-// URLs panel
-/////////////////////////////////////////////////////////////////////////////
-
-class LLPanelScriptLimitsRegionURLs : public LLPanelScriptLimitsInfo
-{
-
-public:
- LLPanelScriptLimitsRegionURLs()
- : LLPanelScriptLimitsInfo(),
-
- mParcelId(LLUUID()),
- mGotParcelURLsUsed(FALSE),
- mGotParcelURLsMax(FALSE),
- mParcelURLsMax(0),
- mParcelURLsUsed(0)
- {
- };
-
- ~LLPanelScriptLimitsRegionURLs()
- {
- };
-
- // LLPanel
- virtual BOOL postBuild();
-
- void setRegionDetails(LLSD content);
- void setRegionSummary(LLSD content);
-
- void populateParcelURLsText();
- void clearList();
-
-private:
-
- LLUUID mParcelId;
BOOL mGotParcelURLsUsed;
+ BOOL mGotParcelURLsUsedDetails;
BOOL mGotParcelURLsMax;
S32 mParcelURLsMax;
S32 mParcelURLsUsed;
+ S32 mParcelURLsUsedDetails;
std::vector<LLSD> mObjectListItems;
protected:
+
+// LLRemoteParcelInfoObserver interface:
+/*virtual*/ void processParcelInfo(const LLParcelData& parcel_data);
+/*virtual*/ void setParcelID(const LLUUID& parcel_id);
+/*virtual*/ void setErrorStatus(U32 status, const std::string& reason);
static void onClickRefresh(void* userdata);
static void onClickHighlight(void* userdata);
@@ -266,11 +227,26 @@ public:
void setAttachmentDetails(LLSD content);
+ void setAttachmentSummary(LLSD content);
BOOL requestAttachmentDetails();
void clearList();
private:
+ BOOL mGotAttachmentMemoryUsed;
+ BOOL mGotAttachmentMemoryUsedDetails;
+ BOOL mGotAttachmentMemoryMax;
+ S32 mAttachmentMemoryMax;
+ S32 mAttachmentMemoryUsed;
+ S32 mAttachmentMemoryUsedDetails;
+
+ BOOL mGotAttachmentURLsUsed;
+ BOOL mGotAttachmentURLsUsedDetails;
+ BOOL mGotAttachmentURLsMax;
+ S32 mAttachmentURLsMax;
+ S32 mAttachmentURLsUsed;
+ S32 mAttachmentURLsUsedDetails;
+
protected:
static void onClickRefresh(void* userdata);
diff --git a/indra/newview/llfolderviewitem.cpp b/indra/newview/llfolderviewitem.cpp
index b05eb84e52..f154de39c9 100644
--- a/indra/newview/llfolderviewitem.cpp
+++ b/indra/newview/llfolderviewitem.cpp
@@ -2540,13 +2540,11 @@ bool LLInventorySort::operator()(const LLFolderViewItem* const& a, const LLFolde
{
static const LLUUID& favorites_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
- static const LLUUID& landmarks_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_LANDMARK);
LLUUID a_uuid = a->getParentFolder()->getListener()->getUUID();
LLUUID b_uuid = b->getParentFolder()->getListener()->getUUID();
- if ((a_uuid == favorites_folder_id && b_uuid == favorites_folder_id) ||
- (a_uuid == landmarks_folder_id && b_uuid == landmarks_folder_id))
+ if ((a_uuid == favorites_folder_id && b_uuid == favorites_folder_id))
{
// *TODO: mantipov: probably it is better to add an appropriate method to LLFolderViewItem
// or to LLInvFVBridge
diff --git a/indra/newview/llinspectremoteobject.cpp b/indra/newview/llinspectremoteobject.cpp
index 898f1cd9ac..66e4a1bf66 100644
--- a/indra/newview/llinspectremoteobject.cpp
+++ b/indra/newview/llinspectremoteobject.cpp
@@ -167,7 +167,8 @@ void LLInspectRemoteObject::nameCallback(const LLUUID& id, const std::string& fi
void LLInspectRemoteObject::update()
{
// show the object name as the inspector's title
- getChild<LLUICtrl>("object_name")->setValue(mName);
+ // (don't hyperlink URLs in object names)
+ getChild<LLUICtrl>("object_name")->setValue("<nolink>" + mName + "</nolink>");
// show the object's owner - click it to show profile
std::string owner = mOwner;
@@ -192,7 +193,7 @@ void LLInspectRemoteObject::update()
std::string url;
if (! mSLurl.empty())
{
- std::string url = "secondlife:///app/teleport/" + mSLurl;
+ url = "secondlife:///app/teleport/" + mSLurl;
}
getChild<LLUICtrl>("object_slurl")->setValue(url);
diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp
index 961f7adc0a..7ec976604a 100644
--- a/indra/newview/llinventorymodel.cpp
+++ b/indra/newview/llinventorymodel.cpp
@@ -218,7 +218,10 @@ BOOL LLInventoryModel::isObjectDescendentOf(const LLUUID& obj_id,
const LLViewerInventoryCategory *LLInventoryModel::getFirstNondefaultParent(const LLUUID& obj_id) const
{
const LLInventoryObject* obj = getObject(obj_id);
- const LLUUID& parent_id = obj->getParentUUID();
+
+ // Search up the parent chain until we get to root or an acceptable folder.
+ // This assumes there are no cycles in the tree else we'll get a hang.
+ LLUUID parent_id = obj->getParentUUID();
while (!parent_id.isNull())
{
const LLViewerInventoryCategory *cat = getCategory(parent_id);
@@ -230,6 +233,7 @@ const LLViewerInventoryCategory *LLInventoryModel::getFirstNondefaultParent(cons
{
return cat;
}
+ parent_id = cat->getParentUUID();
}
return NULL;
}
diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp
index fccf71f3cb..7bcbe334ff 100644
--- a/indra/newview/llpreviewscript.cpp
+++ b/indra/newview/llpreviewscript.cpp
@@ -1904,7 +1904,7 @@ void LLLiveLSLEditor::uploadAssetViaCaps(const std::string& url,
const LLUUID& item_id,
BOOL is_running)
{
- llinfos << "Update Task Inventory via capability" << llendl;
+ llinfos << "Update Task Inventory via capability " << url << llendl;
LLSD body;
body["task_id"] = task_id;
body["item_id"] = item_id;
diff --git a/indra/newview/llsidepanelinventory.cpp b/indra/newview/llsidepanelinventory.cpp
index 7b923f4b0b..3fd5309947 100644
--- a/indra/newview/llsidepanelinventory.cpp
+++ b/indra/newview/llsidepanelinventory.cpp
@@ -176,7 +176,7 @@ void LLSidepanelInventory::onPlayButtonClicked()
performActionOnSelection("play");
break;
default:
- performActionOnSelection("activate");
+ performActionOnSelection("open");
break;
}
}
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp
index ce5da8bb24..522adc05ce 100644
--- a/indra/newview/llstartup.cpp
+++ b/indra/newview/llstartup.cpp
@@ -906,7 +906,7 @@ bool idle_startup()
LLFile::mkdir(gDirUtilp->getPerAccountChatLogsDir());
- //good as place as any to create user windlight directories
+ //good a place as any to create user windlight directories
std::string user_windlight_path_name(gDirUtilp->getExpandedFilename( LL_PATH_USER_SETTINGS , "windlight", ""));
LLFile::mkdir(user_windlight_path_name.c_str());
diff --git a/indra/newview/lltoolplacer.h b/indra/newview/lltoolplacer.h
index b7422380d4..df07f1854c 100644
--- a/indra/newview/lltoolplacer.h
+++ b/indra/newview/lltoolplacer.h
@@ -33,7 +33,6 @@
#ifndef LL_TOOLPLACER_H
#define LL_TOOLPLACER_H
-#include "llprimitive.h"
#include "llpanel.h"
#include "lltool.h"
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 3bf0fb6f71..e525561b7d 100644
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -2208,7 +2208,10 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
LLNearbyChat* nearby_chat = LLFloaterReg::getTypedInstance<LLNearbyChat>("nearby_chat", LLSD());
if(nearby_chat)
{
- nearby_chat->addMessage(chat);
+ LLSD args;
+ args["owner_id"] = from_id;
+ args["slurl"] = location;
+ nearby_chat->addMessage(chat, true, args);
}
diff --git a/indra/newview/llvoiceclient.cpp b/indra/newview/llvoiceclient.cpp
index 431e9625c4..b6e7e73b9d 100644
--- a/indra/newview/llvoiceclient.cpp
+++ b/indra/newview/llvoiceclient.cpp
@@ -1258,7 +1258,6 @@ LLVoiceClient::LLVoiceClient() :
mEarLocation(0),
mSpeakerVolumeDirty(true),
mSpeakerMuteDirty(true),
- mSpeakerVolume(0),
mMicVolume(0),
mMicVolumeDirty(true),
@@ -1271,6 +1270,8 @@ LLVoiceClient::LLVoiceClient() :
mAPIVersion = LLTrans::getString("NotConnected");
+ mSpeakerVolume = scale_speaker_volume(0);
+
#if LL_DARWIN || LL_LINUX || LL_SOLARIS
// HACK: THIS DOES NOT BELONG HERE
// When the vivox daemon dies, the next write attempt on our socket generates a SIGPIPE, which kills us.
@@ -3525,7 +3526,7 @@ void LLVoiceClient::buildLocalAudioUpdates(std::ostringstream &stream)
if(mSpeakerMuteDirty)
{
- const char *muteval = ((mSpeakerVolume == 0)?"true":"false");
+ const char *muteval = ((mSpeakerVolume <= scale_speaker_volume(0))?"true":"false");
mSpeakerMuteDirty = false;
@@ -6064,7 +6065,8 @@ void LLVoiceClient::setVoiceVolume(F32 volume)
if(scaled_volume != mSpeakerVolume)
{
- if((scaled_volume == 0) || (mSpeakerVolume == 0))
+ int min_volume = scale_speaker_volume(0);
+ if((scaled_volume == min_volume) || (mSpeakerVolume == min_volume))
{
mSpeakerMuteDirty = true;
}
diff --git a/indra/newview/skins/default/textures/build/Object_Cone_Selected.png b/indra/newview/skins/default/textures/build/Object_Cone_Selected.png
new file mode 100644
index 0000000000..d50dc69ffe
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Cone_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Cube_Selected.png b/indra/newview/skins/default/textures/build/Object_Cube_Selected.png
new file mode 100644
index 0000000000..3d6964530d
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Cube_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Cylinder_Selected.png b/indra/newview/skins/default/textures/build/Object_Cylinder_Selected.png
new file mode 100644
index 0000000000..3ed0389961
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Cylinder_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Grass_Selected.png b/indra/newview/skins/default/textures/build/Object_Grass_Selected.png
new file mode 100644
index 0000000000..3ebd5ea7a1
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Grass_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Hemi_Cone_Selected.png b/indra/newview/skins/default/textures/build/Object_Hemi_Cone_Selected.png
new file mode 100644
index 0000000000..3bdc4d1fd5
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Hemi_Cone_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Hemi_Cylinder_Selected.png b/indra/newview/skins/default/textures/build/Object_Hemi_Cylinder_Selected.png
new file mode 100644
index 0000000000..0912442e29
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Hemi_Cylinder_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Hemi_Sphere_Selected.png b/indra/newview/skins/default/textures/build/Object_Hemi_Sphere_Selected.png
new file mode 100644
index 0000000000..33db4a2de8
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Hemi_Sphere_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Prism_Selected.png b/indra/newview/skins/default/textures/build/Object_Prism_Selected.png
new file mode 100644
index 0000000000..9e80fe2b84
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Prism_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Pyramid_Selected.png b/indra/newview/skins/default/textures/build/Object_Pyramid_Selected.png
new file mode 100644
index 0000000000..d36bfa55d4
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Pyramid_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Ring_Selected.png b/indra/newview/skins/default/textures/build/Object_Ring_Selected.png
new file mode 100644
index 0000000000..962f6efb93
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Ring_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Sphere_Selected.png b/indra/newview/skins/default/textures/build/Object_Sphere_Selected.png
new file mode 100644
index 0000000000..715d597144
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Sphere_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Tetrahedron_Selected.png b/indra/newview/skins/default/textures/build/Object_Tetrahedron_Selected.png
new file mode 100644
index 0000000000..b2ea680f23
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Tetrahedron_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Torus_Selected.png b/indra/newview/skins/default/textures/build/Object_Torus_Selected.png
new file mode 100644
index 0000000000..1fc22686eb
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Torus_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Tree_Selected.png b/indra/newview/skins/default/textures/build/Object_Tree_Selected.png
new file mode 100644
index 0000000000..5bd87f8a2f
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Tree_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/build/Object_Tube_Selected.png b/indra/newview/skins/default/textures/build/Object_Tube_Selected.png
new file mode 100644
index 0000000000..a4c3f39e14
--- /dev/null
+++ b/indra/newview/skins/default/textures/build/Object_Tube_Selected.png
Binary files differ
diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml
index 60c1470b89..ea66897b35 100644
--- a/indra/newview/skins/default/textures/textures.xml
+++ b/indra/newview/skins/default/textures/textures.xml
@@ -321,20 +321,35 @@ with the same filename but different name
<texture name="NoEntryPassLines" file_name="world/NoEntryPassLines.png" use_mips="true" preload="false" />
<texture name="Object_Cone" file_name="build/Object_Cone.png" preload="false" />
+ <texture name="Object_Cone_Selected" file_name="build/Object_Cone_Selected.png" preload="false" />
<texture name="Object_Cube" file_name="build/Object_Cube.png" preload="false" />
+ <texture name="Object_Cube_Selected" file_name="build/Object_Cube_Selected.png" preload="false" />
<texture name="Object_Cylinder" file_name="build/Object_Cylinder.png" preload="false" />
+ <texture name="Object_Cylinder_Selected" file_name="build/Object_Cylinder_Selected.png" preload="false" />
<texture name="Object_Grass" file_name="build/Object_Grass.png" preload="false" />
+ <texture name="Object_Grass_Selected" file_name="build/Object_Grass_Selected.png" preload="false" />
<texture name="Object_Hemi_Cone" file_name="build/Object_Hemi_Cone.png" preload="false" />
+ <texture name="Object_Hemi_Cone_Selected" file_name="build/Object_Hemi_Cone_Selected.png" preload="false" />
<texture name="Object_Hemi_Cylinder" file_name="build/Object_Hemi_Cylinder.png" preload="false" />
+ <texture name="Object_Hemi_Cylinder_Selected" file_name="build/Object_Hemi_Cylinder_Selected.png" preload="false" />
<texture name="Object_Hemi_Sphere" file_name="build/Object_Hemi_Sphere.png" preload="false" />
+ <texture name="Object_Hemi_Sphere_Selected" file_name="build/Object_Hemi_Sphere_Selected.png" preload="false" />
<texture name="Object_Prism" file_name="build/Object_Prism.png" preload="false" />
+ <texture name="Object_Prism_Selected" file_name="build/Object_Prism_Selected.png" preload="false" />
<texture name="Object_Pyramid" file_name="build/Object_Pyramid.png" preload="false" />
+ <texture name="Object_Pyramid_Selected" file_name="build/Object_Pyramid_Selected.png" preload="false" />
<texture name="Object_Ring" file_name="build/Object_Ring.png" preload="false" />
+ <texture name="Object_Ring_Selected" file_name="build/Object_Ring_Selected.png" preload="false" />
<texture name="Object_Sphere" file_name="build/Object_Sphere.png" preload="false" />
+ <texture name="Object_Sphere_Selected" file_name="build/Object_Sphere_Selected.png" preload="false" />
<texture name="Object_Tetrahedron" file_name="build/Object_Tetrahedron.png" preload="false" />
+ <texture name="Object_Tetrahedron_Selected" file_name="build/Object_Tetrahedron_Selected.png" preload="false" />
<texture name="Object_Torus" file_name="build/Object_Torus.png" preload="false" />
+ <texture name="Object_Torus_Selected" file_name="build/Object_Torus_Selected.png" preload="false" />
<texture name="Object_Tree" file_name="build/Object_Tree.png" preload="false" />
+ <texture name="Object_Tree_Selected" file_name="build/Object_Tree_Selected.png" preload="false" />
<texture name="Object_Tube" file_name="build/Object_Tube.png" preload="false" />
+ <texture name="Object_Tube_Selected" file_name="build/Object_Tube_Selected.png" preload="false" />
<texture name="OptionsMenu_Disabled" file_name="icons/OptionsMenu_Disabled.png" preload="false" />
<texture name="OptionsMenu_Off" file_name="icons/OptionsMenu_Off.png" preload="false" />
@@ -585,10 +600,15 @@ with the same filename but different name
scale.left="4" scale.top="28" scale.right="60" scale.bottom="4" />
<texture name="Tool_Create" file_name="build/Tool_Create.png" preload="false" />
+ <texture name="Tool_Create_Selected" file_name="build/Tool_Create_Selected.png" preload="false" />
<texture name="Tool_Dozer" file_name="build/Tool_Dozer.png" preload="false" />
+ <texture name="Tool_Dozer_Selected" file_name="build/Tool_Dozer_Selected.png" preload="false" />
<texture name="Tool_Face" file_name="build/Tool_Face.png" preload="false" />
+ <texture name="Tool_Face_Selected" file_name="build/Tool_Face_Selected.png" preload="false" />
<texture name="Tool_Grab" file_name="build/Tool_Grab.png" preload="false" />
+ <texture name="Tool_Grab_Selected" file_name="build/Tool_Grab_Selected.png" preload="false" />
<texture name="Tool_Zoom" file_name="build/Tool_Zoom.png" preload="false" />
+ <texture name="Tool_Zoom_Selected" file_name="build/Tool_Zoom_Selected.png" preload="false" />
<texture name="Toolbar_Divider" file_name="containers/Toolbar_Divider.png" preload="false" />
<texture name="Toolbar_Left_Off" file_name="containers/Toolbar_Left_Off.png" preload="false" scale.left="5" scale.bottom="4" scale.top="24" scale.right="30" />
diff --git a/indra/newview/skins/default/xui/en/floater_aaa.xml b/indra/newview/skins/default/xui/en/floater_aaa.xml
index 7236351f2e..b9bc45a10b 100644
--- a/indra/newview/skins/default/xui/en/floater_aaa.xml
+++ b/indra/newview/skins/default/xui/en/floater_aaa.xml
@@ -19,7 +19,7 @@
width="320">
<string name="nudge_parabuild" translate="false">Nudge 1</string>
<string name="test_the_vlt">This string CHANGE2 is extracted.</string>
- <string name="testing_eli">Just a test. change here. more change.</string>
+ <string name="testing_eli">Just a test. changes.</string>
<chat_history
allow_html="true"
bg_readonly_color="ChatHistoryBgColor"
diff --git a/indra/newview/skins/default/xui/en/floater_animation_preview.xml b/indra/newview/skins/default/xui/en/floater_animation_preview.xml
index 4f4288b654..1ffedde29b 100644
--- a/indra/newview/skins/default/xui/en/floater_animation_preview.xml
+++ b/indra/newview/skins/default/xui/en/floater_animation_preview.xml
@@ -147,7 +147,11 @@ Maximum animation length is [MAX_LENGTH] seconds.
name="E_ST_NO_XLT_EMOTE">
Cannot read emote name.
</floater.string>
- <text
+ <floater.string
+ name="E_ST_BAD_ROOT">
+ Incorrect root joint name, use "hip".
+ </floater.string>
+ <text
type="string"
length="1"
bottom="42"
diff --git a/indra/newview/skins/default/xui/en/floater_script_limits.xml b/indra/newview/skins/default/xui/en/floater_script_limits.xml
index 98c44ad1b3..6b36cdfcc5 100644
--- a/indra/newview/skins/default/xui/en/floater_script_limits.xml
+++ b/indra/newview/skins/default/xui/en/floater_script_limits.xml
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater
legacy_header_height="18"
+ can_resize="true"
height="570"
help_topic="scriptlimits"
layout="topleft"
diff --git a/indra/newview/skins/default/xui/en/floater_tools.xml b/indra/newview/skins/default/xui/en/floater_tools.xml
index f1aa5c27c1..5630dfbe8f 100644
--- a/indra/newview/skins/default/xui/en/floater_tools.xml
+++ b/indra/newview/skins/default/xui/en/floater_tools.xml
@@ -70,7 +70,7 @@
height="20"
image_disabled="Tool_Zoom"
image_disabled_selected="Tool_Zoom"
- image_selected="Tool_Zoom"
+ image_selected="Tool_Zoom_Selected"
image_unselected="Tool_Zoom"
layout="topleft"
left="10"
@@ -86,7 +86,7 @@
height="20"
image_disabled="Tool_Grab"
image_disabled_selected="Tool_Grab"
- image_selected="Tool_Grab"
+ image_selected="Tool_Grab_Selected"
image_unselected="Tool_Grab"
layout="topleft"
left_pad="20"
@@ -102,7 +102,7 @@
height="20"
image_disabled="Tool_Face"
image_disabled_selected="Tool_Face"
- image_selected="Tool_Face"
+ image_selected="Tool_Face_Selected"
image_unselected="Tool_Face"
layout="topleft"
left_pad="20"
@@ -118,7 +118,7 @@
height="20"
image_disabled="Tool_Create"
image_disabled_selected="Tool_Create"
- image_selected="Tool_Create"
+ image_selected="Tool_Create_Selected"
image_unselected="Tool_Create"
layout="topleft"
left_pad="20"
@@ -134,7 +134,7 @@
height="20"
image_disabled="Tool_Dozer"
image_disabled_selected="Tool_Dozer"
- image_selected="Tool_Dozer"
+ image_selected="Tool_Dozer_Selected"
image_unselected="Tool_Dozer"
layout="topleft"
left_pad="20"
@@ -344,7 +344,7 @@
height="20"
image_disabled="Object_Cube"
image_disabled_selected="Object_Cube"
- image_selected="Object_Cube"
+ image_selected="Object_Cube_Selected"
image_unselected="Object_Cube"
layout="topleft"
left="4"
@@ -357,7 +357,7 @@
height="20"
image_disabled="Object_Prism"
image_disabled_selected="Object_Prism"
- image_selected="Object_Prism"
+ image_selected="Object_Prism_Selected"
image_unselected="Object_Prism"
layout="topleft"
left_delta="26"
@@ -370,7 +370,7 @@
height="20"
image_disabled="Object_Pyramid"
image_disabled_selected="Object_Pyramid"
- image_selected="Object_Pyramid"
+ image_selected="Object_Pyramid_Selected"
image_unselected="Object_Pyramid"
layout="topleft"
left_delta="26"
@@ -383,7 +383,7 @@
height="20"
image_disabled="Object_Tetrahedron"
image_disabled_selected="Object_Tetrahedron"
- image_selected="Object_Tetrahedron"
+ image_selected="Object_Tetrahedron_Selected"
image_unselected="Object_Tetrahedron"
layout="topleft"
left_delta="26"
@@ -396,7 +396,7 @@
height="20"
image_disabled="Object_Cylinder"
image_disabled_selected="Object_Cylinder"
- image_selected="Object_Cylinder"
+ image_selected="Object_Cylinder_Selected"
image_unselected="Object_Cylinder"
layout="topleft"
left_delta="26"
@@ -409,7 +409,7 @@
height="20"
image_disabled="Object_Hemi_Cylinder"
image_disabled_selected="Object_Hemi_Cylinder"
- image_selected="Object_Hemi_Cylinder"
+ image_selected="Object_Hemi_Cylinder_Selected"
image_unselected="Object_Hemi_Cylinder"
layout="topleft"
left_delta="26"
@@ -422,7 +422,7 @@
height="20"
image_disabled="Object_Cone"
image_disabled_selected="Object_Cone"
- image_selected="Object_Cone"
+ image_selected="Object_Cone_Selected"
image_unselected="Object_Cone"
layout="topleft"
left_delta="26"
@@ -435,7 +435,7 @@
height="20"
image_disabled="Object_Hemi_Cone"
image_disabled_selected="Object_Hemi_Cone"
- image_selected="Object_Hemi_Cone"
+ image_selected="Object_Hemi_Cone_Selected"
image_unselected="Object_Hemi_Cone"
layout="topleft"
left_delta="26"
@@ -448,7 +448,7 @@
height="20"
image_disabled="Object_Sphere"
image_disabled_selected="Object_Sphere"
- image_selected="Object_Sphere"
+ image_selected="Object_Sphere_Selected"
image_unselected="Object_Sphere"
layout="topleft"
left_delta="26"
@@ -461,7 +461,7 @@
height="20"
image_disabled="Object_Hemi_Sphere"
image_disabled_selected="Object_Hemi_Sphere"
- image_selected="Object_Hemi_Sphere"
+ image_selected="Object_Hemi_Sphere_Selected"
image_unselected="Object_Hemi_Sphere"
layout="topleft"
left_delta="26"
@@ -474,7 +474,7 @@
height="20"
image_disabled="Object_Torus"
image_disabled_selected="Object_Torus"
- image_selected="Object_Torus"
+ image_selected="Object_Torus_Selected"
image_unselected="Object_Torus"
layout="topleft"
left="4"
@@ -487,7 +487,7 @@
height="20"
image_disabled="Object_Tube"
image_disabled_selected="Object_Tube"
- image_selected="Object_Tube"
+ image_selected="Object_Tube_Selected"
image_unselected="Object_Tube"
layout="topleft"
left_delta="26"
@@ -500,7 +500,7 @@
height="20"
image_disabled="Object_Ring"
image_disabled_selected="Object_Ring"
- image_selected="Object_Ring"
+ image_selected="Object_Ring_Selected"
image_unselected="Object_Ring"
layout="topleft"
left_delta="26"
@@ -513,7 +513,7 @@
height="20"
image_disabled="Object_Tree"
image_disabled_selected="Object_Tree"
- image_selected="Object_Tree"
+ image_selected="Object_Tree_Selected"
image_unselected="Object_Tree"
layout="topleft"
left_delta="26"
@@ -526,8 +526,9 @@
height="20"
image_disabled="Object_Grass"
image_disabled_selected="Object_Grass"
- image_selected="Object_Grass"
+ image_selected="Object_Grass_Selected"
image_unselected="Object_Grass"
+ image_overlay_color="Red"
layout="topleft"
left_delta="26"
name="ToolGrass"
diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
index 9279d1e686..c971914a2d 100644
--- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
@@ -93,6 +93,7 @@
height="23"
label="Teleport"
name="teleport_btn"
+ tool_tip = "Offer to teleport this person"
width="100" />
</layout_panel>
<layout_panel
diff --git a/indra/newview/skins/default/xui/en/panel_places.xml b/indra/newview/skins/default/xui/en/panel_places.xml
index 9bfd8b91d8..c4e4b9aa9b 100644
--- a/indra/newview/skins/default/xui/en/panel_places.xml
+++ b/indra/newview/skins/default/xui/en/panel_places.xml
@@ -17,12 +17,13 @@ background_visible="true"
name="teleport_history_tab_title"
value="TELEPORT HISTORY" />
<filter_editor
+ text_pad_left="14"
follows="left|top|right"
- font="SansSerif"
+ font="SansSerifSmall"
height="23"
layout="topleft"
left="15"
- label="Filter Places"
+ label="Filter My Places"
max_length="300"
name="Filter"
top="3"
diff --git a/indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml b/indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml
index d98f690339..629d8567d1 100644
--- a/indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml
+++ b/indra/newview/skins/default/xui/en/panel_script_limits_my_avatar.xml
@@ -9,7 +9,44 @@
name="script_limits_my_avatar_panel"
top="0"
width="480">
- <text
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="16"
+ layout="topleft"
+ left="10"
+ name="script_memory"
+ top_pad="24"
+ text_color="White"
+ width="480">
+ Avatar Script Usage
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="16"
+ layout="topleft"
+ left="30"
+ name="memory_used"
+ top_delta="18"
+ width="480">
+
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="16"
+ layout="topleft"
+ left="30"
+ name="urls_used"
+ top_delta="18"
+ width="480">
+
+ </text>
+ <text
type="string"
length="1"
follows="left|top"
@@ -17,7 +54,7 @@
layout="topleft"
left="10"
name="loading_text"
- top="10"
+ top="80"
text_color="EmphasisColor"
width="480">
Loading...
@@ -25,12 +62,12 @@
<scroll_list
draw_heading="true"
follows="all"
- height="500"
+ height="415"
layout="topleft"
left_delta="0"
multi_select="true"
name="scripts_list"
- top_delta="17"
+ top="100"
width="460">
<scroll_list.columns
label="Size (kb)"
diff --git a/indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml b/indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml
index 0fa3c1cf2e..9dff00fa0b 100644
--- a/indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml
+++ b/indra/newview/skins/default/xui/en/panel_script_limits_region_memory.xml
@@ -33,7 +33,7 @@
top_delta="18"
visible="true"
width="480">
- Parcels Owned:
+
</text>
<text
type="string"
@@ -45,7 +45,19 @@
name="memory_used"
top_delta="18"
width="480">
- Memory used:
+ </text>
+
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="16"
+ layout="topleft"
+ left="30"
+ name="urls_used"
+ top_delta="18"
+ width="480">
+
</text>
<text
type="string"
@@ -55,7 +67,7 @@
layout="topleft"
left="10"
name="loading_text"
- top_delta="32"
+ top_delta="12"
text_color="EmphasisColor"
width="480">
Loading...
@@ -73,7 +85,11 @@
<scroll_list.columns
label="Size (kb)"
name="size"
- width="70" />
+ width="72" />
+ <scroll_list.columns
+ label="URLs"
+ name="urls"
+ width="48" />
<scroll_list.columns
label="Object Name"
name="name"
@@ -83,11 +99,13 @@
name="owner"
width="100" />
<scroll_list.columns
- label="Parcel / Location"
- name="location"
+ label="Parcel"
+ name="parcel"
width="130" />
-<!-- <scroll_list.commit_callback
- function="TopObjects.CommitObjectsList" />-->
+ <scroll_list.columns
+ label="Location"
+ name="location"
+ width="80" />
</scroll_list>
<button
follows="bottom|left"
@@ -102,8 +120,8 @@
<button
follows="bottom|right"
height="19"
- visible="false"
label="Highlight"
+ visible="false"
layout="bottomright"
left="370"
name="highlight_btn"
@@ -112,8 +130,8 @@
<button
follows="bottom|right"
height="19"
- visible="false"
label="Return"
+ visible="false"
layout="bottomright"
name="return_btn"
top="34"
diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml
index b378944e48..b4a12cfb32 100644
--- a/indra/newview/skins/default/xui/en/strings.xml
+++ b/indra/newview/skins/default/xui/en/strings.xml
@@ -2051,6 +2051,7 @@ this texture in your inventory
<string name="ScriptLimitsURLsUsed">URLs used: [COUNT] out of [MAX]; [AVAILABLE] available</string>
<string name="ScriptLimitsURLsUsedSimple">URLs used: [COUNT]</string>
<string name="ScriptLimitsRequestError">Error requesting information</string>
+ <string name="ScriptLimitsRequestNoParcelSelected">No Parcel Selected</string>
<string name="ScriptLimitsRequestWrongRegion">Error: script information is only available in your current region</string>
<string name="ScriptLimitsRequestWaiting">Retrieving information...</string>
<string name="ScriptLimitsRequestDontOwnParcel">You do not have permission to examine this parcel</string>
diff --git a/indra/newview/skins/default/xui/en/widgets/location_input.xml b/indra/newview/skins/default/xui/en/widgets/location_input.xml
index 70a58b8e03..2163660206 100644
--- a/indra/newview/skins/default/xui/en/widgets/location_input.xml
+++ b/indra/newview/skins/default/xui/en/widgets/location_input.xml
@@ -96,7 +96,7 @@
name="damage_icon"
width="14"
height="13"
- top="21"
+ top="19"
left="2"
follows="right|top"
image_name="Parcel_Damage_Dark"
@@ -106,7 +106,7 @@
name="damage_text"
width="35"
height="18"
- top="16"
+ top="17"
follows="right|top"
halign="right"
font="SansSerifSmall"