LLInventoryPanel Class Reference

#include <llinventoryview.h>

Inheritance diagram for LLInventoryPanel:

Inheritance graph
[legend]
Collaboration diagram for LLInventoryPanel:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 LLInventoryPanel (const LLString &name, const LLString &sort_order_setting, const LLRect &rect, LLInventoryModel *inventory, LLFolderSearchFunction search, BOOL allow_multi_select, LLView *parent_view=NULL)
 ~LLInventoryPanel ()
LLInventoryModelgetModel ()
BOOL postBuild ()
virtual EWidgetType getWidgetType () const
virtual LLString getWidgetTag () const
virtual LLXMLNodePtr getXML (bool save_children=true) const
BOOL handleHover (S32 x, S32 y, MASK mask)
BOOL handleDragAndDrop (S32 x, S32 y, MASK mask, BOOL drop, EDragAndDropType cargo_type, void *cargo_data, EAcceptance *accept, LLString &tooltip_msg)
void openAllFolders ()
void closeAllFolders ()
void openDefaultFolderForType (LLAssetType::EType)
void setSelection (const LLUUID &obj_id, BOOL take_keyboard_focus)
void setSelectCallback (LLFolderView::SelectCallback callback, void *user_data)
void clearSelection ()
LLInventoryFiltergetFilter ()
void setFilterTypes (U32 filter)
U32 getFilterTypes () const
void setFilterPermMask (PermissionMask filter_perm_mask)
U32 getFilterPermMask () const
void setFilterSubString (const LLString &string)
const LLString getFilterSubString ()
void setSortOrder (U32 order)
U32 getSortOrder ()
void setSinceLogoff (BOOL sl)
void setHoursAgo (U32 hours)
BOOL getSinceLogoff ()
void setShowFolderState (LLInventoryFilter::EFolderShow show)
LLInventoryFilter::EFolderShow getShowFolderState ()
void setAllowMultiSelect (BOOL allow)
void modelChanged (U32 mask)
LLFolderViewgetRootFolder ()
LLScrollableContainerViewgetScrollableContainer ()
void openSelected ()
void unSelectAll ()
void createNewItem (const char *name, const LLUUID &parent_id, LLAssetType::EType asset_type, LLInventoryType::EType inv_type, U32 next_owner_perm=0)

Static Public Member Functions

static LLViewfromXML (LLXMLNodePtr node, LLView *parent, LLUICtrlFactory *factory)
static void dumpSelectionInformation (void *user_data)

Static Public Attributes

static const LLString DEFAULT_SORT_ORDER = LLString("InventorySortOrder")
static const LLString RECENTITEMS_SORT_ORDER = LLString("RecentItemsSortOrder")
static const LLString INHERIT_SORT_ORDER = LLString("")

Protected Member Functions

void rebuildViewsFor (const LLUUID &id, U32 mask)
void buildNewViews (const LLUUID &id)

Protected Attributes

LLInventoryModelmInventory
LLInventoryObservermInventoryObserver
LLFolderViewmFolders
LLScrollableContainerViewmScroller
BOOL mAllowMultiSelect
const LLString mSortOrderSetting
LLFolderSearchFunction mSearchFunction

Detailed Description

Definition at line 66 of file llinventoryview.h.


Constructor & Destructor Documentation

LLInventoryPanel::LLInventoryPanel ( const LLString name,
const LLString sort_order_setting,
const LLRect rect,
LLInventoryModel inventory,
LLFolderSearchFunction  search,
BOOL  allow_multi_select,
LLView parent_view = NULL 
)

Definition at line 1214 of file llinventoryview.cpp.

Referenced by fromXML().

LLInventoryPanel::~LLInventoryPanel (  ) 

Definition at line 1277 of file llinventoryview.cpp.

References LLFolderView::getSortOrder(), gSavedSettings, INHERIT_SORT_ORDER, mFolders, mInventory, mInventoryObserver, mScroller, mSortOrderSetting, NULL, LLInventoryModel::removeObserver(), and LLControlGroup::setU32().


Member Function Documentation

