diff options
Diffstat (limited to 'indra/llui/llflatlistview.h')
-rw-r--r-- | indra/llui/llflatlistview.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/indra/llui/llflatlistview.h b/indra/llui/llflatlistview.h index ba824ff2df..5999e79f61 100644 --- a/indra/llui/llflatlistview.h +++ b/indra/llui/llflatlistview.h @@ -124,6 +124,8 @@ public: /** Returns full rect of child panel */ const LLRect& getItemsRect() const; + LLRect getRequiredRect() { return getItemsRect(); } + /** Returns distance between items */ const S32 getItemsPad() { return mItemPad; } @@ -131,7 +133,7 @@ public: * Adds and item and LLSD value associated with it to the list at specified position * @return true if the item was added, false otherwise */ - virtual bool addItem(LLPanel * item, const LLSD& value = LLUUID::null, EAddPosition pos = ADD_BOTTOM); + virtual bool addItem(LLPanel * item, const LLSD& value = LLUUID::null, EAddPosition pos = ADD_BOTTOM, bool rearrange = true); /** * Insert item_to_add along with associated value to the list right after the after_item. @@ -269,6 +271,15 @@ public: virtual void clear(); /** + * Removes all items that can be detached from the list but doesn't destroy + * them, caller responsible to manage items after they are detached. + * Detachable item should accept "detach" action via notify() method, + * where it disconnect all callbacks, does other valuable routines and + * return 1. + */ + void detachItems(std::vector<LLPanel*>& detached_items); + + /** * Set comparator to use for future sorts. * * This class does NOT manage lifetime of the comparator @@ -359,6 +370,8 @@ protected: LLRect getSelectedItemsRect(); + void ensureSelectedVisible(); + private: void setItemsNoScrollWidth(S32 new_width) {mItemsNoScrollWidth = new_width - 2 * mBorderThickness;} |