diff options
author | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2011-07-15 14:10:38 -0400 |
---|---|---|
committer | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2011-07-15 14:10:38 -0400 |
commit | 0e2291535298ca90ae994ce8e2e56836aaa707bc (patch) | |
tree | 407a616bd39719ace97200eecec097512899d5ec | |
parent | fde88ae24d1093fd0f24fe9cfd66dc05a0d1c51f (diff) | |
parent | a89c58f01bac2bc0bafc69dc31eb6071b6ef8829 (diff) |
merge
-rw-r--r-- | indra/newview/llagent.cpp | 5 | ||||
-rwxr-xr-x | indra/newview/llfloatermodelpreview.cpp | 44 | ||||
-rw-r--r-- | indra/newview/llfloatermodelpreview.h | 3 |
3 files changed, 17 insertions, 35 deletions
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index 8954937f69..492cfe7c1b 100644 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -577,7 +577,10 @@ void LLAgent::setFlying(BOOL fly) // static void LLAgent::toggleFlying() { - LLToolPie::instance().stopClickToWalk(); + if ( gAgent.mAutoPilot ) + { + LLToolPie::instance().stopClickToWalk(); + } BOOL fly = !gAgent.getFlying(); diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp index ef846ec42e..203be5bb1f 100755 --- a/indra/newview/llfloatermodelpreview.cpp +++ b/indra/newview/llfloatermodelpreview.cpp @@ -1385,6 +1385,8 @@ bool LLModelLoader::doLoadModel() if (!dom) { + llinfos<<" Error with dae - traditionally indicates a corrupt file."<<llendl; + setLoadState( ERROR_PARSING ); return false; } @@ -2185,15 +2187,11 @@ void LLModelPreview::critiqueRigForUploadApplicability( const std::vector<std::s setRigValidForJointPositionUpload( true ); } - if ( isRigLegacyOK ) - { + if ( isRigLegacyOK) + { setLegacyRigValid( true ); } - if ( getRigWithSceneParity() && isJointPositionUploadOK ) - { - setResetJointFlag( true ); - } } //----------------------------------------------------------------------------- // critiqueJointToNodeMappingFromScene() @@ -2233,12 +2231,7 @@ void LLModelPreview::critiqueJointToNodeMappingFromScene( void ) //2. Partial rig but w/o parity between the scene and joint array if ( result ) { - setResetJointFlag( true ); setRigWithSceneParity( true ); - } - else - { - setResetJointFlag( false ); } } //----------------------------------------------------------------------------- @@ -2996,13 +2989,7 @@ U32 LLModelPreview::calcResourceCost() if ( uploadingJointPositions && !isRigValidForJointPositionUpload() ) { mFMP->childDisable("ok_btn"); - } - else - if ( !isLegacyRigValid() ) - { - mFMP->childDisable("ok_btn"); - } - //ok_btn should not have been changed unless something was wrong with joint list + } } std::set<LLModel*> accounted; @@ -3343,6 +3330,7 @@ void LLModelPreview::loadModel(std::string filename, S32 lod, bool force_disable if ( getLoadState() >= LLModelLoader::ERROR_PARSING ) { mFMP->childDisable("ok_btn"); + mFMP->childDisable( "calculate_btn" ); } if (lod == mPreviewLOD) @@ -4213,12 +4201,7 @@ void LLModelPreview::updateStatusMessages() if ( uploadingJointPositions && !isRigValidForJointPositionUpload() ) { skinAndRigOk = false; - } - else - if ( !isLegacyRigValid() ) - { - skinAndRigOk = false; - } + } } if(upload_ok && mModelLoader) @@ -4814,8 +4797,12 @@ BOOL LLModelPreview::render() mFMP->childSetValue("upload_joints", false); upload_joints = false; } - - mFMP->childSetEnabled("upload_joints", upload_skin); + + //Only enable joint offsets if it passed the earlier critiquing + if ( isRigValidForJointPositionUpload() ) + { + mFMP->childSetEnabled("upload_joints", upload_skin); + } F32 explode = mFMP->childGetValue("physics_explode").asReal(); @@ -5475,11 +5462,6 @@ void LLFloaterModelPreview::toggleCalculateButton(bool visible) { mCalculateBtn->setVisible( false ); } - else - if ( !mModelPreview->isLegacyRigValid() ) - { - mCalculateBtn->setVisible( false ); - } } mUploadBtn->setVisible(!visible); diff --git a/indra/newview/llfloatermodelpreview.h b/indra/newview/llfloatermodelpreview.h index 3a5f7602fe..c24e171024 100644 --- a/indra/newview/llfloatermodelpreview.h +++ b/indra/newview/llfloatermodelpreview.h @@ -365,9 +365,6 @@ public: void setLoadState( U32 state ) { mLoadState = state; } U32 getLoadState() { return mLoadState; } - //setRestJointFlag: If an asset comes through that changes the joints, we want the reset to persist - void setResetJointFlag( bool state ) { if ( !mResetJoints ) mResetJoints = state; } - const bool getResetJointFlag( void ) const { return mResetJoints; } void setRigWithSceneParity( bool state ) { mRigParityWithScene = state; } const bool getRigWithSceneParity( void ) const { return mRigParityWithScene; } |