本文整理汇总了C++中LLAccordionCtrlTab::isExpanded方法的典型用法代码示例。如果您正苦于以下问题:C++ LLAccordionCtrlTab::isExpanded方法的具体用法?C++ LLAccordionCtrlTab::isExpanded怎么用?C++ LLAccordionCtrlTab::isExpanded使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LLAccordionCtrlTab
的用法示例。
在下文中一共展示了LLAccordionCtrlTab::isExpanded方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: selectItemInAccordionTab
LLFolderViewItem* LLLandmarksPanel::selectItemInAccordionTab(LLPlacesInventoryPanel* inventory_list,
const std::string& tab_name,
const LLUUID& obj_id,
BOOL take_keyboard_focus) const
{
if (!inventory_list)
return NULL;
LLFolderView* root = inventory_list->getRootFolder();
LLFolderViewItem* item = inventory_list->getItemByID(obj_id);
if (!item)
return NULL;
LLAccordionCtrlTab* tab = getChild<LLAccordionCtrlTab>(tab_name);
if (!tab->isExpanded())
{
tab->changeOpenClose(false);
}
root->setSelection(item, FALSE, take_keyboard_focus);
LLAccordionCtrl* accordion = getChild<LLAccordionCtrl>("landmarks_accordion");
LLRect screen_rc;
localRectToScreen(item->getRect(), &screen_rc);
accordion->notifyParent(LLSD().with("scrollToShowRect", screen_rc.getValue()));
return item;
}
示例2: expand_all_folders
void LLOutfitsList::expand_all_folders()
{
for (outfits_map_t::iterator iter = mOutfitsMap.begin();
iter != mOutfitsMap.end();
++iter)
{
LLAccordionCtrlTab* tab = iter->second;
if(tab && !tab->isExpanded())
{
tab->changeOpenClose(false);
}
}
}
示例3: onAccordionTabRightClick
void LLTeleportHistoryPanel::onAccordionTabRightClick(LLView *view, S32 x, S32 y, MASK mask)
{
LLAccordionCtrlTab *tab = (LLAccordionCtrlTab *) view;
// If click occurred below the header, don't show this menu
if (y < tab->getRect().getHeight() - tab->getHeaderHeight() - tab->getPaddingBottom())
return;
if (mAccordionTabMenu)
{
//preventing parent (menu holder) from deleting already "dead" context menus on exit
LLView* parent = mAccordionTabMenu->getParent();
if (parent)
{
parent->removeChild(mAccordionTabMenu);
}
delete mAccordionTabMenu;
}
// set up the callbacks for all of the avatar menu items
// (N.B. callbacks don't take const refs as mID is local scope)
LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar;
registrar.add("TeleportHistory.TabOpen", boost::bind(&LLTeleportHistoryPanel::onAccordionTabOpen, this, tab));
registrar.add("TeleportHistory.TabClose", boost::bind(&LLTeleportHistoryPanel::onAccordionTabClose, this, tab));
// create the context menu from the XUI
llassert(LLMenuGL::sMenuContainer != NULL);
mAccordionTabMenu = LLUICtrlFactory::getInstance()->createFromFile<LLContextMenu>(
"menu_teleport_history_tab.xml", LLMenuGL::sMenuContainer, LLViewerMenuHolderGL::child_registry_t::instance());
mAccordionTabMenu->setItemVisible("TabOpen", !tab->isExpanded() ? true : false);
mAccordionTabMenu->setItemVisible("TabClose", tab->isExpanded() ? true : false);
mAccordionTabMenu->show(x, y);
LLMenuGL::showPopup(tab, mAccordionTabMenu, x, y);
}