fix crash when double-clicking animation in a different state than active state
parent
c5521b404a
commit
664f8178ac
|
|
@ -798,6 +798,12 @@ void FloaterAO::onDoubleClick()
|
|||
return;
|
||||
}
|
||||
|
||||
// do nothing if animation is for a different state than the active state
|
||||
if (mSelectedState != AOEngine::instance().getCurrentState())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// activate AO set if necessary
|
||||
if (AOEngine::instance().getCurrentSet() != mSelectedSet)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1063,6 +1063,10 @@ const AOSet* AOEngine::getCurrentSet() const
|
|||
{
|
||||
return mCurrentSet;
|
||||
}
|
||||
const AOSet::AOState* AOEngine::getCurrentState() const
|
||||
{
|
||||
return mCurrentSet->getStateByRemapID(mLastMotion);
|
||||
}
|
||||
// </AS:Chanayane>
|
||||
|
||||
void AOEngine::updateSortOrder(AOSet::AOState* state)
|
||||
|
|
|
|||
|
|
@ -126,6 +126,7 @@ class AOEngine
|
|||
// <AS:Chanayane> Double click on animation in AO
|
||||
void playAnimation(const LLUUID& animation);
|
||||
const AOSet* getCurrentSet() const;
|
||||
const AOSet::AOState* getCurrentState() const;
|
||||
// </AS:Chanayane>
|
||||
|
||||
void inMouselook(bool mouselook);
|
||||
|
|
|
|||
Loading…
Reference in New Issue