diff options
author | Richard Nelson <richard@lindenlab.com> | 2007-02-24 01:47:17 +0000 |
---|---|---|
committer | Richard Nelson <richard@lindenlab.com> | 2007-02-24 01:47:17 +0000 |
commit | 663fff7c3f969c1435417d2a700d06ebaf744f1b (patch) | |
tree | 719500cb73231e93a4941f34db743142c384e76d /indra/newview/llselectmgr.cpp | |
parent | bb2b96d6c34974c9bf4a57a277e6ff182e8d137d (diff) |
svn merge -r 58007:58273 svn+ssh://svn.lindenlab.com/svn/linden/branches/maintenance
Diffstat (limited to 'indra/newview/llselectmgr.cpp')
-rw-r--r-- | indra/newview/llselectmgr.cpp | 39 |
1 files changed, 16 insertions, 23 deletions
diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index b1c6ea7213..078132b99f 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -1272,39 +1272,32 @@ void LLSelectMgr::selectionSetImage(const LLUUID& imageid) LLViewerObject* objectp; S32 te; - // Apply the texture to each side - for (mSelectedObjects->getFirstTE(&objectp, &te); objectp; mSelectedObjects->getNextTE(&objectp, &te)) + mSelectedObjects->getFirstTE(&objectp, &te); + + for (objectp = mSelectedObjects->getFirstObject(); objectp; objectp = mSelectedObjects->getNextObject()) { - if (item) { - LLToolDragAndDrop::dropTextureOneFace(objectp,te,item,LLToolDragAndDrop::SOURCE_AGENT,LLUUID::null); - - // HACK! HACK! ARG! - // *TODO: Replace mSelectedObjects with a REAL container class! - LLViewerObject* tmp_object; - S32 tmp_te; - mSelectedObjects->getCurrentTE(&tmp_object,&tmp_te); - if ((tmp_object != objectp) || (tmp_te != te) ) - { - //AAARG someone has moved our list around! - mSelectedObjects->getFirstTE(&tmp_object, &tmp_te); - while ((tmp_object != objectp) || (tmp_te != te)) - { - mSelectedObjects->getNextTE(&tmp_object, &tmp_te); - } - } + LLToolDragAndDrop::dropTextureAllFaces(objectp, + item, + LLToolDragAndDrop::SOURCE_AGENT, + LLUUID::null); } else { - // Texture picker defaults aren't inventory items - // * Don't need to worry about permissions for them - // * Can just apply the texture and be done with it. - objectp->setTEImage(te, gImageList.getImage(imageid)); + S32 num_faces = objectp->getNumTEs(); + for( S32 face = 0; face < num_faces; face++ ) + { + // Texture picker defaults aren't inventory items + // * Don't need to worry about permissions for them + // * Can just apply the texture and be done with it. + objectp->setTEImage(face, gImageList.getImage(imageid)); + } objectp->sendTEUpdate(); } } + // 1 particle effect per object if (mSelectedObjects->mSelectType != SELECT_TYPE_HUD) { |