void LLInventoryPanel::buildNewViews ( const LLUUID id  )  [protected]

Definition at line 1502 of file llinventoryview.cpp.

References LLFolderViewItem::addToFolder(), LLAssetType::AT_CATEGORY, LLAssetType::AT_COUNT, LLAssetType::AT_NONE, LLDynamicArray< Type, BlockSize >::count(), count, LLInvFVBridge::createBridge(), LLDynamicArray< Type, BlockSize >::get(), LLInvFVBridge::getCreationDate(), LLInventoryModel::getDirectDescendentsOf(), LLInvFVBridge::getDisplayName(), LLInventoryItem::getFlags(), LLFolderViewEventListener::getIcon(), LLInventoryItem::getInventoryType(), LLFolderView::getItemByID(), LLFolderViewItem::getLabel(), LLInventoryModel::getObject(), LLInventoryObject::getParentUUID(), LLFolderView::getSortOrder(), LLInventoryObject::getType(), LLInventoryObject::getUUID(), gInventory, i, LLInventoryType::IT_CATEGORY, llendl, llwarns, mFolders, mInventory, NULL, S32, and LLFolderViewFolder::setItemSortOrder().

Referenced by modelChanged(), and rebuildViewsFor().

void LLInventoryPanel::clearSelection (  ) 

Definition at line 1708 of file llinventoryview.cpp.

References LLFolderView::clearSelection(), and mFolders.

Referenced by LLFloaterTexturePicker::setImageID().

void LLInventoryPanel::closeAllFolders (  ) 

Definition at line 1684 of file llinventoryview.cpp.

References LLFolderView::arrangeAll(), FALSE, mFolders, LLFolderViewFolder::RECURSE_DOWN, and LLFolderView::setOpenArrangeRecursively().

void LLInventoryPanel::createNewItem ( const char *  name,
const LLUUID parent_id,
LLAssetType::EType  asset_type,
LLInventoryType::EType  inv_type,
U32  next_owner_perm = 0 
)

Definition at line 1713 of file llinventoryview.cpp.

References create_inventory_item(), gAgent, LLAssetType::generateDescriptionFor(), LLAgent::getID(), LLAgent::getSessionID(), NOT_WEARABLE, NULL, PERM_MOVE, PERM_TRANSFER, and LLTransactionID::tnull.

Referenced by do_create().

void LLInventoryPanel::dumpSelectionInformation ( void user_data  )  [static]

Definition at line 1731 of file llinventoryview.cpp.

References LLFolderView::dumpSelectionInformation(), and mFolders.

LLView * LLInventoryPanel::fromXML ( LLXMLNodePtr  node,
LLView parent,
LLUICtrlFactory factory 
) [static]

Reimplemented from LLPanel.

Definition at line 1302 of file llinventoryview.cpp.

References LLView::createRect(), gInventory, LLInventoryView::incrementalFind(), INHERIT_SORT_ORDER, LLUICtrl::initFromXML(), LLInventoryPanel(), postBuild(), and TRUE.

LLInventoryFilter* LLInventoryPanel::getFilter (  )  [inline]

Definition at line 106 of file llinventoryview.h.

References LLFolderView::getFilter(), and mFolders.

Referenced by LLResetFilter::handleEvent(), LLInventoryView::init(), LLInventoryView::setFilterTextFromFilter(), and LLInventoryView::~LLInventoryView().

U32 LLInventoryPanel::getFilterPermMask (  )  const [inline]

Definition at line 110 of file llinventoryview.h.

References LLFolderView::getFilterPermissions(), and mFolders.

const LLString LLInventoryPanel::getFilterSubString (  )  [inline]

Definition at line 112 of file llinventoryview.h.

References LLFolderView::getFilterSubString(), and mFolders.

Referenced by LLFloaterTexturePicker::draw(), LLInventoryView::draw(), LLInventoryView::getFilterSubString(), LLNewWindow::handleEvent(), LLFloaterTexturePicker::onSearchEdit(), and LLFloaterLandmark::onSearchEdit().

U32 LLInventoryPanel::getFilterTypes (  )  const [inline]

Definition at line 108 of file llinventoryview.h.

