LLFloaterCustomize Class Reference

#include <llfloatercustomize.h>

Inheritance diagram for LLFloaterCustomize:

Inheritance graph
[legend]
Collaboration diagram for LLFloaterCustomize:

Collaboration graph
[legend]
List of all members.

Public Types

typedef std::pair< BOOL, LLViewerVisualParam * > editable_param
typedef std::map< F32, editable_paramparam_map

Public Member Functions

 LLFloaterCustomize ()
virtual ~LLFloaterCustomize ()
virtual BOOL postBuild ()
virtual void onClose (bool app_quitting)
virtual void draw ()
void clearScrollingPanelList ()
void generateVisualParamHints (LLViewerJointMesh *joint_mesh, param_map &params)
const LLStringgetEditGroup ()
void addVisualParamToUndoBuffer (LLViewerVisualParam *param, F32 current_weight)
void updateScrollingPanelList (BOOL allow_modify)
void setWearable (EWearableType type, LLWearable *wearable, U32 perm_mask, BOOL is_complete)
LLPanelEditWearablegetCurrentWearablePanel ()
virtual BOOL isDirty () const
void askToSaveAllIfDirty (void(*next_step_callback)(BOOL proceed, void *userdata), void *userdata)
void spawnWearableAppearance (EWearableType type)
void switchToDefaultSubpart ()
void fetchInventory ()
void updateInventoryUI ()
void updateScrollingPanelUI ()

Static Public Member Functions

static void setCurrentWearableType (EWearableType type)
static EWearableType getCurrentWearableType ()
static void onBtnSaveAll (void *userdata)
static void onBtnSnapshot (void *userdata)
static void onBtnMakeOutfit (void *userdata)
static void onMakeOutfitCommit (LLMakeOutfitDialog *dialog, void *userdata)
static void onTabChanged (void *userdata, bool from_click)
static void onSaveAllDialog (S32 option, void *userdata)

Protected Member Functions

void initWearablePanels ()
void initScrollingPanelList ()

Static Protected Member Functions

static voidcreateWearablePanel (void *userdata)

Protected Attributes

LLPanelEditWearablemWearablePanelList [WT_COUNT]
LLScrollingPanelListmScrollingPanelList
LLScrollableContainerViewmScrollContainer
LLGenePoolmGenePool
LLVisualParamResetmResetParams
LLInventoryObservermInventoryObserver
void(* mNextStepAfterSaveAllCallback )(BOOL proceed, void *userdata)
voidmNextStepAfterSaveAllUserdata

Static Protected Attributes

static EWearableType sCurrentWearableType = WT_SHAPE

Detailed Description

Definition at line 72 of file llfloatercustomize.h.


Member Typedef Documentation

typedef std::pair<BOOL, LLViewerVisualParam*> LLFloaterCustomize::editable_param

Definition at line 75 of file llfloatercustomize.h.

typedef std::map<F32, editable_param> LLFloaterCustomize::param_map

Definition at line 76 of file llfloatercustomize.h.


Constructor & Destructor Documentation

LLFloaterCustomize::LLFloaterCustomize (  ) 

Definition at line 1550 of file llfloatercustomize.cpp.

References LLInventoryModel::addObserver(), LLUICtrlFactory::buildFloater(), createWearablePanel(), gAgent, LLAgent::getAvatarObject(), LLCharacter::getSex(), gInventory, gSavedSettings, gUICtrlFactory, mInventoryObserver, mResetParams, LLControlGroup::setU32(), SEX_MALE, WT_EYES, WT_GLOVES, WT_HAIR, WT_JACKET, WT_PANTS, WT_SHAPE, WT_SHIRT, WT_SHOES, WT_SKIN, WT_SKIRT, WT_SOCKS, WT_UNDERPANTS, and WT_UNDERSHIRT.

LLFloaterCustomize::~LLFloaterCustomize (  )  [virtual]

Definition at line 2105 of file llfloatercustomize.cpp.

