void show(LLView* spawning_view)
	{
		if (!mMenu) return;

		updateItemsVisibility();
		mMenu->buildDrawLabels();
		mMenu->updateParent(LLMenuGL::sMenuContainer);
		S32 menu_x = 0;
		S32 menu_y = spawning_view->getRect().getHeight() + mMenu->getRect().getHeight();
		LLMenuGL::showPopup(spawning_view, mMenu, menu_x, menu_y);
	}
// virtual
LLContextMenu* LLWearableItemsList::ContextMenu::createMenu()
{
    LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar;
    const uuid_vec_t& ids = mUUIDs;		// selected items IDs
    LLUUID selected_id = ids.front();	// ID of the first selected item

    functor_t take_off = boost::bind(&LLAppearanceMgr::removeItemFromAvatar, LLAppearanceMgr::getInstance(), _1);

    // Register handlers common for all wearable types.
    registrar.add("Wearable.Wear", boost::bind(wear_multiple, ids, true));
    registrar.add("Wearable.Add", boost::bind(wear_multiple, ids, false));
    registrar.add("Wearable.Edit", boost::bind(handleMultiple, LLAgentWearables::editWearable, ids));
    registrar.add("Wearable.CreateNew", boost::bind(createNewWearable, selected_id));
    registrar.add("Wearable.ShowOriginal", boost::bind(show_item_original, selected_id));
    registrar.add("Wearable.TakeOffDetach", boost::bind(handleMultiple, take_off, ids));

    // Register handlers for clothing.
    registrar.add("Clothing.TakeOff", boost::bind(handleMultiple, take_off, ids));

    // Register handlers for body parts.

    // Register handlers for attachments.
    registrar.add("Attachment.Detach", boost::bind(handleMultiple, take_off, ids));
    registrar.add("Attachment.Profile", boost::bind(show_item_profile, selected_id));
    registrar.add("Object.Attach", boost::bind(LLViewerAttachMenu::attachObjects, ids, _2));

    // Create the menu.
    LLContextMenu* menu = createFromFile("menu_wearable_list_item.xml");

    // Determine which items should be visible/enabled.
    updateItemsVisibility(menu);

    // Update labels for the items requiring that.
    updateItemsLabels(menu);
    return menu;
}