References LLFolderView::getFilterTypes(), and mFolders.

Referenced by LLNewWindow::handleEvent().

LLInventoryModel* LLInventoryPanel::getModel (  )  [inline]

Definition at line 82 of file llinventoryview.h.

References mInventory.

Referenced by LLFolderBridge::buildContextMenu(), LLEmptyTrash::callback_empty_trash(), LLFolderBridge::createNewCategory(), LLFolderBridge::dragCategoryIntoFolder(), LLFolderBridge::dragItemIntoFolder(), LLFolderBridge::folderOptionsMenu(), LLFolderBridge::getCategory(), LLInvFVBridge::getInventoryObject(), LLItemBridge::getItem(), LLBeginIMSession::handleEvent(), LLDoCreateFloater::handleEvent(), LLDoCreate::handleEvent(), LLEmptyTrashFloater::handleEvent(), LLEmptyTrash::handleEvent(), LLNewWindow::handleEvent(), LLFolderBridge::hasChildren(), LLInvFVBridge::isAgentInventory(), LLInvFVBridge::isClipboardPasteable(), LLInvFVBridge::isInTrash(), LLFolderBridge::isItemRemovable(), LLInvFVBridge::isItemRemovable(), LLFolderBridge::isUpToDate(), modelChanged(), LLFolderBridge::modifyOutfit(), LLFolderBridge::openItem(), LLFolderBridge::pasteFromClipboard(), LLFolderBridge::performAction(), LLInvFVBridge::removeBatchNoCheck(), LLFolderBridge::removeItem(), LLItemBridge::removeItem(), LLObjectBridge::renameItem(), LLFolderBridge::renameItem(), LLItemBridge::renameItem(), LLFolderBridge::restoreItem(), and LLItemBridge::restoreItem().

LLFolderView* LLInventoryPanel::getRootFolder (  )  [inline]

Definition at line 124 of file llinventoryview.h.

References mFolders.

Referenced by do_create(), LLAttachObject::handleEvent(), LLBeginIMSession::handleEvent(), LLDoToSelected::handleEvent(), LLDoToSelectedFloater::handleEvent(), LLFloaterTexturePicker::handleKeyHere(), LLInventoryView::handleKeyHere(), LLFloaterLandmark::handleKeyHere(), LLInventoryView::incrementalFind(), LLInventoryView::init(), LLFloaterLandmark::LLFloaterLandmark(), LLFloaterTexturePicker::LLFloaterTexturePicker(), LLInventoryView::onClose(), LLFloaterTexturePicker::onSearchEdit(), LLFloaterLandmark::onSearchEdit(), LLInventoryView::onSelectionChange(), and LLCallingCardBridge::refreshFolderViewItem().

LLScrollableContainerView* LLInventoryPanel::getScrollableContainer (  )  [inline]

Definition at line 125 of file llinventoryview.h.

References mScroller.

Referenced by LLInventoryView::handleDragAndDrop().

LLInventoryFilter::EFolderShow LLInventoryPanel::getShowFolderState (  ) 

Definition at line 1370 of file llinventoryview.cpp.

References LLFolderView::getFilter(), LLInventoryFilter::getShowFolderState(), and mFolders.

BOOL LLInventoryPanel::getSinceLogoff (  )  [inline]

Definition at line 117 of file llinventoryview.h.

References LLFolderView::getFilter(), LLInventoryFilter::isSinceLogoff(), and mFolders.

U32 LLInventoryPanel::getSortOrder (  )  [inline]

Definition at line 114 of file llinventoryview.h.

References LLFolderView::getSortOrder(), and mFolders.

virtual LLString LLInventoryPanel::getWidgetTag (  )  const [inline, virtual]

Reimplemented from LLPanel.

Definition at line 87 of file llinventoryview.h.

References LL_INVENTORY_PANEL_TAG.

virtual EWidgetType LLInventoryPanel::getWidgetType (  )  const [inline, virtual]

Reimplemented from LLPanel.

Definition at line 86 of file llinventoryview.h.

References WIDGET_TYPE_INVENTORY_PANEL.