References gInventory, llendl, llinfos, mGenePool, mInventoryObserver, mResetParams, and LLInventoryModel::removeObserver().


Member Function Documentation

void LLFloaterCustomize::addVisualParamToUndoBuffer ( LLViewerVisualParam param,
F32  current_weight 
)

void LLFloaterCustomize::askToSaveAllIfDirty ( void(*)(BOOL proceed, void *userdata)  next_step_callback,
void userdata 
)

Definition at line 2258 of file llfloatercustomize.cpp.

References LLViewerWindow::alertXml(), gViewerWindow, isDirty(), mNextStepAfterSaveAllCallback, mNextStepAfterSaveAllUserdata, onSaveAllDialog(), and TRUE.

Referenced by handle_reset_view(), remove_inventory_category_from_avatar(), LLAgent::userRemoveAllClothes(), and wear_inventory_category_on_avatar().

void LLFloaterCustomize::clearScrollingPanelList (  ) 

Definition at line 2211 of file llfloatercustomize.cpp.

References LLScrollingPanelList::clearPanels(), and mScrollingPanelList.

Referenced by LLPanelEditWearable::onCommitSexChange().

void * LLFloaterCustomize::createWearablePanel ( void userdata  )  [static, protected]

Definition at line 1728 of file llfloatercustomize.cpp.

References edit_wearable_for_teens(), gAgent, LLAgent::isTeen(), WearablePanelData::mFloater, WearablePanelData::mType, mWearablePanelList, NULL, and type.

Referenced by LLFloaterCustomize().

void LLFloaterCustomize::draw (  )  [virtual]

Reimplemented from LLFloater.

Definition at line 2134 of file llfloatercustomize.cpp.

References LLPanel::childSetEnabled(), LLFloater::draw(), LLView::getVisible(), isDirty(), LLFloater::isMinimized(), and updateInventoryUI().

void LLFloaterCustomize::fetchInventory (  ) 

Definition at line 2327 of file llfloatercustomize.cpp.

References LLInventoryFetchObserver::fetchItems(), gAgent, LLAgent::getWearableItem(), LLUUID::notNull(), S32, type, WT_COUNT, and WT_SHAPE.

Referenced by LLMorphView::setVisible().

void LLFloaterCustomize::generateVisualParamHints ( LLViewerJointMesh joint_mesh,
param_map params 
)

Definition at line 2219 of file llfloatercustomize.cpp.

References LLScrollingPanelList::addPanel(), LLScrollingPanelList::clearPanels(), end, and mScrollingPanelList.

Referenced by LLPanelEditWearable::setSubpart().

LLPanelEditWearable* LLFloaterCustomize::getCurrentWearablePanel (  )  [inline]

Definition at line 99 of file llfloatercustomize.h.

References mWearablePanelList, and sCurrentWearableType.

Referenced by getEditGroup(), LLPanelEditWearable::onBtnSubpart(), LLScrollingPanelParam::onSliderMouseDown(), and switchToDefaultSubpart().

static EWearableType LLFloaterCustomize::getCurrentWearableType (  )  [inline, static]

Definition at line 110 of file llfloatercustomize.h.

References sCurrentWearableType.

Referenced by onSaveAllDialog().

const LLString & LLFloaterCustomize::getEditGroup (  ) 

Definition at line 1530 of file llfloatercustomize.cpp.

References LLPanelEditWearable::getCurrentSubpart(), getCurrentWearablePanel(), and LLSubpart::mEditGroup.

void LLFloaterCustomize::initScrollingPanelList (  )  [protected]

Definition at line 2197 of file llfloatercustomize.cpp.

References LLView::addChild(), LLUICtrlFactory::getScrollableContainerByName(), mScrollingPanelList, and LLScrollableContainerView::setScrolledView().

Referenced by postBuild().

void LLFloaterCustomize::initWearablePanels (  )  [protected]

Definition at line 1746 of file llfloatercustomize.cpp.

