diff options
author | James Cook <james@lindenlab.com> | 2009-11-25 12:31:24 -0800 |
---|---|---|
committer | James Cook <james@lindenlab.com> | 2009-11-25 12:31:24 -0800 |
commit | 957055396d2ffa3a76b09c60cb9c3e1f73870cbf (patch) | |
tree | 632ecbdc0c21b0e14eb72f74faa8c04765f54489 /indra/llui | |
parent | ef46d4077ca4aad322aabfe545885be136577c8a (diff) | |
parent | 59eb8a43a467ecaa5a8c2b58bf1abfb8350c0202 (diff) |
merge in changes from viewer-2-0, manually fixed conflict in llviewermessages.cpp
Diffstat (limited to 'indra/llui')
-rw-r--r-- | indra/llui/llconsole.cpp | 5 | ||||
-rw-r--r-- | indra/llui/llflatlistview.h | 2 | ||||
-rw-r--r-- | indra/llui/llfloater.h | 1 | ||||
-rw-r--r-- | indra/llui/lltextbase.cpp | 6 | ||||
-rw-r--r-- | indra/llui/llurlentry.cpp | 33 | ||||
-rw-r--r-- | indra/llui/llurlentry.h | 13 | ||||
-rw-r--r-- | indra/llui/llurlregistry.cpp | 1 |
7 files changed, 52 insertions, 9 deletions
diff --git a/indra/llui/llconsole.cpp b/indra/llui/llconsole.cpp index 48c76cf105..fa0abd55d0 100644 --- a/indra/llui/llconsole.cpp +++ b/indra/llui/llconsole.cpp @@ -392,9 +392,4 @@ void LLConsole::addLine(const LLWString& wline, F32 size, const LLColor4 &color) Paragraph paragraph(wline, color, mTimer.getElapsedTimeF32(), mFont, (F32)getRect().getWidth() ); mParagraphs.push_back ( paragraph ); - -#if LL_WINDOWS && LL_LCD_COMPILE - // add to LCD screen - AddNewDebugConsoleToLCD(wline); -#endif } diff --git a/indra/llui/llflatlistview.h b/indra/llui/llflatlistview.h index eac947a0d7..3867e910c0 100644 --- a/indra/llui/llflatlistview.h +++ b/indra/llui/llflatlistview.h @@ -50,7 +50,7 @@ class LLTextBox; * is ignored. The option "keep_one_selected" forces at least one item to be selected at any time (only for mouse events on items) * since any item of the list was selected. * - * Examples of using this control are presented in Picks panel (Me Profile and Profile View), where this control is used to + * Examples of using this control are presented in Picks panel (My Profile and Profile View), where this control is used to * manage the list of pick items. * * ASSUMPTIONS AND STUFF diff --git a/indra/llui/llfloater.h b/indra/llui/llfloater.h index 42d3240c0a..d7ec0aac00 100644 --- a/indra/llui/llfloater.h +++ b/indra/llui/llfloater.h @@ -197,6 +197,7 @@ public: /// The static isShown() can accept a NULL pointer (which of course /// returns false). When non-NULL, it calls the non-static isShown(). static bool isShown(const LLFloater* floater); + BOOL isFirstLook() { return mFirstLook; } // EXT-2653: This function is necessary to prevent overlapping for secondary showed toasts BOOL isFrontmost(); BOOL isDependent() { return !mDependeeHandle.isDead(); } void setCanMinimize(BOOL can_minimize); diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp index 3619b36c0d..7bf10d774c 100644 --- a/indra/llui/lltextbase.cpp +++ b/indra/llui/lltextbase.cpp @@ -2065,16 +2065,16 @@ void LLTextBase::updateRects() mContentsRect.unionWith(line_iter->mRect); } - mContentsRect.mLeft = 0; + S32 delta_pos_x = -mContentsRect.mLeft; mContentsRect.mTop += mVPad; S32 delta_pos = -mContentsRect.mBottom; // move line segments to fit new document rect for (line_list_t::iterator it = mLineInfoList.begin(); it != mLineInfoList.end(); ++it) { - it->mRect.translate(0, delta_pos); + it->mRect.translate(delta_pos_x, delta_pos); } - mContentsRect.translate(0, delta_pos); + mContentsRect.translate(delta_pos_x, delta_pos); } // update document container dimensions according to text contents diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp index 219fae84be..b51709e208 100644 --- a/indra/llui/llurlentry.cpp +++ b/indra/llui/llurlentry.cpp @@ -34,6 +34,7 @@ #include "linden_common.h" #include "llurlentry.h" #include "lluri.h" + #include "llcachename.h" #include "lltrans.h" #include "lluicolortable.h" @@ -383,6 +384,38 @@ std::string LLUrlEntryGroup::getLabel(const std::string &url, const LLUrlLabelCa } } +// +// LLUrlEntryInventory Describes a Second Life inventory Url, e.g., +// secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/select +// +LLUrlEntryInventory::LLUrlEntryInventory() +{ + mPattern = boost::regex("secondlife:///app/inventory/[\\da-f-]+/\\w+", + boost::regex::perl|boost::regex::icase); + mMenuName = "menu_url_inventory.xml"; +} + +std::string LLUrlEntryInventory::getLabel(const std::string &url, const LLUrlLabelCallback &cb) +{ + return unescapeUrl(url); + // TODO: Figure out if we can somehow access the inventory from here to get the actual item name + /* + std::string inventory_id_string = getIDStringFromUrl(url); + if (inventory_id_string.empty()) + { + // something went wrong, give raw url + return unescapeUrl(url); + } + LLUUID inventory_id(inventory_id_string); + LLInventoryItem* item = gInventory.getItem(inventory_id); + if(!item) + { + return unescapeUrl(url); + } + return item->getName(); */ +} + + /// /// LLUrlEntryParcel Describes a Second Life parcel Url, e.g., /// secondlife:///app/parcel/0000060e-4b39-e00b-d0c3-d98b1934e3a8/about diff --git a/indra/llui/llurlentry.h b/indra/llui/llurlentry.h index 7970b48eb5..b3fb333fdd 100644 --- a/indra/llui/llurlentry.h +++ b/indra/llui/llurlentry.h @@ -174,6 +174,19 @@ private: }; /// +/// LLUrlEntryInventory Describes a Second Life inventory Url, e.g., +/// secondlife:///app/inventory/0e346d8b-4433-4d66-a6b0-fd37083abc4c/select +/// +class LLUrlEntryInventory : public LLUrlEntryBase +{ +public: + LLUrlEntryInventory(); + /*virtual*/ std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb); +private: +}; + + +/// /// LLUrlEntryParcel Describes a Second Life parcel Url, e.g., /// secondlife:///app/parcel/0000060e-4b39-e00b-d0c3-d98b1934e3a8/about /// diff --git a/indra/llui/llurlregistry.cpp b/indra/llui/llurlregistry.cpp index a6922b019b..b2f084e5ac 100644 --- a/indra/llui/llurlregistry.cpp +++ b/indra/llui/llurlregistry.cpp @@ -55,6 +55,7 @@ LLUrlRegistry::LLUrlRegistry() registerUrl(new LLUrlEntryPlace()); registerUrl(new LLUrlEntrySL()); registerUrl(new LLUrlEntrySLLabel()); + registerUrl(new LLUrlEntryInventory()); } LLUrlRegistry::~LLUrlRegistry() |