#include <llgesturemgr.h>
Collaboration diagram for LLGestureManager:
Definition at line 54 of file llgesturemgr.h.
typedef std::map<LLUUID, LLMultiGesture*> LLGestureManager::item_map_t |
Definition at line 146 of file llgesturemgr.h.
LLGestureManager::LLGestureManager | ( | ) |
Definition at line 68 of file llgesturemgr.cpp.
LLGestureManager::~LLGestureManager | ( | ) |
Definition at line 98 of file llgesturemgr.cpp.
References activateGestureWithAsset(), FALSE, LLInventoryItem::getAssetUUID(), LLInventoryModel::getItem(), gInventory, mDeactivateSimilarNames, mLoadingCount, and TRUE.
Referenced by activateGestures(), LLToolDragAndDrop::dad3dActivateGesture(), ActivateGestureCallback::fire(), LLPreviewGesture::onCommitActive(), and LLGestureBridge::performAction().
void LLGestureManager::activateGestures | ( | LLViewerInventoryItem::item_array_t & | items | ) |
Definition at line 114 of file llgesturemgr.cpp.
References activateGesture(), activateGestureWithAsset(), count, FALSE, gAgent, LLAgent::getID(), LLAgent::getSessionID(), gMessageSystem, isGestureActive(), mDeactivateSimilarNames, mLoadingCount, MTUBYTES, S32, LLAgent::sendReliableMessage(), and TRUE.
Referenced by wear_inventory_category_on_avatar_step2().
void LLGestureManager::activateGestureWithAsset | ( | const LLUUID & | item_id, | |
const LLUUID & | asset_id, | |||
BOOL | inform_server, | |||
BOOL | deactivate_similar | |||
) |
Definition at line 207 of file llgesturemgr.cpp.
References LLAssetType::AT_GESTURE, gAssetStorage, LLAssetStorage::getAssetData(), isGestureActive(), llendl, llwarns, mActive, notifyObservers(), LLUUID::notNull(), NULL, onLoadComplete(), and TRUE.
Referenced by activateGesture(), activateGestures(), and idle_startup().
void LLGestureManager::addObserver | ( | LLGestureManagerObserver * | observer | ) |
Definition at line 1079 of file llgesturemgr.cpp.
References mObservers.
Referenced by LLFloaterGesture::LLFloaterGesture(), and LLChatBar::setGestureCombo().
Definition at line 256 of file llgesturemgr.cpp.
References LLInventoryModel::addChangedMask(), LLMessageSystem::addU32(), LLMessageSystem::addUUID(), gAgent, LLAgent::getID(), LLAgent::getSessionID(), gInventory, gMessageSystem, LLInventoryObserver::LABEL, llendl, llwarns, mActive, LLMessageSystem::newMessage(), LLMessageSystem::nextBlock(), notifyObservers(), NULL, LLAgent::sendReliableMessage(), and stopGesture().
Referenced by LLFolderBridge::dragCategoryIntoFolder(), LLFolderBridge::dragItemIntoFolder(), LLPreviewGesture::onCommitActive(), LLGestureBridge::performAction(), remove_inventory_category_from_avatar_step2(), LLGestureBridge::removeItem(), and LLFolderBridge::removeItem().
void LLGestureManager::deactivateSimilarGestures | ( | LLMultiGesture * | gesture, | |
const LLUUID & | in_item_id | |||
) |
Definition at line 298 of file llgesturemgr.cpp.
References LLInventoryModel::addChangedMask(), LLMessageSystem::addU32(), LLMessageSystem::addUUID(), FALSE, gAgent, LLMessageSystem::getCurrentSendTotal(), LLAgent::getID(), LLInventoryModel::getItem(), LLAgent::getSessionID(), gInventory, gMessageSystem, KEY_NONE, LLInventoryObserver::LABEL, mActive, mDeactivateSimilarNames, LLMultiGesture::mKey, LLMultiGesture::mMask, LLMultiGesture::mTrigger, MTUBYTES, LLMessageSystem::newMessage(), LLMessageSystem::nextBlock(), notifyObservers(), NULL, LLAgent::sendReliableMessage(), stopGesture(), and TRUE.
Referenced by onLoadComplete().
S32 LLGestureManager::getPlayingCount | ( | ) | const |
void LLGestureManager::init | ( | ) |
Definition at line 90 of file llgesturemgr.cpp.
Definition at line 384 of file llgesturemgr.cpp.
References mActive.
Referenced by activateGestures(), activateGestureWithAsset(), LLFolderBridge::dragCategoryIntoFolder(), LLFolderBridge::dragItemIntoFolder(), LLGestureBridge::getLabelStyle(), LLGestureBridge::getLabelSuffix(), LLPreviewGesture::onCommitActive(), LLPreviewGesture::refresh(), remove_inventory_category_from_avatar_step2(), LLFolderBridge::removeItem(), LLPreviewGesture::saveIfNeeded(), and LLUpdateAgentInventoryResponder::uploadComplete().
Definition at line 391 of file llgesturemgr.cpp.
References FALSE, mActive, and LLMultiGesture::mPlaying.
Referenced by LLFloaterGesture::onClickPlay(), and LLFloaterGesture::onCommitList().
BOOL LLGestureManager::matchPrefix | ( | const std::string & | in_str, | |
std::string * | out_str | |||
) |
Definition at line 1111 of file llgesturemgr.cpp.
References LLStringBase< char >::compareInsensitive(), FALSE, mActive, S32, TRUE, and LLStringBase< char >::truncate().
Referenced by LLChatBar::onInputEditorKeystroke().
void LLGestureManager::notifyObservers | ( | ) |
Definition at line 1097 of file llgesturemgr.cpp.
References lldebugs, llendl, and mObservers.
Referenced by activateGestureWithAsset(), deactivateGesture(), deactivateSimilarGestures(), onLoadComplete(), playGesture(), replaceGesture(), stopGesture(), and update().
void LLGestureManager::onLoadComplete | ( | LLVFS * | vfs, | |
const LLUUID & | asset_uuid, | |||
LLAssetType::EType | type, | |||
void * | user_data, | |||
S32 | status, | |||
LLExtStat | ext_status | |||
) | [static, protected] |
Definition at line 913 of file llgesturemgr.cpp.
References LLInventoryModel::addChangedMask(), LLMessageSystem::addU32(), LLMessageSystem::addUUID(), deactivateSimilarGestures(), LLMultiGesture::deserialize(), gAgent, LLAgent::getID(), LLAgent::getSessionID(), LLVFile::getSize(), gGestureManager, gInventory, gMessageSystem, gViewerStats, LLViewerStats::incStat(), LLInventoryObserver::LABEL, LL_ERR_ASSET_REQUEST_NOT_IN_DATABASE, LL_ERR_FILE_EMPTY, llendl, llerrs, llwarns, mActive, LLLoadInfo::mDeactivateSimilar, mDeactivateSimilarNames, LLLoadInfo::mInformServer, LLLoadInfo::mItemID, mLoadingCount, LLMessageSystem::newMessage(), LLMessageSystem::nextBlock(), notifyObservers(), NULL, LLVFile::read(), LLVFile::READ, S32, LLAgent::sendReliableMessage(), LLNotifyBox::showXml(), size, and LLViewerStats::ST_DOWNLOAD_FAILED.
Referenced by activateGestureWithAsset(), and replaceGesture().
void LLGestureManager::playGesture | ( | LLMultiGesture * | gesture | ) |
Definition at line 456 of file llgesturemgr.cpp.
References LLMultiGesture::mCurrentStep, mPlaying, LLMultiGesture::mPlaying, notifyObservers(), stepGesture(), and TRUE.
Referenced by LLFloaterGesture::onClickPlay(), LLPreviewGesture::onClickPreview(), playGesture(), triggerAndReviseString(), and triggerGesture().
void LLGestureManager::removeObserver | ( | LLGestureManagerObserver * | observer | ) |
Definition at line 1084 of file llgesturemgr.cpp.
References mObservers.
Referenced by LLFloaterGesture::~LLFloaterGesture().
Definition at line 442 of file llgesturemgr.cpp.
References gGestureManager, llendl, llwarns, mActive, and replaceGesture().
void LLGestureManager::replaceGesture | ( | const LLUUID & | item_id, | |
LLMultiGesture * | new_gesture, | |||
const LLUUID & | asset_id | |||
) |
Definition at line 402 of file llgesturemgr.cpp.
References LLAssetType::AT_GESTURE, FALSE, gAssetStorage, LLAssetStorage::getAssetData(), llendl, llwarns, mActive, LLLoadInfo::mDeactivateSimilar, mDeactivateSimilarNames, LLLoadInfo::mInformServer, LLLoadInfo::mItemID, mLoadingCount, notifyObservers(), LLUUID::notNull(), NULL, onLoadComplete(), stopGesture(), and TRUE.
Referenced by replaceGesture(), LLPreviewGesture::saveIfNeeded(), and LLUpdateAgentInventoryResponder::uploadComplete().
void LLGestureManager::runStep | ( | LLMultiGesture * | gesture, | |
LLGestureStep * | step | |||
) | [protected] |
Definition at line 828 of file llgesturemgr.cpp.
References ANIM_FLAG_STOP, ANIM_REQUEST_START, ANIM_REQUEST_STOP, CHAT_TYPE_NORMAL, FALSE, gAgent, gChatBar, LLGestureStep::getType(), LLGestureStepChat::mChatText, LLMultiGesture::mCurrentStep, LLGestureStepWait::mFlags, LLMultiGesture::mRequestedAnimIDs, LLGestureStepSound::mSoundAssetID, LLMultiGesture::mWaitingAnimations, LLMultiGesture::mWaitingTimer, LLMultiGesture::mWaitTimer, LLFrameTimer::reset(), send_sound_trigger(), LLAgent::sendAnimationRequest(), LLChatBar::sendChatFromViewer(), STEP_ANIMATION, STEP_CHAT, STEP_SOUND, STEP_WAIT, TRUE, WAIT_FLAG_ALL_ANIM, and WAIT_FLAG_TIME.
Referenced by stepGesture().
void LLGestureManager::stepGesture | ( | LLMultiGesture * | gesture | ) | [protected] |
Definition at line 680 of file llgesturemgr.cpp.
References FALSE, gAgent, LLAgent::getAvatarObject(), LLFrameTimer::getElapsedTimeF32(), llassert, llendl, llinfos, MAX_WAIT_ANIM_SECS, LLMultiGesture::mCurrentStep, LLMultiGesture::mPlaying, LLMultiGesture::mPlayingAnimIDs, LLMultiGesture::mRequestedAnimIDs, LLVOAvatar::mSignaledAnimations, LLMultiGesture::mSteps, LLMultiGesture::mWaitingAnimations, LLMultiGesture::mWaitingAtEnd, LLMultiGesture::mWaitingTimer, LLGestureStepWait::mWaitSeconds, LLMultiGesture::mWaitTimer, NULL, runStep(), S32, and TRUE.
Referenced by playGesture(), and update().
void LLGestureManager::stopGesture | ( | LLMultiGesture * | gesture | ) |
Definition at line 1027 of file llgesturemgr.cpp.
References ANIM_REQUEST_STOP, gAgent, LLMultiGesture::mCallbackData, LLMultiGesture::mDoneCallback, mPlaying, LLMultiGesture::mPlayingAnimIDs, LLMultiGesture::mRequestedAnimIDs, notifyObservers(), NULL, LLMultiGesture::reset(), and LLAgent::sendAnimationRequest().
Referenced by deactivateGesture(), deactivateSimilarGestures(), LLPreviewGesture::handleSaveChangesDialog(), LLFloaterGesture::onClickPlay(), LLPreviewGesture::onClickPreview(), LLPreviewGesture::onClose(), replaceGesture(), and stopGesture().
BOOL LLGestureManager::triggerAndReviseString | ( | const std::string & | str, | |
std::string * | revised_string = NULL | |||
) |
Definition at line 490 of file llgesturemgr.cpp.
References FALSE, ll_rand(), mActive, LLMultiGesture::mReplaceText, LLMultiGesture::mTrigger, NULL, playGesture(), S32, LLStringBase< char >::toLower(), and TRUE.
Referenced by LLVOAvatar::idleUpdate(), LLChatBar::onCommitGesture(), and LLChatBar::sendChat().
Definition at line 589 of file llgesturemgr.cpp.
References FALSE, ll_rand(), mActive, playGesture(), and TRUE.
Referenced by LLViewerWindow::handleKey().
void LLGestureManager::update | ( | ) |
Definition at line 637 of file llgesturemgr.cpp.
References i, mPlaying, notifyObservers(), NULL, S32, and stepGesture().
Referenced by idle().
Definition at line 152 of file llgesturemgr.h.
Referenced by activateGestureWithAsset(), LLFloaterGesture::buildGestureList(), deactivateGesture(), deactivateSimilarGestures(), getItemIDs(), isGestureActive(), isGesturePlaying(), matchPrefix(), onLoadComplete(), playGesture(), LLChatBar::refreshGestures(), replaceGesture(), stopGesture(), triggerAndReviseString(), triggerGesture(), and ~LLGestureManager().
std::string LLGestureManager::mDeactivateSimilarNames |
Definition at line 155 of file llgesturemgr.h.
Referenced by activateGesture(), activateGestures(), deactivateSimilarGestures(), onLoadComplete(), and replaceGesture().
Definition at line 154 of file llgesturemgr.h.
Referenced by activateGesture(), activateGestures(), onLoadComplete(), and replaceGesture().
std::vector<LLGestureManagerObserver*> LLGestureManager::mObservers |
Definition at line 157 of file llgesturemgr.h.
Referenced by addObserver(), notifyObservers(), and removeObserver().
std::vector<LLMultiGesture*> LLGestureManager::mPlaying |
Definition at line 143 of file llgesturemgr.h.
Referenced by getPlayingCount(), playGesture(), stopGesture(), and update().
Definition at line 142 of file llgesturemgr.h.