References LLPanelEditWearable::addColorSwatch(), LLPanelEditWearable::addSubpart(), LLPanelEditWearable::addTextureDropTarget(), LLPanel::childSetAction(), LLPanel::childSetCommitCallback(), f, FALSE, LLControlGroup::getString(), gSavedSettings, LLSubpart::mCameraOffset, LLSubpart::mEditGroup, LLSubpart::mSex, LLSubpart::mTargetJoint, LLSubpart::mTargetOffset, mWearablePanelList, LLUUID::null, LLPanelEditWearable::onBtnRandomize(), LLPanelEditWearable::onCommitSexChange(), LLVector3d::setVec(), SEX_MALE, SUBPART_EYES, SUBPART_GLOVES, SUBPART_HAIR_COLOR, SUBPART_HAIR_EYEBROWS, SUBPART_HAIR_FACIAL, SUBPART_HAIR_STYLE, SUBPART_JACKET, SUBPART_PANTS, SUBPART_SHAPE_CHIN, SUBPART_SHAPE_EARS, SUBPART_SHAPE_EYES, SUBPART_SHAPE_HEAD, SUBPART_SHAPE_LEGS, SUBPART_SHAPE_MOUTH, SUBPART_SHAPE_NOSE, SUBPART_SHAPE_TORSO, SUBPART_SHAPE_WHOLE, SUBPART_SHIRT, SUBPART_SHOES, SUBPART_SKIN_BODYDETAIL, SUBPART_SKIN_COLOR, SUBPART_SKIN_FACEDETAIL, SUBPART_SKIN_MAKEUP, SUBPART_SOCKS, SUBPART_UNDERPANTS, SUBPART_UNDERSHIRT, LLVOAvatar::TEX_EYES_IRIS, LLVOAvatar::TEX_HAIR, LLVOAvatar::TEX_HEAD_BODYPAINT, LLVOAvatar::TEX_LOWER_BODYPAINT, LLVOAvatar::TEX_LOWER_JACKET, LLVOAvatar::TEX_LOWER_PANTS, LLVOAvatar::TEX_LOWER_SHOES, LLVOAvatar::TEX_LOWER_SOCKS, LLVOAvatar::TEX_LOWER_UNDERPANTS, LLVOAvatar::TEX_SKIRT, LLVOAvatar::TEX_UPPER_BODYPAINT, LLVOAvatar::TEX_UPPER_GLOVES, LLVOAvatar::TEX_UPPER_JACKET, LLVOAvatar::TEX_UPPER_SHIRT, LLVOAvatar::TEX_UPPER_UNDERSHIRT, TRUE, WT_EYES, WT_GLOVES, WT_HAIR, WT_JACKET, WT_PANTS, WT_SHAPE, WT_SHIRT, WT_SHOES, WT_SKIN, WT_SKIRT, WT_SOCKS, WT_UNDERPANTS, and WT_UNDERSHIRT.

Referenced by postBuild().

BOOL LLFloaterCustomize::isDirty (  )  const [virtual]

Reimplemented from LLUICtrl.

Definition at line 2158 of file llfloatercustomize.cpp.

References FALSE, i, mWearablePanelList, S32, TRUE, and WT_COUNT.

Referenced by askToSaveAllIfDirty(), and draw().

void LLFloaterCustomize::onBtnMakeOutfit ( void userdata  )  [static]

Definition at line 1684 of file llfloatercustomize.cpp.

References edit_wearable_for_teens(), FALSE, gAgent, LLAgent::getAvatarObject(), LLAgent::getWearable(), i, LLAgent::isTeen(), NULL, onMakeOutfitCommit(), S32, LLMakeOutfitDialog::setWearableToInclude(), LLModalDialog::startModal(), WT_COUNT, and WT_SHIRT.

Referenced by postBuild().

void LLFloaterCustomize::onBtnSaveAll ( void userdata  )  [static]

Definition at line 1652 of file llfloatercustomize.cpp.

References gAgent, and LLAgent::saveAllWearables().

Referenced by postBuild().

void LLFloaterCustomize::onBtnSnapshot ( void userdata  )  [static]