LLXMLNodePtr LLInventoryPanel::getXML ( bool  save_children = true  )  const [virtual]

Reimplemented from LLPanel.

Definition at line 1293 of file llinventoryview.cpp.

References LLFolderView::getAllowMultiSelect(), LLPanel::getXML(), mFolders, and TRUE.

BOOL LLInventoryPanel::handleDragAndDrop ( S32  x,
S32  y,
MASK  mask,
BOOL  drop,
EDragAndDropType  cargo_type,
void cargo_data,
EAcceptance accept,
LLString tooltip_msg 
) [virtual]

Reimplemented from LLView.

Definition at line 1660 of file llinventoryview.cpp.

References LLView::handleDragAndDrop(), mFolders, and LLFolderView::setDragAndDropThisFrame().

BOOL LLInventoryPanel::handleHover ( S32  x,
S32  y,
MASK  mask 
) [virtual]

Reimplemented from LLView.

Definition at line 1641 of file llinventoryview.cpp.

References LLInventoryModel::backgroundFetchActive(), LLWindow::getCursor(), LLView::getWindow(), LLView::handleHover(), LLWindow::setCursor(), TRUE, UI_CURSOR_ARROW, and UI_CURSOR_WORKING.

void LLInventoryPanel::modelChanged ( U32  mask  ) 

Definition at line 1375 of file llinventoryview.cpp.

References LLInventoryObserver::ADD, LLFolderViewItem::addToFolder(), buildNewViews(), LLInvFVBridge::clearDisplayName(), LLFolderViewItem::destroyView(), LLFolderViewFolder::extractItem(), FALSE, LLFastTimer::FTM_REFRESH, LLInventoryModel::getChangedIDs(), LLFolderView::getItemByID(), LLFolderViewItem::getListener(), getModel(), LLInventoryModel::getObject(), LLFolderViewItem::getParentFolder(), LLFolderViewItem::getRoot(), gInventory, LLInventoryObserver::LABEL, llendl, llwarns, mFolders, LLFolderView::needsAutoRename(), NULL, LLFolderViewItem::refresh(), LLInventoryObserver::REMOVE, setSelection(), and LLInventoryObserver::STRUCTURE.

Referenced by LLInventoryPanelObserver::changed().

void LLInventoryPanel::openAllFolders (  ) 

Definition at line 1678 of file llinventoryview.cpp.

References LLFolderView::arrangeAll(), mFolders, LLFolderViewFolder::RECURSE_DOWN, LLFolderView::setOpenArrangeRecursively(), and TRUE.

void LLInventoryPanel::openDefaultFolderForType ( LLAssetType::EType   ) 

Definition at line 1690 of file llinventoryview.cpp.

References LLFolderViewFolder::applyFunctorRecursively(), LLInventoryModel::findCategoryUUIDForType(), mFolders, and mInventory.

Referenced by LLFloaterLandmark::LLFloaterLandmark(), and LLFloaterAvatarPicker::postBuild().

void LLInventoryPanel::openSelected (  ) 

Definition at line 1632 of file llinventoryview.cpp.

References LLFolderView::getCurSelectedItem(), LLFolderViewItem::getListener(), mFolders, and LLInvFVBridge::openItem().

Referenced by handle_grab_texture(), and LLNewAgentInventoryResponder::uploadComplete().

BOOL LLInventoryPanel::postBuild (  )  [virtual]

Reimplemented from LLPanel.

Definition at line 1232 of file llinventoryview.cpp.

References LLInventoryObserver::ADD, LLView::addChild(), LLInventoryModel::addObserver(), DEFAULT_SORT_ORDER, LLControlGroup::getU32(), LLRectBase< Type >::getWidth(), gSavedSettings, INHERIT_SORT_ORDER, init_inventory_panel_actions(), mAllowMultiSelect, LLRectBase< Type >::mBottom, mFolders, mInventory, mInventoryObserver, LLRectBase< Type >::mLeft, LLView::mName, LLView::mRect, mScroller, mSortOrderSetting, LLUUID::null, NULL, rebuildViewsFor(), LLView::setFollowsAll(), LLScrollableContainerView::setReserveScrollCorner(), setSortOrder(), LLRectBase< Type >::translate(), and TRUE.

