summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorDon Kjer <don@lindenlab.com>2007-10-11 00:28:42 +0000
committerDon Kjer <don@lindenlab.com>2007-10-11 00:28:42 +0000
commit1b550aaec246063090fe7143145d69eebfbd4680 (patch)
tree66b1d7c9f424e0183c5488037fcdae3a37916955 /indra/newview
parent5ec8bbbe2244ea70d8aa74b5c572351632699425 (diff)
EFFECTIVE MERGE: svn merge -r 69928:70806 svn+ssh://svn/svn/linden/branches/maintenance-1 && svn merge -r 70948:70949 svn+ssh://svn/svn/linden/branches/maintenance-1-qa into release
ACTUAL MERGE: svn merge -r 71430:71431 svn+ssh://svn/svn/linden/qa/maintenance-1-merge-71429 into release
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llchatbar.cpp4
-rw-r--r--indra/newview/llfloaterworldmap.cpp15
-rw-r--r--indra/newview/llfolderview.cpp8
-rw-r--r--indra/newview/llgroupmgr.cpp12
-rw-r--r--indra/newview/llinventorybridge.cpp10
-rw-r--r--indra/newview/llpanelgroup.cpp4
-rw-r--r--indra/newview/llpreviewgesture.cpp20
-rw-r--r--indra/newview/llselectmgr.cpp35
-rw-r--r--indra/newview/llselectmgr.h7
-rw-r--r--indra/newview/llstartup.cpp73
-rw-r--r--indra/newview/lltoolselect.cpp8
-rw-r--r--indra/newview/pipeline.cpp8
-rw-r--r--indra/newview/pipeline.h7
13 files changed, 99 insertions, 112 deletions
diff --git a/indra/newview/llchatbar.cpp b/indra/newview/llchatbar.cpp
index 21a5e08587..3517c1e18a 100644
--- a/indra/newview/llchatbar.cpp
+++ b/indra/newview/llchatbar.cpp
@@ -456,7 +456,7 @@ LLWString LLChatBar::stripChannelNumber(const LLWString &mesg, S32* channel)
}
else if (mesg[0] == '/'
&& mesg[1]
- && isdigit(mesg[1]))
+ && LLStringOps::isDigit(mesg[1]))
{
// This a special "/20" speak on a channel
S32 pos = 0;
@@ -470,7 +470,7 @@ LLWString LLChatBar::stripChannelNumber(const LLWString &mesg, S32* channel)
channel_string[pos] = c;
pos++;
}
- while(c && pos < 64 && isdigit(c));
+ while(c && pos < 64 && LLStringOps::isDigit(c));
// Move the pointer forward to the first non-whitespace char
// Check isspace before looping, so we can handle "/33foo"
diff --git a/indra/newview/llfloaterworldmap.cpp b/indra/newview/llfloaterworldmap.cpp
index 23d01a963b..bdb7f09e22 100644
--- a/indra/newview/llfloaterworldmap.cpp
+++ b/indra/newview/llfloaterworldmap.cpp
@@ -298,20 +298,6 @@ void LLFloaterWorldMap::onClose(bool app_quitting)
setVisible(FALSE);
}
-// Allow us to download landmarks quickly when map is shown
-class LLLandmarkFetchDescendentsObserver : public LLInventoryFetchDescendentsObserver
-{
-public:
- virtual void done()
- {
- // We need to find landmarks in all folders, so get the main
- // background download going.
- gInventory.startBackgroundFetch();
- gInventory.removeObserver(this);
- delete this;
- }
-};
-
// static
void LLFloaterWorldMap::show(void*, BOOL center_on_target)
{
@@ -351,7 +337,6 @@ void LLFloaterWorldMap::show(void*, BOOL center_on_target)
LLFirstUse::useMap();
// Start speculative download of landmarks
- LLInventoryFetchDescendentsObserver::folder_ref_t folders;
LLUUID landmark_folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
gInventory.startBackgroundFetch(landmark_folder_id);
diff --git a/indra/newview/llfolderview.cpp b/indra/newview/llfolderview.cpp
index 38f2249329..a68b937093 100644
--- a/indra/newview/llfolderview.cpp
+++ b/indra/newview/llfolderview.cpp
@@ -3678,6 +3678,14 @@ BOOL LLFolderView::handleKeyHere( KEY key, MASK mask, BOOL called_from_parent )
{
BOOL handled = FALSE;
+ // SL-51858: Key presses are not being passed to the Popup menu.
+ // A proper fix is non-trivial so instead just close the menu.
+ LLMenuGL* menu = (LLMenuGL*)LLView::getViewByHandle(mPopupMenuHandle);
+ if (menu->isOpen())
+ {
+ LLMenuGL::sMenuContainer->hideMenus();
+ }
+
LLView *item = NULL;
if (getChildCount() > 0)
{
diff --git a/indra/newview/llgroupmgr.cpp b/indra/newview/llgroupmgr.cpp
index 7d7a5b9a3a..d1116b66e1 100644
--- a/indra/newview/llgroupmgr.cpp
+++ b/indra/newview/llgroupmgr.cpp
@@ -780,7 +780,10 @@ void LLGroupMgr::removeObserver(LLGroupMgrObserver* observer)
mObservers.erase(it);
break;
}
- ++it;
+ else
+ {
+ ++it;
+ }
}
}
@@ -1287,6 +1290,7 @@ void LLGroupMgr::processCreateGroupReply(LLMessageSystem* msg, void ** data)
LLGroupMgrGroupData* LLGroupMgr::createGroupData(const LLUUID& id)
{
LLGroupMgrGroupData* group_datap;
+
group_iter existing_group = gGroupMgr->mGroups.find(id);
if (existing_group == gGroupMgr->mGroups.end())
{
@@ -1320,7 +1324,6 @@ void LLGroupMgr::notifyObservers(LLGroupChange gc)
void LLGroupMgr::addGroup(LLGroupMgrGroupData* group_datap)
{
- mGroups[group_datap->getID()] = group_datap;
if (mGroups.size() > MAX_CACHED_GROUPS)
{
// get rid of groups that aren't observed
@@ -1330,8 +1333,8 @@ void LLGroupMgr::addGroup(LLGroupMgrGroupData* group_datap)
if (oi == mObservers.end())
{
// not observed
- LLGroupMgrGroupData* group_datap = gi->second;
- delete group_datap;
+ LLGroupMgrGroupData* unobserved_groupp = gi->second;
+ delete unobserved_groupp;
mGroups.erase(gi++);
}
else
@@ -1340,6 +1343,7 @@ void LLGroupMgr::addGroup(LLGroupMgrGroupData* group_datap)
}
}
}
+ mGroups[group_datap->getID()] = group_datap;
}
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 4e9c399f3e..505364f98c 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -1784,8 +1784,14 @@ void LLFolderBridge::folderOptionsMenu()
checkFolderForContentsOfType(model, is_gesture) )
{
mItems.push_back("Folder Wearables Separator");
- mItems.push_back("Add To Outfit");
- mItems.push_back("Replace Outfit");
+
+ // Only enable add/replace outfit for non-default folders.
+ const LLInventoryCategory* category = model->getCategory(mUUID);
+ if (!category || (LLAssetType::AT_NONE == category->getPreferredType()))
+ {
+ mItems.push_back("Add To Outfit");
+ mItems.push_back("Replace Outfit");
+ }
mItems.push_back("Take Off Items");
}
hideContextEntries(*mMenu, mItems, disabled_items);
diff --git a/indra/newview/llpanelgroup.cpp b/indra/newview/llpanelgroup.cpp
index f3e9eaf2fe..a96b66984b 100644
--- a/indra/newview/llpanelgroup.cpp
+++ b/indra/newview/llpanelgroup.cpp
@@ -168,11 +168,11 @@ LLPanelGroup::LLPanelGroup(const std::string& filename,
mFactoryMap["roles_sub_tab"] = LLCallbackMap(LLPanelGroupRolesSubTab::createTab, &mID);
mFactoryMap["actions_sub_tab"] = LLCallbackMap(LLPanelGroupActionsSubTab::createTab, &mID);
+ gGroupMgr->addObserver(this);
+
// Pass on construction of this panel to the control factory.
gUICtrlFactory->buildPanel(this, filename, &getFactoryMap());
mFilename = filename;
-
- gGroupMgr->addObserver(this);
}
LLPanelGroup::~LLPanelGroup()
diff --git a/indra/newview/llpreviewgesture.cpp b/indra/newview/llpreviewgesture.cpp
index a9205998e6..720963cb0f 100644
--- a/indra/newview/llpreviewgesture.cpp
+++ b/indra/newview/llpreviewgesture.cpp
@@ -151,6 +151,13 @@ LLPreviewGesture* LLPreviewGesture::show(const std::string& title, const LLUUID&
hostp->addFloater(self, TRUE);
}
+ // Start speculative download of sounds and animations
+ LLUUID animation_folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_ANIMATION);
+ gInventory.startBackgroundFetch(animation_folder_id);
+
+ LLUUID sound_folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_SOUND);
+ gInventory.startBackgroundFetch(sound_folder_id);
+
// this will call refresh when we have everything.
LLViewerInventoryItem* item = (LLViewerInventoryItem*)self->getItem();
if(item && !item->isComplete())
@@ -577,8 +584,10 @@ void LLPreviewGesture::addAnimations()
LLComboBox* combo = mAnimationCombo;
combo->removeall();
+
+ LLString none_text = childGetText("none_text");
- combo->add("-- None --", LLUUID::null);
+ combo->add(none_text, LLUUID::null);
// Add all the default (legacy) animations
S32 i;
@@ -628,6 +637,13 @@ void LLPreviewGesture::addAnimations()
void LLPreviewGesture::addSounds()
{
+ LLComboBox* combo = mSoundCombo;
+ combo->removeall();
+
+ LLString none_text = childGetText("none_text");
+
+ combo->add(none_text, LLUUID::null);
+
// Get all inventory items that are sounds
LLViewerInventoryCategory::cat_array_t cats;
LLViewerInventoryItem::item_array_t items;
@@ -655,8 +671,6 @@ void LLPreviewGesture::addSounds()
std::sort(sounds.begin(), sounds.end(), SortItemPtrsByName());
// And load up the combobox
- LLComboBox* combo = mSoundCombo;
- combo->removeall();
std::vector<LLInventoryItem*>::iterator it;
for (it = sounds.begin(); it != sounds.end(); ++it)
{
diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp
index af16a4d3fa..d48fa405ba 100644
--- a/indra/newview/llselectmgr.cpp
+++ b/indra/newview/llselectmgr.cpp
@@ -3272,7 +3272,6 @@ void LLSelectMgr::deselectAll()
mLastSentSelectionCenterGlobal.clearVec();
updatePointAt();
- updateSelectionCenter();
}
void LLSelectMgr::deselectUnused()
@@ -5302,11 +5301,8 @@ void LLSelectMgr::updateSelectionCenter()
mShowSelection = FALSE;
mSelectionBBox = LLBBox();
mPauseRequest = NULL;
- if (gAgent.getAvatarObject())
- {
- gAgent.getAvatarObject()->mHUDTargetZoom = 1.f;
- gAgent.getAvatarObject()->mHUDCurZoom = 1.f;
- }
+ resetAgentHUDZoom();
+
}
else
{
@@ -5604,6 +5600,33 @@ BOOL LLSelectMgr::setForceSelection(BOOL force)
return force;
}
+void LLSelectMgr::resetAgentHUDZoom()
+{
+ if (gAgent.getAvatarObject())
+ {
+ gAgent.getAvatarObject()->mHUDTargetZoom = 1.f;
+ gAgent.getAvatarObject()->mHUDCurZoom = 1.f;
+ }
+}
+
+void LLSelectMgr::getAgentHUDZoom(F32 &target_zoom, F32 &current_zoom) const
+{
+ if (gAgent.getAvatarObject())
+ {
+ target_zoom = gAgent.getAvatarObject()->mHUDTargetZoom;
+ current_zoom = gAgent.getAvatarObject()->mHUDCurZoom;
+ }
+}
+
+void LLSelectMgr::setAgentHUDZoom(F32 target_zoom, F32 current_zoom)
+{
+ if (gAgent.getAvatarObject())
+ {
+ gAgent.getAvatarObject()->mHUDTargetZoom = target_zoom;
+ gAgent.getAvatarObject()->mHUDCurZoom = current_zoom;
+ }
+}
+
LLObjectSelection::LLObjectSelection() :
LLRefCount(),
mSelectType(SELECT_TYPE_WORLD)
diff --git a/indra/newview/llselectmgr.h b/indra/newview/llselectmgr.h
index 69bf585005..26b919ba28 100644
--- a/indra/newview/llselectmgr.h
+++ b/indra/newview/llselectmgr.h
@@ -602,7 +602,12 @@ public:
LLVector3d getSelectionCenterGlobal() const { return mSelectionCenterGlobal; }
void updateSelectionCenter();
- void updatePointAt();
+
+ void resetAgentHUDZoom();
+ void setAgentHUDZoom(F32 target_zoom, F32 current_zoom);
+ void getAgentHUDZoom(F32 &target_zoom, F32 &current_zoom) const;
+
+ void updatePointAt();
// Internal list maintenance functions. TODO: Make these private!
void remove(std::vector<LLViewerObject*>& objects);
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp
index 4ade8c57ff..a84590f4df 100644
--- a/indra/newview/llstartup.cpp
+++ b/indra/newview/llstartup.cpp
@@ -1078,7 +1078,17 @@ BOOL idle_startup()
}
else if (message_response)
{
- emsg << message_response;
+ // XUI: fix translation for strings returned during login
+ // We need a generic table for translations
+ LLString big_reason = LLAgent::sTeleportErrorMessages[ message_response ];
+ if ( big_reason.size() == 0 )
+ {
+ emsg << message_response;
+ }
+ else
+ {
+ emsg << big_reason;
+ }
}
if(reason_response && (0 == strcmp(reason_response, "tos")))
@@ -3099,67 +3109,6 @@ void init_stat_view()
stat_barp->mDisplayBar = FALSE;
- // Pipeline statistics
- LLStatView *pipeline_statviewp;
- pipeline_statviewp = new LLStatView("pipeline stat view", "Pipeline", "", rect);
- render_statviewp->addChildAtEnd(pipeline_statviewp);
-
- stat_barp = pipeline_statviewp->addStat("Visible Drawables", &(gPipeline.mNumVisibleDrawablesStat));
- stat_barp->setUnitLabel("");
- stat_barp->mMinBar = 0.f;
- stat_barp->mMaxBar = 10000.f;
- stat_barp->mTickSpacing = 1000.f;
- stat_barp->mLabelSpacing = 5000.f;
- stat_barp->mPerSec = FALSE;
-
- stat_barp = pipeline_statviewp->addStat("Visible Faces", &(gPipeline.mNumVisibleFacesStat));
- stat_barp->setUnitLabel("");
- stat_barp->mMinBar = 0.f;
- stat_barp->mMaxBar = 40000.f;
- stat_barp->mTickSpacing = 5000.f;
- stat_barp->mLabelSpacing = 10000.f;
- stat_barp->mPerSec = FALSE;
-
- stat_barp = pipeline_statviewp->addStat("DirtyGeom", &(gPipeline.mGeometryChangesStat));
- stat_barp->setUnitLabel("/fr");
- stat_barp->mMinBar = 0.f;
- stat_barp->mMaxBar = 1000.f;
- stat_barp->mTickSpacing = 100.f;
- stat_barp->mLabelSpacing = 500.f;
- stat_barp->mPerSec = FALSE;
-
- stat_barp = pipeline_statviewp->addStat("DirtyLight", &(gPipeline.mLightingChangesStat));
- stat_barp->setUnitLabel("/fr");
- stat_barp->mMinBar = 0.f;
- stat_barp->mMaxBar = 1000.f;
- stat_barp->mTickSpacing = 100.f;
- stat_barp->mLabelSpacing = 500.f;
- stat_barp->mPerSec = FALSE;
-
- stat_barp = pipeline_statviewp->addStat("MoveList", &(gPipeline.mMoveChangesStat));
- stat_barp->setUnitLabel("dr");
- stat_barp->mMinBar = 0.f;
- stat_barp->mMaxBar = 1000.f;
- stat_barp->mTickSpacing = 100.f;
- stat_barp->mLabelSpacing = 500.f;
- stat_barp->mPerSec = FALSE;
-
- stat_barp = pipeline_statviewp->addStat("Compiles", &(gPipeline.mCompilesStat));
- stat_barp->setUnitLabel("/fr");
- stat_barp->mMinBar = 0.f;
- stat_barp->mMaxBar = 1000.f;
- stat_barp->mTickSpacing = 100.f;
- stat_barp->mLabelSpacing = 500.f;
- stat_barp->mPerSec = FALSE;
-
- stat_barp = pipeline_statviewp->addStat("Verts Relit", &(gPipeline.mVerticesRelitStat));
- stat_barp->setUnitLabel("/fr");
- stat_barp->mMinBar = 0.f;
- stat_barp->mMaxBar = 40000.f;
- stat_barp->mTickSpacing = 10000.f;
- stat_barp->mLabelSpacing = 20000.f;
- stat_barp->mPerSec = FALSE;
-
// Texture statistics
LLStatView *texture_statviewp;
texture_statviewp = new LLStatView("texture stat view", "Texture", "", rect);
diff --git a/indra/newview/lltoolselect.cpp b/indra/newview/lltoolselect.cpp
index d366226a05..f77202f1bc 100644
--- a/indra/newview/lltoolselect.cpp
+++ b/indra/newview/lltoolselect.cpp
@@ -155,6 +155,11 @@ LLHandle<LLObjectSelection> LLToolSelect::handleObjectSelection(LLViewerObject *
}
else
{
+ // Save the current zoom values because deselect resets them.
+ F32 target_zoom;
+ F32 current_zoom;
+ gSelectMgr->getAgentHUDZoom(target_zoom, current_zoom);
+
// JC - Change behavior to make it easier to select children
// of linked sets. 9/3/2002
if( !already_selected || ignore_group)
@@ -171,6 +176,9 @@ LLHandle<LLObjectSelection> LLToolSelect::handleObjectSelection(LLViewerObject *
{
gSelectMgr->selectObjectAndFamily(object);
}
+
+ // restore the zoom to the previously stored values.
+ gSelectMgr->setAgentHUDZoom(target_zoom, current_zoom);
}
if (!gAgent.getFocusOnAvatar() && // if camera not glued to avatar
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index d336876ee1..758455df6a 100644
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -748,13 +748,7 @@ U32 LLPipeline::addObject(LLViewerObject *vobj)
void LLPipeline::resetFrameStats()
{
- mCompilesStat.addValue(sCompiles);
- mLightingChangesStat.addValue(mLightingChanges);
- mGeometryChangesStat.addValue(mGeometryChanges);
mTrianglesDrawnStat.addValue(mTrianglesDrawn/1000.f);
- mVerticesRelitStat.addValue(mVerticesRelit);
- mNumVisibleFacesStat.addValue(mNumVisibleFaces);
- mNumVisibleDrawablesStat.addValue((S32)mVisibleList.size());
mTrianglesDrawn = 0;
sCompiles = 0;
@@ -856,8 +850,6 @@ void LLPipeline::updateMove()
return;
}
- mMoveChangesStat.addValue((F32)mMovedList.size());
-
for (LLDrawable::drawable_set_t::iterator iter = mRetexturedList.begin();
iter != mRetexturedList.end(); ++iter)
{
diff --git a/indra/newview/pipeline.h b/indra/newview/pipeline.h
index 583f40e93d..8b64b63016 100644
--- a/indra/newview/pipeline.h
+++ b/indra/newview/pipeline.h
@@ -349,19 +349,12 @@ public:
BOOL mBackfaceCull;
S32 mTrianglesDrawn;
LLStat mTrianglesDrawnStat;
- LLStat mCompilesStat;
S32 mVerticesRelit;
- LLStat mVerticesRelitStat;
S32 mLightingChanges;
- LLStat mLightingChangesStat;
S32 mGeometryChanges;
- LLStat mGeometryChangesStat;
- LLStat mMoveChangesStat;
S32 mNumVisibleFaces;
- LLStat mNumVisibleFacesStat;
- LLStat mNumVisibleDrawablesStat;
static S32 sCompiles;