Definition at line 1659 of file llfloatercustomize.cpp.

References f, FALSE, LLControlGroup::getString(), LLViewerWindow::getWindowHeight(), LLViewerWindow::getWindowWidth(), gSavedSettings, gViewerWindow, LLViewerWindow::rawSnapshot(), send_sound_trigger(), and TRUE.

void LLFloaterCustomize::onClose ( bool  app_quitting  )  [virtual]

Reimplemented from LLFloater.

Definition at line 2179 of file llfloatercustomize.cpp.

References gFloaterView, handle_reset_view(), and LLView::sendChildToBack().

void LLFloaterCustomize::onMakeOutfitCommit ( LLMakeOutfitDialog dialog,
void userdata 
) [static]

Definition at line 1711 of file llfloatercustomize.cpp.

References gAgent, LLAgent::getAvatarObject(), LLMakeOutfitDialog::getFolderName(), LLMakeOutfitDialog::getIncludedItems(), LLMakeOutfitDialog::getRenameClothing(), and LLAgent::makeNewOutfit().

Referenced by onBtnMakeOutfit().

void LLFloaterCustomize::onSaveAllDialog ( S32  option,
void userdata 
) [static]

Definition at line 2281 of file llfloatercustomize.cpp.

References FALSE, gAgent, getCurrentWearableType(), llassert, LLAgent::revertAllWearables(), LLAgent::saveAllWearables(), setCurrentWearableType(), and TRUE.

Referenced by askToSaveAllIfDirty().

void LLFloaterCustomize::onTabChanged ( void userdata,
bool  from_click 
) [static]

Definition at line 2173 of file llfloatercustomize.cpp.

References setCurrentWearableType().

Referenced by postBuild().

BOOL LLFloaterCustomize::postBuild (  )  [virtual]

Reimplemented from LLPanel.

Definition at line 1585 of file llfloatercustomize.cpp.

References LLPanel::childSetAction(), LLPanel::childSetTabChangeCallback(), LLPanel::childShowTab(), gAgent, LLUICtrlFactory::getTabContainerByName(), initScrollingPanelList(), initWearablePanels(), LLAgent::isTeen(), onBtnMakeOutfit(), onBtnSaveAll(), LLFloater::onClickClose(), onTabChanged(), TRUE, WT_EYES, WT_GLOVES, WT_HAIR, WT_JACKET, WT_PANTS, WT_SHAPE, WT_SHIRT, WT_SHOES, WT_SKIN, WT_SKIRT, WT_SOCKS, WT_UNDERPANTS, and WT_UNDERSHIRT.

void LLFloaterCustomize::setCurrentWearableType ( EWearableType  type  )  [static]

Definition at line 1634 of file llfloatercustomize.cpp.

References LLPanel::childShowTab(), LLView::getName(), gFloaterCustomize, mWearablePanelList, S32, and switchToDefaultSubpart().

Referenced by LLWearableBridge::editOnAvatar(), onSaveAllDialog(), onTabChanged(), LLAgent::setWearableOutfit(), and LLWearable::writeToAvatar().

void LLFloaterCustomize::setWearable ( EWearableType  type,
LLWearable wearable,
U32  perm_mask,
BOOL  is_complete 
)

Definition at line 2235 of file llfloatercustomize.cpp.

References FALSE, gAgent, LLAgent::getAvatarObject(), LLCharacter::getSex(), gSavedSettings, llassert, mWearablePanelList, PERM_MODIFY, LLControlGroup::setU32(), LLPanelEditWearable::setWearable(), SEX_MALE, updateScrollingPanelList(), and WT_COUNT.

Referenced by LLWearable::removeFromAvatar(), and LLWearable::writeToAvatar().

void LLFloaterCustomize::spawnWearableAppearance ( EWearableType  type  ) 

Definition at line 2119 of file llfloatercustomize.cpp.

References gAgent, LLAgent::getAvatarObject(), mGenePool, and LLGenePool::spawn().

Referenced by LLPanelEditWearable::onBtnRandomize().

