From a2e22732f195dc075a733c79f15156752f522a43 Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Tue, 30 Jul 2013 19:13:45 -0700 Subject: Summer cleaning - removed a lot of llcommon dependencies to speed up build times consolidated most indra-specific constants in llcommon under indra_constants.h fixed issues with operations on mixed unit types (implicit and explicit) made LL_INFOS() style macros variadic in order to subsume other logging methods such as ll_infos added optional tag output to error recorders --- indra/newview/llviewerparcelmgr.cpp | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'indra/newview/llviewerparcelmgr.cpp') diff --git a/indra/newview/llviewerparcelmgr.cpp b/indra/newview/llviewerparcelmgr.cpp index 4cdb568d17..b25d042d28 100755 --- a/indra/newview/llviewerparcelmgr.cpp +++ b/indra/newview/llviewerparcelmgr.cpp @@ -36,7 +36,6 @@ #include "llnotifications.h" #include "llnotificationsutil.h" #include "llparcel.h" -#include "llsecondlifeurls.h" #include "message.h" #include "llfloaterreg.h" @@ -591,13 +590,13 @@ void LLViewerParcelMgr::deselectLand() void LLViewerParcelMgr::addObserver(LLParcelObserver* observer) { - mObservers.put(observer); + mObservers.push_back(observer); } void LLViewerParcelMgr::removeObserver(LLParcelObserver* observer) { - mObservers.removeObj(observer); + vector_replace_with_last(mObservers, observer); } @@ -606,16 +605,16 @@ void LLViewerParcelMgr::removeObserver(LLParcelObserver* observer) // from the list. void LLViewerParcelMgr::notifyObservers() { - LLDynamicArray observers; - S32 count = mObservers.count(); + std::vector observers; + S32 count = mObservers.size(); S32 i; for(i = 0; i < count; ++i) { - observers.put(mObservers.get(i)); + observers.push_back(mObservers.at(i)); } for(i = 0; i < count; ++i) { - observers.get(i)->changed(); + observers.at(i)->changed(); } } -- cgit v1.2.3 From e340009fc59d59e59b2e8d903a884acb76b178eb Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Fri, 9 Aug 2013 17:11:19 -0700 Subject: second phase summer cleaning replace llinfos, lldebugs, etc with new LL_INFOS(), LL_DEBUGS(), etc. --- indra/newview/llviewerparcelmgr.cpp | 50 ++++++++++++++++++------------------- 1 file changed, 25 insertions(+), 25 deletions(-) (limited to 'indra/newview/llviewerparcelmgr.cpp') diff --git a/indra/newview/llviewerparcelmgr.cpp b/indra/newview/llviewerparcelmgr.cpp index b25d042d28..10a3cd517c 100755 --- a/indra/newview/llviewerparcelmgr.cpp +++ b/indra/newview/llviewerparcelmgr.cpp @@ -197,22 +197,22 @@ LLViewerParcelMgr::~LLViewerParcelMgr() void LLViewerParcelMgr::dump() { - llinfos << "Parcel Manager Dump" << llendl; - llinfos << "mSelected " << S32(mSelected) << llendl; - llinfos << "Selected parcel: " << llendl; - llinfos << mWestSouth << " to " << mEastNorth << llendl; + LL_INFOS() << "Parcel Manager Dump" << LL_ENDL; + LL_INFOS() << "mSelected " << S32(mSelected) << LL_ENDL; + LL_INFOS() << "Selected parcel: " << LL_ENDL; + LL_INFOS() << mWestSouth << " to " << mEastNorth << LL_ENDL; mCurrentParcel->dump(); - llinfos << "banning " << mCurrentParcel->mBanList.size() << llendl; + LL_INFOS() << "banning " << mCurrentParcel->mBanList.size() << LL_ENDL; access_map_const_iterator cit = mCurrentParcel->mBanList.begin(); access_map_const_iterator end = mCurrentParcel->mBanList.end(); for ( ; cit != end; ++cit) { - llinfos << "ban id " << (*cit).first << llendl; + LL_INFOS() << "ban id " << (*cit).first << LL_ENDL; } - llinfos << "Hover parcel:" << llendl; + LL_INFOS() << "Hover parcel:" << LL_ENDL; mHoverParcel->dump(); - llinfos << "Agent parcel:" << llendl; + LL_INFOS() << "Agent parcel:" << LL_ENDL; mAgentParcel->dump(); } @@ -947,7 +947,7 @@ void LLViewerParcelMgr::sendParcelGodForceOwner(const LLUUID& owner_id) return; } - llinfos << "Claiming " << mWestSouth << " to " << mEastNorth << llendl; + LL_INFOS() << "Claiming " << mWestSouth << " to " << mEastNorth << LL_ENDL; // BUG: Only works for the region containing mWestSouthBottom LLVector3d east_north_region_check( mEastNorth ); @@ -970,7 +970,7 @@ void LLViewerParcelMgr::sendParcelGodForceOwner(const LLUUID& owner_id) return; } - llinfos << "Region " << region->getOriginGlobal() << llendl; + LL_INFOS() << "Region " << region->getOriginGlobal() << LL_ENDL; LLSD payload; payload["owner_id"] = owner_id; @@ -1110,8 +1110,8 @@ LLViewerParcelMgr::ParcelBuyInfo* LLViewerParcelMgr::setupParcelBuy( if (is_claim) { - llinfos << "Claiming " << mWestSouth << " to " << mEastNorth << llendl; - llinfos << "Region " << region->getOriginGlobal() << llendl; + LL_INFOS() << "Claiming " << mWestSouth << " to " << mEastNorth << LL_ENDL; + LL_INFOS() << "Region " << region->getOriginGlobal() << LL_ENDL; // BUG: Only works for the region containing mWestSouthBottom LLVector3d east_north_region_check( mEastNorth ); @@ -1281,7 +1281,7 @@ void LLViewerParcelMgr::sendParcelPropertiesUpdate(LLParcel* parcel, bool use_ag LLViewerRegion *region = use_agent_region ? gAgent.getRegion() : LLWorld::getInstance()->getRegionFromPosGlobal( mWestSouth ); if (!region) return; - //llinfos << "found region: " << region->getName() << llendl; + //LL_INFOS() << "found region: " << region->getName() << LL_ENDL; LLSD body; std::string url = region->getCapability("ParcelPropertiesUpdate"); @@ -1291,8 +1291,8 @@ void LLViewerParcelMgr::sendParcelPropertiesUpdate(LLParcel* parcel, bool use_ag U32 message_flags = 0x01; body["flags"] = ll_sd_from_U32(message_flags); parcel->packMessage(body); - llinfos << "Sending parcel properties update via capability to: " - << url << llendl; + LL_INFOS() << "Sending parcel properties update via capability to: " + << url << LL_ENDL; LLHTTPClient::post(url, body, new LLHTTPClient::Responder()); } else @@ -1386,7 +1386,7 @@ void LLViewerParcelMgr::processParcelOverlay(LLMessageSystem *msg, void **user) if (packed_overlay_size <= 0) { - llwarns << "Overlay size " << packed_overlay_size << llendl; + LL_WARNS() << "Overlay size " << packed_overlay_size << LL_ENDL; return; } @@ -1394,8 +1394,8 @@ void LLViewerParcelMgr::processParcelOverlay(LLMessageSystem *msg, void **user) S32 expected_size = parcels_per_edge * parcels_per_edge / PARCEL_OVERLAY_CHUNKS; if (packed_overlay_size != expected_size) { - llwarns << "Got parcel overlay size " << packed_overlay_size - << " expecting " << expected_size << llendl; + LL_WARNS() << "Got parcel overlay size " << packed_overlay_size + << " expecting " << expected_size << LL_ENDL; return; } @@ -1461,7 +1461,7 @@ void LLViewerParcelMgr::processParcelProperties(LLMessageSystem *msg, void **use if (request_result == PARCEL_RESULT_NO_DATA) { // no valid parcel data - llinfos << "no valid parcel data" << llendl; + LL_INFOS() << "no valid parcel data" << LL_ENDL; return; } @@ -1493,9 +1493,9 @@ void LLViewerParcelMgr::processParcelProperties(LLMessageSystem *msg, void **use } else { - llinfos << "out of order agent parcel sequence id " << sequence_id + LL_INFOS() << "out of order agent parcel sequence id " << sequence_id << " last good " << parcel_mgr.mAgentParcelSequenceID - << llendl; + << LL_ENDL; return; } @@ -1743,7 +1743,7 @@ void LLViewerParcelMgr::processParcelProperties(LLMessageSystem *msg, void **use } else { - llinfos << "Stopping parcel music (invalid audio stream URL)" << llendl; + LL_INFOS() << "Stopping parcel music (invalid audio stream URL)" << LL_ENDL; // clears the URL // null value causes fade out LLViewerAudio::getInstance()->startInternetStreamWithAutoFade(LLStringUtil::null); @@ -1751,7 +1751,7 @@ void LLViewerParcelMgr::processParcelProperties(LLMessageSystem *msg, void **use } else if (!gAudiop->getInternetStreamURL().empty()) { - llinfos << "Stopping parcel music (parcel stream URL is empty)" << llendl; + LL_INFOS() << "Stopping parcel music (parcel stream URL is empty)" << LL_ENDL; // null value causes fade out LLViewerAudio::getInstance()->startInternetStreamWithAutoFade(LLStringUtil::null); } @@ -1779,7 +1779,7 @@ void LLViewerParcelMgr::optionally_start_music(const std::string& music_url) gSavedSettings.getBOOL(LLViewerMedia::AUTO_PLAY_MEDIA_SETTING) && gSavedSettings.getBOOL("MediaTentativeAutoPlay"))) { - llinfos << "Starting parcel music " << music_url << llendl; + LL_INFOS() << "Starting parcel music " << music_url << LL_ENDL; LLViewerAudio::getInstance()->startInternetStreamWithAutoFade(music_url); } else @@ -1808,7 +1808,7 @@ void LLViewerParcelMgr::processParcelAccessListReply(LLMessageSystem *msg, void if (parcel_id != parcel->getLocalID()) { LL_WARNS_ONCE("") << "processParcelAccessListReply for parcel " << parcel_id - << " which isn't the selected parcel " << parcel->getLocalID()<< llendl; + << " which isn't the selected parcel " << parcel->getLocalID()<< LL_ENDL; return; } -- cgit v1.2.3