diff options
author | Steven Bennetts <steve@lindenlab.com> | 2007-03-16 20:39:40 +0000 |
---|---|---|
committer | Steven Bennetts <steve@lindenlab.com> | 2007-03-16 20:39:40 +0000 |
commit | 5e9e67cb2d1d3dfc82dfe96103270b2341991ddd (patch) | |
tree | 2df2a064523b2bffef6ff7566399c76b1f2cc196 /indra/newview | |
parent | 1ada34fc0c5dc20bffba231ef513b569dbec32ea (diff) |
merge -r 59028:59178 maintenance -> release.
Diffstat (limited to 'indra/newview')
23 files changed, 339 insertions, 202 deletions
diff --git a/indra/newview/app_settings/keywords.ini b/indra/newview/app_settings/keywords.ini index 0545c38959..bf49c2c5d5 100644 --- a/indra/newview/app_settings/keywords.ini +++ b/indra/newview/app_settings/keywords.ini @@ -468,6 +468,10 @@ PARCEL_DETAILS_OWNER Used with llGetParcelDetails to get the parcel owner id. PARCEL_DETAILS_GROUP Used with llGetParcelDetails to get the parcel group id. PARCEL_DETAILS_AREA Used with llGetParcelDetails to get the parcel area in square meters. +STRING_TRIM_HEAD Used with llStringTrim to trim leading spaces from a string. +STRING_TRIM_TAIL Used with llStringTrim to trim trailing spaces from a string. +STRING_TRIM Used with llStringTrim to trim both leading and trailing spaces from a string. + # string constants [word .1, .3, .5] NULL_KEY Indicates an empty key diff --git a/indra/newview/app_settings/viewerart.xml b/indra/newview/app_settings/viewerart.xml index 1ae2010002..d56efeae09 100644 --- a/indra/newview/app_settings/viewerart.xml +++ b/indra/newview/app_settings/viewerart.xml @@ -113,4 +113,4 @@ <avatar_yes_happy.bvh value="b8c8b2a3-9008-1771-3bfc-90924955ab2d"/> <avatar_yes_head.bvh value="15dd911d-be82-2856-26db-27659b142875"/> <avatar_yoga_float.bvh value="42ecd00b-9947-a97c-400a-bbc9174c7aeb"/> -</settings> +</settings>
\ No newline at end of file diff --git a/indra/newview/linux_tools/client-readme.txt b/indra/newview/linux_tools/client-readme.txt index 42d7eff0dd..7c972bb8d1 100644 --- a/indra/newview/linux_tools/client-readme.txt +++ b/indra/newview/linux_tools/client-readme.txt @@ -71,27 +71,31 @@ you wish. 4. KNOWN ISSUES -=-=-=-=-=-=-=- -The following user-visible features are currently not fully implemented on -the Linux client and are therefore known not to work properly: +These are the most commonly-encountered known issues which are specific to +the Alpha release of the Linux client. + +* VISUAL EFFECTS AND PERFORMANCE - many Linux graphics drivers are not as + robust as their counterparts for other operating systems, so some advanced + Second Life graphical features have been DISABLED by default to aid + stability. See PROBLEM 3 in the TROUBLESHOOTING section if you wish to + turn these on to possibly enhance your experience. + +* MISC - The following user-visible features are not currently fully + implemented on the Linux client and are therefore known not to work properly + at this time: * QuickTime movie playback and movie recording * Video memory detection * Full Unicode font rendering * Auto-updater +* UPLOAD / SAVE / COLOR-PICKER DIALOGS - These only appear when the client + is in 'windowed' mode, not 'fullscreen' mode. + * UPDATING - when the client detects that a new version of Second Life is available, it will ask you if you wish to download the new version. This option is not implemented; to upgrade, you should manually download a new version from the Second Life web site, <http://www.secondlife.com/>. -* UPLOAD / SAVE / COLOR-PICKER DIALOGS - These only function when the client - is in 'windowed' mode, not 'fullscreen' mode. - -* GRAPHICAL SPEED/QUALITY - as many Linux graphics drivers are not as robust - as their counterparts for some other operating systems, advanced Second Life - graphical features have been disabled to aid stability. See PROBLEM 3 in the - TROUBLESHOOTING section if you wish to turn these on to enhance your - experience. - 5. TROUBLESHOOTING -=-=-=-=-=-=-=-=-= @@ -130,8 +134,8 @@ SOLUTION:- As a last resort, you can disable most of Second Life's advanced from the line which reads '#export LL_GL_NOEXT=x' PROBLEM 3:- Performance or graphical quality are not as high as I expect. +PROBLEM:- 'SHINY' doesn't work. PROBLEM:- I can't turn on Anisotropic Filtering, Ripple Water, or AGP. -PROBLEM:- 'Shiny' doesn't work. SOLUTION:- Some graphics performance features in Second Life are disabled by default for the Linux version due to stability issues with some common Linux graphic drivers. You can re-enable these features at the slight diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index 07daf89f1c..c0ad9ffb03 100644 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -4649,14 +4649,26 @@ void LLAgent::requestStopMotion( LLMotion* motion ) // Notify all avatars that a motion has stopped. // This is needed to clear the animation state bits LLUUID anim_state = motion->getID(); + onAnimStop(motion->getID()); // if motion is not looping, it could have stopped by running out of time // so we need to tell the server this // llinfos << "Sending stop for motion " << motion->getName() << llendl; sendAnimationRequest( anim_state, ANIM_REQUEST_STOP ); +} +void LLAgent::onAnimStop(const LLUUID& id) +{ // handle automatic state transitions (based on completion of animation playback) - if (anim_state == ANIM_AGENT_STANDUP) + if (id == ANIM_AGENT_STAND) + { + stopFidget(); + } + else if (id == ANIM_AGENT_AWAY) + { + clearAFK(); + } + else if (id == ANIM_AGENT_STANDUP) { // send stand up command setControlFlags(AGENT_CONTROL_FINISH_ANIM); @@ -4665,7 +4677,7 @@ void LLAgent::requestStopMotion( LLMotion* motion ) if (mAvatarObject.notNull() && !mAvatarObject->mBelowWater && rand() % 3 == 0) sendAnimationRequest( ANIM_AGENT_BRUSH, ANIM_REQUEST_START ); } - else if (anim_state == ANIM_AGENT_PRE_JUMP || anim_state == ANIM_AGENT_LAND || anim_state == ANIM_AGENT_MEDIUM_LAND) + else if (id == ANIM_AGENT_PRE_JUMP || id == ANIM_AGENT_LAND || id == ANIM_AGENT_MEDIUM_LAND) { setControlFlags(AGENT_CONTROL_FINISH_ANIM); } diff --git a/indra/newview/llagent.h b/indra/newview/llagent.h index a8e4d2f0b4..b86dc03807 100644 --- a/indra/newview/llagent.h +++ b/indra/newview/llagent.h @@ -331,6 +331,7 @@ public: // Animation functions void requestStopMotion( LLMotion* motion ); + void onAnimStop(const LLUUID& id); void sendAnimationRequests(LLDynamicArray<LLUUID> &anim_ids, EAnimRequest request); void sendAnimationRequest(const LLUUID &anim_id, EAnimRequest request); diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp index bb76957da1..6c00874982 100644 --- a/indra/newview/llface.cpp +++ b/indra/newview/llface.cpp @@ -944,19 +944,26 @@ BOOL LLFace::getGeometryVolume(const LLVolume& volume, { LLVOVolume* vobj = (LLVOVolume*) (LLViewerObject*) mVObjp; U8 mode = vobj->mTexAnimMode; - if (mode & LLViewerTextureAnim::TRANSLATE) + if (!mode) { - os = ot = 0.f; + clearState(TEXTURE_ANIM); } - if (mode & LLViewerTextureAnim::ROTATE) - { - r = 0.f; - cos_ang = 1.f; - sin_ang = 0.f; - } - if (mode & LLViewerTextureAnim::SCALE) + else { - ms = mt = 1.f; + if (mode & LLViewerTextureAnim::TRANSLATE) + { + os = ot = 0.f; + } + if (mode & LLViewerTextureAnim::ROTATE) + { + r = 0.f; + cos_ang = 1.f; + sin_ang = 0.f; + } + if (mode & LLViewerTextureAnim::SCALE) + { + ms = mt = 1.f; + } } } diff --git a/indra/newview/llfloatertos.cpp b/indra/newview/llfloatertos.cpp index c178d0d416..f7bf4de34f 100644 --- a/indra/newview/llfloatertos.cpp +++ b/indra/newview/llfloatertos.cpp @@ -106,9 +106,9 @@ BOOL LLFloaterTOS::postBuild() childSetAction("Cancel", onCancel, this); childSetCommitCallback("tos_agreement", updateAgree, this); - // this displays the critical message if ( mType != TOS_TOS ) { + // this displays the critical message LLTextEditor *Editor = LLUICtrlFactory::getTextEditorByName(this, "tos_text"); if (Editor) { @@ -118,25 +118,11 @@ BOOL LLFloaterTOS::postBuild() Editor->setWordWrap(TRUE); Editor->setFocus(TRUE); } - childSetValue("tos_text", LLSD(mMessage)); - }; - - // this displays the critical message - if ( mType != TOS_TOS ) - { - LLTextEditor *Editor = LLUICtrlFactory::getTextEditorByName(this, "tos_text"); - if (Editor) - { - Editor->setHandleEditKeysDirectly( TRUE ); - Editor->setEnabled( FALSE ); - Editor->setReadOnlyFgColor(LLColor4::white); - Editor->setWordWrap(TRUE); - Editor->setFocus(TRUE); - } - childSetValue("tos_text", LLSD(mMessage)); - }; + childSetValue("tos_text", LLSD(mMessage)); + return TRUE; + } - #if LL_LIBXUL_ENABLED +#if LL_LIBXUL_ENABLED // disable Agree to TOS radio button until the page has fully loaded LLRadioGroup* tos_agreement = LLUICtrlFactory::getRadioGroupByName(this, "tos_agreement"); if ( tos_agreement ) @@ -163,7 +149,18 @@ BOOL LLFloaterTOS::postBuild() gResponsePtr = LLIamHere::build( this ); LLHTTPClient::get( childGetValue( "real_url" ).asString(), gResponsePtr ); }; - #endif +#else + LLTextEditor *Editor = LLUICtrlFactory::getTextEditorByName(this, "tos_text"); + if (Editor) + { + Editor->setHandleEditKeysDirectly( TRUE ); + Editor->setEnabled( FALSE ); + Editor->setReadOnlyFgColor(LLColor4::white); + Editor->setWordWrap(TRUE); + Editor->setFocus(TRUE); + } + childSetValue("tos_text", LLSD(mMessage)); +#endif return TRUE; } diff --git a/indra/newview/llfloaterworldmap.cpp b/indra/newview/llfloaterworldmap.cpp index a39c2be6bf..d8ed27173d 100644 --- a/indra/newview/llfloaterworldmap.cpp +++ b/indra/newview/llfloaterworldmap.cpp @@ -439,6 +439,14 @@ void LLFloaterWorldMap::draw() return; } + // On orientation island, users don't have a home location yet, so don't + // let them teleport "home". It dumps them in an often-crowed welcome + // area (infohub) and they get confused. JC + LLViewerRegion* regionp = gAgent.getRegion(); + bool agent_on_prelude = (regionp && regionp->isPrelude()); + bool enable_go_home = gAgent.isGodlike() || !agent_on_prelude; + childSetEnabled("Go Home", enable_go_home); + updateLocation(); LLTracker::ETrackingStatus tracking_status = LLTracker::getTrackingStatus(); diff --git a/indra/newview/llfloaterworldmap.h b/indra/newview/llfloaterworldmap.h index 32112a995f..5867ea179c 100644 --- a/indra/newview/llfloaterworldmap.h +++ b/indra/newview/llfloaterworldmap.h @@ -37,18 +37,18 @@ public: static void *createWorldMapView(void* data); BOOL postBuild(); - virtual void onClose(bool app_quitting); + /*virtual*/ void onClose(bool app_quitting); static void show(void*, BOOL center_on_target ); static void reloadIcons(void*); static void toggle(void*); static void hide(void*); - virtual void reshape( S32 width, S32 height, BOOL called_from_parent = TRUE ); - virtual BOOL handleHover(S32 x, S32 y, MASK mask); - virtual BOOL handleScrollWheel(S32 x, S32 y, S32 clicks); - virtual void setVisible(BOOL visible); - virtual void draw(); + /*virtual*/ void reshape( S32 width, S32 height, BOOL called_from_parent = TRUE ); + /*virtual*/ BOOL handleHover(S32 x, S32 y, MASK mask); + /*virtual*/ BOOL handleScrollWheel(S32 x, S32 y, S32 clicks); + /*virtual*/ void setVisible(BOOL visible); + /*virtual*/ void draw(); // methods for dealing with inventory. The observe() method is // called during program startup. inventoryUpdated() will be diff --git a/indra/newview/llfolderview.cpp b/indra/newview/llfolderview.cpp index 0dc7daa587..5f37d756fe 100644 --- a/indra/newview/llfolderview.cpp +++ b/indra/newview/llfolderview.cpp @@ -4449,14 +4449,15 @@ std::string::size_type LLInventoryFilter::getStringMatchOffset() const return mSubStringMatchOffset; } +// has user modified default filter params? BOOL LLInventoryFilter::isActive() { - return mFilterOps.mFilterTypes != 0xffffffff + return mFilterOps.mFilterTypes != mDefaultFilterOps.mFilterTypes || mFilterSubString.size() - || mFilterOps.mPermissions != PERM_NONE - || mFilterOps.mMinDate != 0 - || mFilterOps.mMaxDate != U32_MAX - || mFilterOps.mHoursAgo != 0; + || mFilterOps.mPermissions != mDefaultFilterOps.mPermissions + || mFilterOps.mMinDate != mDefaultFilterOps.mMinDate + || mFilterOps.mMaxDate != mDefaultFilterOps.mMaxDate + || mFilterOps.mHoursAgo != mDefaultFilterOps.mHoursAgo; } BOOL LLInventoryFilter::isModified() diff --git a/indra/newview/llfolderview.h b/indra/newview/llfolderview.h index 575d05cd0a..84dcddedbb 100644 --- a/indra/newview/llfolderview.h +++ b/indra/newview/llfolderview.h @@ -798,7 +798,6 @@ public: static void idle(void* user_data); - void setAutoSelectOverride(bool override) { mAutoSelectOverride = override; } BOOL needsAutoSelect() { return mNeedsAutoSelect && !mAutoSelectOverride; } BOOL getDebugFilters() { return mDebugFilters; } diff --git a/indra/newview/llpreviewnotecard.cpp b/indra/newview/llpreviewnotecard.cpp index 154ce5b07c..be6ef4caf4 100644 --- a/indra/newview/llpreviewnotecard.cpp +++ b/indra/newview/llpreviewnotecard.cpp @@ -128,6 +128,7 @@ BOOL LLPreviewNotecard::postBuild() if (ed) { ed->setNotecardInfo(mNotecardItemID, mObjectID); + ed->makePristine(); } return TRUE; } diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp index a7d29a6591..eb86934a54 100644 --- a/indra/newview/llpreviewscript.cpp +++ b/indra/newview/llpreviewscript.cpp @@ -169,6 +169,18 @@ LLFloaterScriptSearch::LLFloaterScriptSearch(std::string title, LLRect rect, LLS sInstance = this; childSetFocus("search_text", TRUE); + + // find floater in which script panel is embedded + LLView* viewp = (LLView*)editor_core; + while(viewp) + { + if (viewp->getWidgetType() == WIDGET_TYPE_FLOATER) + { + ((LLFloater*)viewp)->addDependentFloater(this); + break; + } + viewp = viewp->getParent(); + } } //static diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index 62903011cf..38c4f72fc9 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -2312,6 +2312,14 @@ S32 LLSpatialPartition::getLights(const LLVector3& pos, F32 rad, LLDrawable::dra return getDrawables(pos, rad, results, TRUE); } +void pushVerts(LLDrawInfo* params, U32 mask) +{ + params->mVertexBuffer->setBuffer(mask); + U32* indicesp = (U32*) params->mVertexBuffer->getIndicesPointer(); + glDrawRangeElements(params->mParticle ? GL_POINTS : GL_TRIANGLES, params->mStart, params->mEnd, params->mCount, + GL_UNSIGNED_INT, indicesp+params->mOffset); +} + void pushVerts(LLSpatialGroup* group, U32 mask) { LLDrawInfo* params = NULL; @@ -2321,10 +2329,7 @@ void pushVerts(LLSpatialGroup* group, U32 mask) for (std::vector<LLDrawInfo*>::iterator j = i->second.begin(); j != i->second.end(); ++j) { params = *j; - params->mVertexBuffer->setBuffer(mask); - U32* indicesp = (U32*) params->mVertexBuffer->getIndicesPointer(); - glDrawRangeElements(params->mParticle ? GL_POINTS : GL_TRIANGLES, params->mStart, params->mEnd, params->mCount, - GL_UNSIGNED_INT, indicesp+params->mOffset); + pushVerts(params, mask); } } } @@ -2617,6 +2622,18 @@ void renderPoints(LLDrawable* drawablep) glEnd(); } +void renderTextureAnim(LLDrawInfo* params) +{ + if (!params->mTextureMatrix) + { + return; + } + + LLGLEnable blend(GL_BLEND); + glColor4f(1,1,0,0.5f); + pushVerts(params, LLVertexBuffer::MAP_VERTEX); +} + class LLOctreeRenderNonOccluded : public LLOctreeTraveler<LLDrawable> { public: @@ -2685,6 +2702,19 @@ public: renderPoints(drawable); } } + + for (LLSpatialGroup::draw_map_t::iterator i = group->mDrawMap.begin(); i != group->mDrawMap.end(); ++i) + { + std::vector<LLDrawInfo*>& draw_vec = i->second; + for (std::vector<LLDrawInfo*>::iterator j = draw_vec.begin(); j != draw_vec.end(); ++j) + { + LLDrawInfo* draw_info = *j; + if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXTURE_ANIM)) + { + renderTextureAnim(draw_info); + } + } + } } }; @@ -2694,7 +2724,8 @@ void LLSpatialPartition::renderDebug() LLPipeline::RENDER_DEBUG_OCCLUSION | LLPipeline::RENDER_DEBUG_BBOXES | LLPipeline::RENDER_DEBUG_POINTS | - LLPipeline::RENDER_DEBUG_TEXTURE_PRIORITY)) + LLPipeline::RENDER_DEBUG_TEXTURE_PRIORITY | + LLPipeline::RENDER_DEBUG_TEXTURE_ANIM)) { return; } diff --git a/indra/newview/lltexturectrl.cpp b/indra/newview/lltexturectrl.cpp index 794281965e..39feb40109 100644 --- a/indra/newview/lltexturectrl.cpp +++ b/indra/newview/lltexturectrl.cpp @@ -95,6 +95,7 @@ public: EAcceptance *accept, LLString& tooltip_msg); virtual void draw(); + virtual BOOL handleKeyHere(KEY key, MASK mask, BOOL called_from_parent); // LLFloater overrides virtual void onClose(bool app_quitting); @@ -156,6 +157,7 @@ protected: BOOL mCanApplyImmediately; BOOL mNoCopyTextureSelected; F32 mContextConeOpacity; + LLSaveFolderState mSavedFolderState; }; LLFloaterTexturePicker::LLFloaterTexturePicker( @@ -210,13 +212,16 @@ LLFloaterTexturePicker::LLFloaterTexturePicker( filter_types |= 0x1 << LLInventoryType::IT_TEXTURE; filter_types |= 0x1 << LLInventoryType::IT_SNAPSHOT; - mInventoryPanel->setAutoSelectOverride(true); mInventoryPanel->setFilterTypes(filter_types); //mInventoryPanel->setFilterPermMask(getFilterPermMask()); //Commented out due to no-copy texture loss. mInventoryPanel->setFilterPermMask(immediate_filter_perm_mask); mInventoryPanel->setSelectCallback(onSelectionChange, this); mInventoryPanel->setShowFolderState(LLInventoryFilter::SHOW_NON_EMPTY_FOLDERS); mInventoryPanel->setAllowMultiSelect(FALSE); + + // store this filter as the default one + mInventoryPanel->getRootFolder()->getFilter()->markDefault(); + // Commented out to stop opening all folders with textures // mInventoryPanel->openDefaultFolderForType(LLAssetType::AT_TEXTURE); @@ -244,6 +249,8 @@ LLFloaterTexturePicker::LLFloaterTexturePicker( updateFilterPermMask(); setCanMinimize(FALSE); + + mSavedFolderState.setApply(FALSE); } LLFloaterTexturePicker::~LLFloaterTexturePicker() @@ -379,6 +386,41 @@ BOOL LLFloaterTexturePicker::handleDragAndDrop( return handled; } +BOOL LLFloaterTexturePicker::handleKeyHere(KEY key, MASK mask, BOOL called_from_parent) +{ + LLFolderView* root_folder = mInventoryPanel->getRootFolder(); + + if (!called_from_parent && root_folder && + mSearchEdit && mSearchEdit->hasFocus() && + (key == KEY_RETURN || key == KEY_DOWN) && mask == MASK_NONE) + { + if (!root_folder->getCurSelectedItem()) + { + LLFolderViewItem* itemp = root_folder->getItemByID(gAgent.getInventoryRootID()); + if (itemp) + { + root_folder->setSelection(itemp, FALSE, FALSE); + } + } + root_folder->scrollToShowSelection(); + + // move focus to inventory proper + root_folder->setFocus(TRUE); + + // treat this as a user selection of the first filtered result + commitIfImmediateSet(); + + return TRUE; + } + + if (root_folder->hasFocus() && key == KEY_UP) + { + mSearchEdit->focusFirstItem(TRUE); + } + + return LLFloater::handleKeyHere(key, mask, called_from_parent); +} + // virtual void LLFloaterTexturePicker::onClose(bool app_quitting) { @@ -738,53 +780,36 @@ void LLFloaterTexturePicker::onSearchEdit(const LLString& search_string, void* u { LLFloaterTexturePicker* picker = (LLFloaterTexturePicker*)user_data; - std::string filter_text = search_string; - - if (filter_text.empty()&& picker->mInventoryPanel->getFilterSubString().empty()) - { - // current filter and new filter empty, do nothing - return; - } - std::string upper_case_search_string = filter_text; + std::string upper_case_search_string = search_string; LLString::toUpper(upper_case_search_string); - picker->mInventoryPanel->setFilterSubString(upper_case_search_string); - - LLFolderView* root_folder = picker->mInventoryPanel->getRootFolder(); - - //if (search_string.size()) - //{ - // LLSelectFirstFilteredItem filter; - // root_folder->applyFunctorRecursively(filter); - // //...and scroll to show it - // root_folder->scrollToShowSelection(); - //} - - KEY key = gKeyboard->currentKey(); - - if ((key == KEY_RETURN || key == KEY_DOWN) && gKeyboard->currentMask(FALSE) == MASK_NONE) + if (upper_case_search_string.empty()) { - if (search_string.size()) + if (picker->mInventoryPanel->getFilterSubString().empty()) { - LLSelectFirstFilteredItem filter; - root_folder->applyFunctorRecursively(filter); - //...and scroll to show it - root_folder->scrollToShowSelection(); + // current filter and new filter empty, do nothing + return; } - if (!root_folder->getCurSelectedItem()) + picker->mSavedFolderState.setApply(TRUE); + picker->mInventoryPanel->getRootFolder()->applyFunctorRecursively(picker->mSavedFolderState); + // add folder with current item to list of previously opened folders + LLOpenFoldersWithSelection opener; + picker->mInventoryPanel->getRootFolder()->applyFunctorRecursively(opener); + picker->mInventoryPanel->getRootFolder()->scrollToShowSelection(); + + } + else if (picker->mInventoryPanel->getFilterSubString().empty()) + { + // first letter in search term, save existing folder open state + if (!picker->mInventoryPanel->getRootFolder()->isFilterActive()) { - LLFolderViewItem* itemp = root_folder->getItemByID(gAgent.getInventoryRootID()); - if (itemp) - { - root_folder->setSelection(itemp, FALSE, FALSE); - } + picker->mSavedFolderState.setApply(FALSE); + picker->mInventoryPanel->getRootFolder()->applyFunctorRecursively(picker->mSavedFolderState); } - - // move focus to inventory proper - root_folder->setFocus(TRUE); - root_folder->scrollToShowSelection(); } + + picker->mInventoryPanel->setFilterSubString(upper_case_search_string); } //static diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index a638d99381..0cce868b4a 100644 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -1131,6 +1131,9 @@ void init_debug_rendering_menu(LLMenuGL* menu) sub_menu->append(new LLMenuItemCheckGL("Occlusion", &LLPipeline::toggleRenderDebug, NULL, &LLPipeline::toggleRenderDebugControl, (void*)LLPipeline::RENDER_DEBUG_OCCLUSION)); + sub_menu->append(new LLMenuItemCheckGL("Animated Textures", &LLPipeline::toggleRenderDebug, NULL, + &LLPipeline::toggleRenderDebugControl, + (void*)LLPipeline::RENDER_DEBUG_TEXTURE_ANIM)); sub_menu->append(new LLMenuItemCheckGL("Texture Priority", &LLPipeline::toggleRenderDebug, NULL, &LLPipeline::toggleRenderDebugControl, (void*)LLPipeline::RENDER_DEBUG_TEXTURE_PRIORITY)); @@ -7787,6 +7790,18 @@ class LLWorldEnableSetHomeLocation : public view_listener_t } }; +class LLWorldEnableTeleportHome : public view_listener_t +{ + bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata) + { + LLViewerRegion* regionp = gAgent.getRegion(); + bool agent_on_prelude = (regionp && regionp->isPrelude()); + bool enable_teleport_home = gAgent.isGodlike() || !agent_on_prelude; + gMenuHolder->findControl(userdata["control"].asString())->setValue(enable_teleport_home); + return true; + } +}; + BOOL enable_region_owner(void*) { if(gAgent.getRegion() && gAgent.getRegion()->getOwner() == gAgent.getID()) @@ -8603,6 +8618,7 @@ void initialize_menu_actions() (new LLWorldEnableCreateLandmark())->registerListener(gMenuHolder, "World.EnableCreateLandmark"); (new LLWorldEnableSetHomeLocation())->registerListener(gMenuHolder, "World.EnableSetHomeLocation"); + (new LLWorldEnableTeleportHome())->registerListener(gMenuHolder, "World.EnableTeleportHome"); (new LLWorldEnableBuyLand())->registerListener(gMenuHolder, "World.EnableBuyLand"); (new LLWorldCheckAlwaysRun())->registerListener(gMenuHolder, "World.CheckAlwaysRun"); diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index 6d4170e437..ed13f6dbe9 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -1978,6 +1978,7 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data) is_linden = gMuteListp->isLinden(from_name); } + BOOL is_audible = (CHAT_AUDIBLE_FULLY == chat.mAudible); chatter = gObjectList.findObject(from_id); if (chatter) { @@ -1997,7 +1998,8 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data) } // only pay attention to other people chatting - if ((is_linden || (!is_muted && !is_busy)) + if (is_audible + && (is_linden || (!is_muted && !is_busy)) && chatter != gAgent.getAvatarObject()) { gAgent.heardChat(chat); @@ -2010,7 +2012,6 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data) is_owned_by_me = chatter->permYouOwner(); } - BOOL is_audible = (CHAT_AUDIBLE_FULLY == chat.mAudible); if (is_audible) { BOOL visible_in_chat_bubble = FALSE; diff --git a/indra/newview/llviewerobjectlist.cpp b/indra/newview/llviewerobjectlist.cpp index 68193604bb..b80aabab34 100644 --- a/indra/newview/llviewerobjectlist.cpp +++ b/indra/newview/llviewerobjectlist.cpp @@ -1217,7 +1217,7 @@ LLViewerObject *LLViewerObjectList::createObjectViewer(const LLPCode pcode, LLVi LLViewerObject *objectp = LLViewerObject::createObject(fullid, pcode, regionp); if (!objectp) { - llwarns << "Couldn't create object of type " << LLPrimitive::pCodeToString(pcode) << llendl; +// llwarns << "Couldn't create object of type " << LLPrimitive::pCodeToString(pcode) << llendl; return NULL; } @@ -1251,7 +1251,7 @@ LLViewerObject *LLViewerObjectList::createObject(const LLPCode pcode, LLViewerRe LLViewerObject *objectp = LLViewerObject::createObject(fullid, pcode, regionp); if (!objectp) { - llwarns << "Couldn't create object of type " << LLPrimitive::pCodeToString(pcode) << " id:" << fullid << llendl; +// llwarns << "Couldn't create object of type " << LLPrimitive::pCodeToString(pcode) << " id:" << fullid << llendl; return NULL; } diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 36c08321ed..a2dadcc438 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -2172,7 +2172,9 @@ BOOL LLViewerWindow::handleKey(KEY key, MASK mask) } // don't pass keys on to world when something in ui has focus - return gFocusMgr.childHasKeyboardFocus(mRootView) || (gMenuBarView && gMenuBarView->getHighlightedItem()); + return gFocusMgr.childHasKeyboardFocus(mRootView) + || LLMenuGL::getKeyboardMode() + || (gMenuBarView && gMenuBarView->getHighlightedItem() && gMenuBarView->getHighlightedItem()->isActive()); } diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index afeffa0aec..f9ee5064a1 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -2014,7 +2014,7 @@ void LLVOAvatar::buildCharacter() continue; } LLMenuItemCallGL* item = new LLMenuItemCallGL(attachment->getName(), - NULL, &object_selected_and_point_valid, &attach_label, NULL); + NULL, &object_selected_and_point_valid, &attach_label, attachment); item->addListener(gMenuHolder->getListenerByName("Object.AttachToAvatar"), "on_click", mAttachmentPoints.reverseLookup(attachment)); gAttachSubMenu->append(item); @@ -4508,14 +4508,7 @@ BOOL LLVOAvatar::stopMotion(const LLUUID& id, BOOL stop_immediate) { if (mIsSelf) { - if (id == ANIM_AGENT_STAND) - { - LLAgent::stopFidget(); - } - else if (id == ANIM_AGENT_AWAY) - { - gAgent.clearAFK(); - } + gAgent.onAnimStop(id); } if (id == ANIM_AGENT_WALK) diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index d08c5311d7..6619531953 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -59,6 +59,7 @@ LLVOVolume::LLVOVolume(const LLUUID &id, const LLPCode pcode, LLViewerRegion *re : LLViewerObject(id, pcode, regionp), mVolumeImpl(NULL) { + mTexAnimMode = 0; mRelativeXform.identity(); mRelativeXformInvTrans.identity(); @@ -118,8 +119,8 @@ U32 LLVOVolume::processUpdateMessage(LLMessageSystem *mesgsys, mTextureAnimp->reset(); } } + mTexAnimMode = 0; mTextureAnimp->unpackTAMessage(mesgsys, block_num); - gPipeline.markTextured(mDrawable); } else { @@ -129,6 +130,7 @@ U32 LLVOVolume::processUpdateMessage(LLMessageSystem *mesgsys, mTextureAnimp = NULL; gPipeline.markTextured(mDrawable); mFaceMappingChanged = TRUE; + mTexAnimMode = 0; } } @@ -201,12 +203,16 @@ U32 LLVOVolume::processUpdateMessage(LLMessageSystem *mesgsys, mTextureAnimp->reset(); } } + mTexAnimMode = 0; mTextureAnimp->unpackTAMessage(*dp); } - else + else if (mTextureAnimp) { delete mTextureAnimp; mTextureAnimp = NULL; + gPipeline.markTextured(mDrawable); + mFaceMappingChanged = TRUE; + mTexAnimMode = 0; } } else @@ -229,94 +235,105 @@ U32 LLVOVolume::processUpdateMessage(LLMessageSystem *mesgsys, } -BOOL LLVOVolume::idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time) +void LLVOVolume::animateTextures() { - LLViewerObject::idleUpdate(agent, world, time); - - /////////////////////// - // - // Do texture animation stuff - // - - if (mTextureAnimp && gAnimateTextures) + F32 off_s = 0.f, off_t = 0.f, scale_s = 1.f, scale_t = 1.f, rot = 0.f; + S32 result; + + if (result = mTextureAnimp->animateTextures(off_s, off_t, scale_s, scale_t, rot)) { - F32 off_s = 0.f, off_t = 0.f, scale_s = 1.f, scale_t = 1.f, rot = 0.f; - S32 result; - if (result = mTextureAnimp->animateTextures(off_s, off_t, scale_s, scale_t, rot)) + if (!mTexAnimMode) { - mTexAnimMode = mTextureAnimp->mMode | result; - - S32 start, end; - if (mTextureAnimp->mFace == -1) - { - start = 0; - end = mDrawable->getNumFaces(); - } - else + mFaceMappingChanged = TRUE; + gPipeline.markTextured(mDrawable); + } + mTexAnimMode = result | mTextureAnimp->mMode; + + S32 start=0, end=mDrawable->getNumFaces()-1; + if (mTextureAnimp->mFace >= 0 && mTextureAnimp->mFace <= end) + { + start = end = mTextureAnimp->mFace; + } + + for (S32 i = start; i <= end; i++) + { + LLQuaternion quat; + LLVector3 scale(1,1,1); + + LLFace* facep = mDrawable->getFace(i); + const LLTextureEntry* te = facep->getTextureEntry(); + LLMatrix4& tex_mat = facep->mTextureMatrix; + + if (!te) { - start = mTextureAnimp->mFace; - end = start + 1; + continue; } - - for (S32 i = start; i < end; i++) + if (result & LLViewerTextureAnim::ROTATE) { - LLQuaternion quat; - LLVector3 scale(1,1,1); - - LLFace* facep = mDrawable->getFace(i); - const LLTextureEntry* te = facep->getTextureEntry(); - LLMatrix4& tex_mat = facep->mTextureMatrix; - - if (!te) + F32 axis = -1; + F32 s,t; + te->getScale(&s,&t); + if (s < 0) { - continue; + axis = -axis; } - if (result & LLViewerTextureAnim::ROTATE) + if (t < 0) { - F32 axis = -1; - F32 s,t; - te->getScale(&s,&t); - if (s < 0) - { - axis = -axis; - } - if (t < 0) - { - axis = -axis; - } - quat.setQuat(rot, 0, 0, axis); + axis = -axis; } - - if (!(result & LLViewerTextureAnim::TRANSLATE)) - { - te->getOffset(&off_s,&off_t); - } + quat.setQuat(rot, 0, 0, axis); + } + + if (!(result & LLViewerTextureAnim::TRANSLATE)) + { + te->getOffset(&off_s,&off_t); + } - LLVector3 trans(off_s+0.5f, off_t+0.5f, 0.f); + LLVector3 trans(off_s+0.5f, off_t+0.5f, 0.f); - tex_mat.identity(); - tex_mat.translate(LLVector3(-0.5f, -0.5f, 0.f)); - tex_mat.rotate(quat); - - if (result & LLViewerTextureAnim::SCALE) - { - scale.setVec(scale_s, scale_t, 1.f); - LLMatrix4 mat; - mat.initAll(scale, LLQuaternion(), LLVector3()); - tex_mat *= mat; - } - - tex_mat.translate(trans); + tex_mat.identity(); + tex_mat.translate(LLVector3(-0.5f, -0.5f, 0.f)); + tex_mat.rotate(quat); + + if (result & LLViewerTextureAnim::SCALE) + { + scale.setVec(scale_s, scale_t, 1.f); + LLMatrix4 mat; + mat.initAll(scale, LLQuaternion(), LLVector3()); + tex_mat *= mat; } + + tex_mat.translate(trans); } - else + } + else + { + if (mTexAnimMode && mTextureAnimp->mRate == 0) { - if (mTextureAnimp->mRate == 0) - { - mTexAnimMode = 0; - } + gPipeline.markTextured(mDrawable); + mFaceMappingChanged = TRUE; + mTexAnimMode = 0; } } +} +BOOL LLVOVolume::idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time) +{ + LLViewerObject::idleUpdate(agent, world, time); + + if (mDead || mDrawable.isNull()) + { + return TRUE; + } + + /////////////////////// + // + // Do texture animation stuff + // + + if (mTextureAnimp && gAnimateTextures) + { + animateTextures(); + } // Dispatch to implementation if (mVolumeImpl) @@ -717,15 +734,26 @@ void LLVOVolume::setParent(LLViewerObject* parent) void LLVOVolume::regenFaces() { // remove existing faces - deleteFaces(); + BOOL count_changed = mNumFaces != getNumTEs(); - // add new faces - mNumFaces = getNumTEs(); + if (count_changed) + { + deleteFaces(); + // add new faces + mNumFaces = getNumTEs(); + } + for (S32 i = 0; i < mNumFaces; i++) { - LLFace* facep = addFace(i); - facep->setViewerObject(this); + LLFace* facep = count_changed ? addFace(i) : mDrawable->getFace(i); facep->setTEOffset(i); + facep->setTexture(getTEImage(i)); + facep->setViewerObject(this); + } + + if (!count_changed) + { + updateFaceFlags(); } } @@ -2062,21 +2090,14 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group) facep->setState(LLFace::FULLBRIGHT); } - if (vobj->mTextureAnimp) + if (vobj->mTextureAnimp && vobj->mTexAnimMode) { if (vobj->mTextureAnimp->mFace <= -1) { S32 face; for (face = 0; face < vobj->getNumTEs(); face++) { - if (vobj->mTextureAnimp->mMode & LLViewerTextureAnim::ON) - { - drawablep->getFace(face)->setState(LLFace::TEXTURE_ANIM); - } - else - { - drawablep->getFace(face)->clearState(LLFace::TEXTURE_ANIM); - } + drawablep->getFace(face)->setState(LLFace::TEXTURE_ANIM); } } else if (vobj->mTextureAnimp->mFace < vobj->getNumTEs()) diff --git a/indra/newview/llvovolume.h b/indra/newview/llvovolume.h index 76b469e6aa..16a91bce8e 100644 --- a/indra/newview/llvovolume.h +++ b/indra/newview/llvovolume.h @@ -71,6 +71,7 @@ public: void deleteFaces(); + void animateTextures(); /*virtual*/ BOOL idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time); /*virtual*/ BOOL isActive() const; diff --git a/indra/newview/pipeline.h b/indra/newview/pipeline.h index 0fadae0a61..5061ef742c 100644 --- a/indra/newview/pipeline.h +++ b/indra/newview/pipeline.h @@ -327,6 +327,7 @@ public: RENDER_DEBUG_TEXTURE_AREA = 0x08000, RENDER_DEBUG_FACE_AREA = 0x10000, RENDER_DEBUG_PARTICLES = 0x20000, + RENDER_DEBUG_TEXTURE_ANIM = 0x40000, }; LLPointer<LLViewerImage> mAlphaSizzleImagep; |