void LLFloaterCustomize::switchToDefaultSubpart (  ) 

Definition at line 2114 of file llfloatercustomize.cpp.

References getCurrentWearablePanel(), and LLPanelEditWearable::switchToDefaultSubpart().

Referenced by setCurrentWearableType(), and LLMorphView::setVisible().

void LLFloaterCustomize::updateInventoryUI (  ) 

Definition at line 2347 of file llfloatercustomize.cpp.

References LLPanel::childSetEnabled(), LLPanel::childSetVisible(), FALSE, gAgent, LLPermissions::getMaskOwner(), LLInventoryItem::getPermissions(), LLPanelEditWearable::getType(), LLAgent::getWearableInventoryItem(), i, LLViewerInventoryItem::isComplete(), mWearablePanelList, NULL, PERM_MODIFY, S32, sCurrentWearableType, TRUE, and WT_COUNT.

Referenced by draw().

void LLFloaterCustomize::updateScrollingPanelList ( BOOL  allow_modify  ) 

Definition at line 2248 of file llfloatercustomize.cpp.

References mScrollingPanelList, and LLScrollingPanelList::updatePanels().

Referenced by LLUndoWearable::applyUndoRedo(), LLPanelEditWearable::onBtnRandomize(), setWearable(), and updateScrollingPanelUI().

void LLFloaterCustomize::updateScrollingPanelUI (  ) 

Definition at line 2389 of file llfloatercustomize.cpp.

References FALSE, gAgent, LLPermissions::getMaskOwner(), LLInventoryItem::getPermissions(), LLPanelEditWearable::getType(), LLAgent::getWearableInventoryItem(), LLViewerInventoryItem::isComplete(), mWearablePanelList, PERM_MODIFY, sCurrentWearableType, and updateScrollingPanelList().

Referenced by LLFloaterCustomizeObserver::changed(), and LLPanelEditWearable::setSubpart().


Member Data Documentation

LLGenePool* LLFloaterCustomize::mGenePool [protected]

Definition at line 132 of file llfloatercustomize.h.

Referenced by spawnWearableAppearance(), and ~LLFloaterCustomize().

LLInventoryObserver* LLFloaterCustomize::mInventoryObserver [protected]

Definition at line 135 of file llfloatercustomize.h.

Referenced by LLFloaterCustomize(), and ~LLFloaterCustomize().

void(* LLFloaterCustomize::mNextStepAfterSaveAllCallback)(BOOL proceed, void *userdata) [protected]

Referenced by askToSaveAllIfDirty().

void* LLFloaterCustomize::mNextStepAfterSaveAllUserdata [protected]

Definition at line 138 of file llfloatercustomize.h.

Referenced by askToSaveAllIfDirty().

LLVisualParamReset* LLFloaterCustomize::mResetParams [protected]

Definition at line 133 of file llfloatercustomize.h.

Referenced by LLFloaterCustomize(), and ~LLFloaterCustomize().

LLScrollableContainerView* LLFloaterCustomize::mScrollContainer [protected]

Definition at line 131 of file llfloatercustomize.h.

LLScrollingPanelList* LLFloaterCustomize::mScrollingPanelList [protected]

Definition at line 130 of file llfloatercustomize.h.

Referenced by clearScrollingPanelList(), generateVisualParamHints(), initScrollingPanelList(), and updateScrollingPanelList().

LLPanelEditWearable* LLFloaterCustomize::mWearablePanelList[WT_COUNT] [protected]

Definition at line 126 of file llfloatercustomize.h.

Referenced by createWearablePanel(), getCurrentWearablePanel(), initWearablePanels(), isDirty(), setCurrentWearableType(), setWearable(), updateInventoryUI(), and updateScrollingPanelUI().

EWearableType LLFloaterCustomize::sCurrentWearableType = WT_SHAPE [static, protected]

Definition at line 128 of file llfloatercustomize.h.

Referenced by getCurrentWearablePanel(), getCurrentWearableType(), updateInventoryUI(), and updateScrollingPanelUI().


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