Referenced by fromXML().

void LLInventoryPanel::rebuildViewsFor ( const LLUUID id,
U32  mask 
) [protected]

Definition at line 1488 of file llinventoryview.cpp.

References buildNewViews(), LLFolderViewItem::destroyView(), LLFolderView::getItemByID(), mFolders, and NULL.

Referenced by postBuild().

void LLInventoryPanel::setAllowMultiSelect ( BOOL  allow  )  [inline]

Definition at line 121 of file llinventoryview.h.

References mFolders, and LLFolderView::setAllowMultiSelect().

Referenced by LLFloaterLandmark::LLFloaterLandmark(), LLFloaterTexturePicker::LLFloaterTexturePicker(), and LLFloaterAvatarPicker::setAllowMultiple().

void LLInventoryPanel::setFilterPermMask ( PermissionMask  filter_perm_mask  ) 

Definition at line 1334 of file llinventoryview.cpp.

References LLFolderView::getFilter(), mFolders, and LLInventoryFilter::setFilterPermissions().

Referenced by LLFloaterTexturePicker::LLFloaterTexturePicker().

void LLInventoryPanel::setFilterSubString ( const LLString string  ) 

Definition at line 1339 of file llinventoryview.cpp.

References LLFolderView::getFilter(), mFolders, and LLInventoryFilter::setFilterSubString().

Referenced by LLNewWindow::handleEvent(), LLFloaterTexturePicker::onSearchEdit(), LLFloaterLandmark::onSearchEdit(), and LLInventoryView::setFilterSubString().

void LLInventoryPanel::setFilterTypes ( U32  filter  ) 

Definition at line 1329 of file llinventoryview.cpp.

References LLFolderView::getFilter(), mFolders, and LLInventoryFilter::setFilterTypes().

Referenced by LLInventoryViewFinder::draw(), LLNewWindow::handleEvent(), LLFloaterLandmark::LLFloaterLandmark(), LLFloaterTexturePicker::LLFloaterTexturePicker(), and LLFloaterAvatarPicker::postBuild().

void LLInventoryPanel::setHoursAgo ( U32  hours  ) 

Definition at line 1360 of file llinventoryview.cpp.

References LLFolderView::getFilter(), mFolders, and LLInventoryFilter::setHoursAgo().

Referenced by LLInventoryViewFinder::draw().

void LLInventoryPanel::setSelectCallback ( LLFolderView::SelectCallback  callback,
void user_data 
) [inline]

Definition at line 104 of file llinventoryview.h.

References mFolders, and LLFolderView::setSelectCallback().

Referenced by LLInventoryView::init(), LLFloaterLandmark::LLFloaterLandmark(), LLFloaterTexturePicker::LLFloaterTexturePicker(), and LLFloaterAvatarPicker::postBuild().

void LLInventoryPanel::setSelection ( const LLUUID obj_id,
BOOL  take_keyboard_focus 
)

Definition at line 1697 of file llinventoryview.cpp.

References LLFolderViewEventListener::arrangeAndSet(), LLFolderView::getItemByID(), LLFolderViewItem::getListener(), mFolders, and TRUE.

Referenced by LLFloaterOpenObject::callbackMoveInventory(), container_inventory_arrived(), LLFolderBridge::createNewCategory(), do_create(), handle_grab_texture(), LLFloaterLandmark::LLFloaterLandmark(), LLFloaterTexturePicker::LLFloaterTexturePicker(), LLAgent::makeNewOutfitDone(), modelChanged(), open_offer(), LLInventoryModel::processUpdateInventoryFolder(), LLFloaterTexturePicker::setImageID(), and LLNewAgentInventoryResponder::uploadComplete().

void LLInventoryPanel::setShowFolderState ( LLInventoryFilter::EFolderShow  show  ) 

Definition at line 1365 of file llinventoryview.cpp.

References LLFolderView::getFilter(), mFolders, and LLInventoryFilter::setShowFolderState().

