Save some frames from updating export info when llselectmgr signals change but we have the same object selected
parent
2b02fc2a57
commit
4e1f7ce4e8
|
|
@ -108,6 +108,7 @@ namespace DAEExportUtil
|
|||
|
||||
ColladaExportFloater::ColladaExportFloater(const LLSD& key)
|
||||
: LLFloater(key),
|
||||
mCurrentObjectID(NULL),
|
||||
mDirty(true)
|
||||
{
|
||||
mCommitCallbackRegistrar.add("ColladaExport.TextureExport", boost::bind(&ColladaExportFloater::onTextureExportCheck, this));
|
||||
|
|
@ -250,6 +251,7 @@ void ColladaExportFloater::addSelectedObjects()
|
|||
LLSelectNode* node = mObjectSelection->getFirstRootNode();
|
||||
if (node)
|
||||
{
|
||||
mCurrentObjectID = node->getObject()->getID();
|
||||
mSaver.mOffset = -mObjectSelection->getFirstRootObject()->getRenderPosition();
|
||||
mObjectName = node->mName;
|
||||
|
||||
|
|
@ -280,7 +282,15 @@ void ColladaExportFloater::addSelectedObjects()
|
|||
|
||||
void ColladaExportFloater::updateSelection()
|
||||
{
|
||||
mObjectSelection = LLSelectMgr::getInstance()->getSelection();
|
||||
LLObjectSelectionHandle object_selection = LLSelectMgr::getInstance()->getSelection();
|
||||
LLSelectNode* node = object_selection->getFirstRootNode();
|
||||
|
||||
if (node && !node->mValid && node->getObject()->getID() == mCurrentObjectID)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
mObjectSelection = object_selection;
|
||||
dirty();
|
||||
refresh();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -148,6 +148,7 @@ private:
|
|||
std::string mObjectName;
|
||||
LLUIString mTitleProgress;
|
||||
LLPanel* mTexturePanel;
|
||||
LLUUID mCurrentObjectID;
|
||||
bool mDirty;
|
||||
|
||||
class CacheReadResponder : public LLTextureCache::ReadResponder
|
||||
|
|
|
|||
|
|
@ -196,6 +196,7 @@ void FSFloaterObjectExport::onIdle()
|
|||
|
||||
FSFloaterObjectExport::FSFloaterObjectExport(const LLSD& key)
|
||||
: LLFloater(key),
|
||||
mCurrentObjectID(NULL),
|
||||
mDirty(true)
|
||||
{
|
||||
}
|
||||
|
|
@ -257,8 +258,16 @@ void FSFloaterObjectExport::onOpen(const LLSD& key)
|
|||
void FSFloaterObjectExport::updateSelection()
|
||||
{
|
||||
LLObjectSelectionHandle object_selection = LLSelectMgr::getInstance()->getSelection();
|
||||
LLSelectNode* node = object_selection->getFirstRootNode();
|
||||
|
||||
if (node && !node->mValid && node->getObject()->getID() == mCurrentObjectID)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
mObjectSelection = object_selection;
|
||||
dirty();
|
||||
refresh();
|
||||
}
|
||||
|
||||
bool FSFloaterObjectExport::exportSelection()
|
||||
|
|
@ -1145,6 +1154,7 @@ void FSFloaterObjectExport::addSelectedObjects()
|
|||
LLSelectNode* node = mObjectSelection->getFirstRootNode();
|
||||
if (node)
|
||||
{
|
||||
mCurrentObjectID = node->getObject()->getID();
|
||||
mObjectName = node->mName;
|
||||
for (LLObjectSelection::iterator iter = mObjectSelection->begin(); iter != mObjectSelection->end(); ++iter)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -98,6 +98,7 @@ private:
|
|||
obj_info_t mObjects;
|
||||
std::string mFilename;
|
||||
LLSafeHandle<LLObjectSelection> mObjectSelection;
|
||||
LLUUID mCurrentObjectID;
|
||||
|
||||
S32 mTotal;
|
||||
S32 mIncluded;
|
||||
|
|
|
|||
Loading…
Reference in New Issue