Referenced by LLInventoryViewFinder::draw(), LLInventoryView::init(), LLFloaterLandmark::LLFloaterLandmark(), LLFloaterTexturePicker::LLFloaterTexturePicker(), LLFloaterTexturePicker::onShowFolders(), LLFloaterLandmark::onShowFolders(), and LLFloaterAvatarPicker::postBuild().

void LLInventoryPanel::setSinceLogoff ( BOOL  sl  ) 

Definition at line 1355 of file llinventoryview.cpp.

References LLFolderView::getFilter(), mFolders, and LLInventoryFilter::setDateRangeLastLogoff().

Referenced by LLInventoryViewFinder::draw(), and LLInventoryView::init().

void LLInventoryPanel::setSortOrder ( U32  order  ) 

Definition at line 1344 of file llinventoryview.cpp.

References LLFolderView::getFilter(), LLInventoryFilter::isModified(), mFolders, LLFolderView::scrollToShowSelection(), LLFolderView::setSortOrder(), and LLInventoryFilter::setSortOrder().

Referenced by LLInventoryView::init(), and postBuild().

void LLInventoryPanel::unSelectAll (  )  [inline]

Definition at line 132 of file llinventoryview.h.

References FALSE, mFolders, NULL, and LLFolderView::setSelection().

Referenced by LLFolderBridge::dragItemIntoFolder().


Member Data Documentation

const LLString LLInventoryPanel::DEFAULT_SORT_ORDER = LLString("InventorySortOrder") [static]

Definition at line 69 of file llinventoryview.h.

Referenced by postBuild().

const LLString LLInventoryPanel::INHERIT_SORT_ORDER = LLString("") [static]

Definition at line 71 of file llinventoryview.h.

Referenced by fromXML(), postBuild(), and ~LLInventoryPanel().

BOOL LLInventoryPanel::mAllowMultiSelect [protected]

Definition at line 155 of file llinventoryview.h.

Referenced by postBuild().

LLFolderView* LLInventoryPanel::mFolders [protected]

Definition at line 153 of file llinventoryview.h.

Referenced by buildNewViews(), clearSelection(), closeAllFolders(), dumpSelectionInformation(), getFilter(), getFilterPermMask(), getFilterSubString(), getFilterTypes(), getRootFolder(), getShowFolderState(), getSinceLogoff(), getSortOrder(), getXML(), handleDragAndDrop(), modelChanged(), openAllFolders(), openDefaultFolderForType(), openSelected(), postBuild(), rebuildViewsFor(), setAllowMultiSelect(), setFilterPermMask(), setFilterSubString(), setFilterTypes(), setHoursAgo(), setSelectCallback(), setSelection(), setShowFolderState(), setSinceLogoff(), setSortOrder(), unSelectAll(), and ~LLInventoryPanel().

LLInventoryModel* LLInventoryPanel::mInventory [protected]

Definition at line 151 of file llinventoryview.h.

Referenced by buildNewViews(), getModel(), openDefaultFolderForType(), postBuild(), and ~LLInventoryPanel().

LLInventoryObserver* LLInventoryPanel::mInventoryObserver [protected]

Definition at line 152 of file llinventoryview.h.

Referenced by postBuild(), and ~LLInventoryPanel().

LLScrollableContainerView* LLInventoryPanel::mScroller [protected]

Definition at line 154 of file llinventoryview.h.

Referenced by getScrollableContainer(), postBuild(), and ~LLInventoryPanel().

LLFolderSearchFunction LLInventoryPanel::mSearchFunction [protected]

Definition at line 157 of file llinventoryview.h.

const LLString LLInventoryPanel::mSortOrderSetting [protected]

Definition at line 156 of file llinventoryview.h.

Referenced by postBuild(), and ~LLInventoryPanel().

const LLString LLInventoryPanel::RECENTITEMS_SORT_ORDER = LLString("RecentItemsSortOrder") [static]

Definition at line 70 of file llinventoryview.h.


The documentation for this class was generated from the following files:
Generated on Thu Jul 1 06:11:26 2010 for Second Life Viewer by  doxygen 1.4.7