diff options
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/CMakeLists.txt | 3 | ||||
-rw-r--r-- | indra/newview/llcallfloater.cpp | 3 | ||||
-rw-r--r-- | indra/newview/llfolderview.cpp | 12 | ||||
-rw-r--r-- | indra/newview/llfolderviewitem.cpp | 6 | ||||
-rw-r--r-- | indra/newview/llfolderviewitem.h | 1 | ||||
-rw-r--r-- | indra/newview/llpanelimcontrolpanel.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llparticipantlist.cpp | 12 | ||||
-rw-r--r-- | indra/newview/llparticipantlist.h | 4 | ||||
-rw-r--r-- | indra/newview/llspeakers.cpp | 14 | ||||
-rw-r--r-- | indra/newview/llspeakers.h | 7 |
10 files changed, 46 insertions, 18 deletions
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index f85b943c70..69bf1f15a1 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -1345,7 +1345,9 @@ if (WINDOWS) DXGUID_LIBRARY ) +# see EXP-1765 - theory is opengl32.lib needs to be included before gdi32.lib (windows libs) set(viewer_LIBRARIES + opengl32 ${WINDOWS_LIBRARIES} comdlg32 ${DINPUT_LIBRARY} @@ -1355,7 +1357,6 @@ if (WINDOWS) odbccp32 ole32 oleaut32 - opengl32 shell32 Vfw32 winspool diff --git a/indra/newview/llcallfloater.cpp b/indra/newview/llcallfloater.cpp index e3217668c5..f2375bfa4f 100644 --- a/indra/newview/llcallfloater.cpp +++ b/indra/newview/llcallfloater.cpp @@ -188,7 +188,7 @@ void LLCallFloater::draw() // Need to resort the participant list if it's in sort by recent speaker order. if (mParticipants) - mParticipants->updateRecentSpeakersOrder(); + mParticipants->update(); LLFloater::draw(); } @@ -333,6 +333,7 @@ void LLCallFloater::refreshParticipantList() if (!non_avatar_caller) { + llassert(mParticipants == NULL); // check for possible memory leak mParticipants = new LLParticipantList(mSpeakerManager, mAvatarList, true, mVoiceType != VC_GROUP_CHAT && mVoiceType != VC_AD_HOC_CHAT, false); mParticipants->setValidateSpeakerCallback(boost::bind(&LLCallFloater::validateSpeaker, this, _1)); const U32 speaker_sort_order = gSavedSettings.getU32("SpeakerParticipantDefaultOrder"); diff --git a/indra/newview/llfolderview.cpp b/indra/newview/llfolderview.cpp index e0d7d67f7d..79c987fa37 100644 --- a/indra/newview/llfolderview.cpp +++ b/indra/newview/llfolderview.cpp @@ -388,7 +388,7 @@ void LLFolderView::setOpenArrangeRecursively(BOOL openitem, ERecurseType recurse static LLFastTimer::DeclareTimer FTM_ARRANGE("Arrange"); -// This view grows and shinks to enclose all of its children items and folders. +// This view grows and shrinks to enclose all of its children items and folders. S32 LLFolderView::arrange( S32* unused_width, S32* unused_height, S32 filter_generation ) { if (getListener()->getUUID().notNull()) @@ -527,15 +527,15 @@ void LLFolderView::reshape(S32 width, S32 height, BOOL called_from_parent) LLView::reshape(width, height, called_from_parent); scroll_rect = mScrollContainer->getContentWindowRect(); } - width = llmax(mMinWidth, scroll_rect.getWidth()); + width = llmax(mMinWidth, scroll_rect.getWidth()); height = llmax(mRunningHeight, scroll_rect.getHeight()); - // restrict width with scroll container's width - if (mUseEllipses) + // Restrict width within scroll container's width + if (mUseEllipses && mScrollContainer) + { width = scroll_rect.getWidth(); - + } LLView::reshape(width, height, called_from_parent); - mReshapeSignal(mSelectedItems, FALSE); } diff --git a/indra/newview/llfolderviewitem.cpp b/indra/newview/llfolderviewitem.cpp index 9944a9dd3d..734adbc648 100644 --- a/indra/newview/llfolderviewitem.cpp +++ b/indra/newview/llfolderviewitem.cpp @@ -410,8 +410,8 @@ BOOL LLFolderViewItem::addToFolder(LLFolderViewFolder* folder, LLFolderView* roo } -// Finds width and height of this object and it's children. Also -// makes sure that this view and it's children are the right size. +// Finds width and height of this object and its children. Also +// makes sure that this view and its children are the right size. S32 LLFolderViewItem::arrange( S32* width, S32* height, S32 filter_generation) { const Params& p = LLUICtrlFactory::getDefaultParams<LLFolderViewItem>(); @@ -423,7 +423,7 @@ S32 LLFolderViewItem::arrange( S32* width, S32* height, S32 filter_generation) : 0; if (mLabelWidthDirty) { - mLabelWidth = ARROW_SIZE + TEXT_PAD + ICON_WIDTH + ICON_PAD + getLabelFontForStyle(mLabelStyle)->getWidth(mLabel) + getLabelFontForStyle(mLabelStyle)->getWidth(mLabelSuffix); + mLabelWidth = ARROW_SIZE + TEXT_PAD + ICON_WIDTH + ICON_PAD + getLabelFontForStyle(mLabelStyle)->getWidth(mLabel) + getLabelFontForStyle(mLabelStyle)->getWidth(mLabelSuffix) + TEXT_PAD_RIGHT; mLabelWidthDirty = false; } diff --git a/indra/newview/llfolderviewitem.h b/indra/newview/llfolderviewitem.h index 2fc79f5765..4e8dc2da16 100644 --- a/indra/newview/llfolderviewitem.h +++ b/indra/newview/llfolderviewitem.h @@ -114,6 +114,7 @@ public: static const S32 ICON_PAD = 2; static const S32 ICON_WIDTH = 16; static const S32 TEXT_PAD = 1; + static const S32 TEXT_PAD_RIGHT = 4; static const S32 ARROW_SIZE = 12; static const S32 MAX_FOLDER_ITEM_OVERLAP = 2; // animation parameters diff --git a/indra/newview/llpanelimcontrolpanel.cpp b/indra/newview/llpanelimcontrolpanel.cpp index 0295ad151f..eda0749cdb 100644 --- a/indra/newview/llpanelimcontrolpanel.cpp +++ b/indra/newview/llpanelimcontrolpanel.cpp @@ -374,7 +374,7 @@ void LLPanelGroupControlPanel::draw() { // Need to resort the participant list if it's in sort by recent speaker order. if (mParticipantList) - mParticipantList->updateRecentSpeakersOrder(); + mParticipantList->update(); LLPanelChatControlPanel::draw(); } diff --git a/indra/newview/llparticipantlist.cpp b/indra/newview/llparticipantlist.cpp index 5c95e805ce..975a6c67d8 100644 --- a/indra/newview/llparticipantlist.cpp +++ b/indra/newview/llparticipantlist.cpp @@ -390,7 +390,10 @@ void LLParticipantList::onAvatarListRefreshed(LLUICtrl* ctrl, const LLSD& param) { const LLPointer<LLSpeaker>& speakerp = *it; - update_speaker_indicator(list, speakerp->mID, speakerp->mModeratorMutedVoice); + if (speakerp->mStatus == LLSpeaker::STATUS_TEXT_ONLY) + { + update_speaker_indicator(list, speakerp->mID, speakerp->mModeratorMutedVoice); + } } } } @@ -466,12 +469,12 @@ void LLParticipantList::setValidateSpeakerCallback(validate_speaker_callback_t c mValidateSpeakerCallback = cb; } -void LLParticipantList::updateRecentSpeakersOrder() +void LLParticipantList::update() { + mSpeakerMgr->update(true); + if (E_SORT_BY_RECENT_SPEAKERS == getSortOrder() && !isHovered()) { - // Need to update speakers to sort list correctly - mSpeakerMgr->update(true); // Resort avatar list sort(); } @@ -760,6 +763,7 @@ void LLParticipantList::LLParticipantListMenu::toggleMute(const LLSD& userdata, LLPointer<LLSpeaker> speakerp = mParent.mSpeakerMgr->findSpeaker(speaker_id); if (speakerp.isNull()) { + LL_WARNS("Speakers") << "Speaker " << speaker_id << " not found" << llendl; return; } LLAvatarListItem* item = dynamic_cast<LLAvatarListItem*>(mParent.mAvatarList->getItemByValue(speaker_id)); diff --git a/indra/newview/llparticipantlist.h b/indra/newview/llparticipantlist.h index a001d29b67..53966c15fe 100644 --- a/indra/newview/llparticipantlist.h +++ b/indra/newview/llparticipantlist.h @@ -72,9 +72,9 @@ public: const EParticipantSortOrder getSortOrder() const; /** - * Refreshes the participant list if it's in sort by recent speaker order. + * Refreshes the participant list. */ - void updateRecentSpeakersOrder(); + void update(); /** * Set a callback to be called before adding a speaker. Invalid speakers will not be added. diff --git a/indra/newview/llspeakers.cpp b/indra/newview/llspeakers.cpp index c588bd8fb4..07d2f1ad6f 100644 --- a/indra/newview/llspeakers.cpp +++ b/indra/newview/llspeakers.cpp @@ -272,6 +272,7 @@ LLPointer<LLSpeaker> LLSpeakerMgr::setSpeaker(const LLUUID& id, const std::strin speakerp->mStatus = status; mSpeakers.insert(std::make_pair(speakerp->mID, speakerp)); mSpeakersSorted.push_back(speakerp); + LL_DEBUGS("Speakers") << "Added speaker " << id << llendl; fireEvent(new LLSpeakerListChangeEvent(this, speakerp->mID), "add"); } else @@ -290,6 +291,10 @@ LLPointer<LLSpeaker> LLSpeakerMgr::setSpeaker(const LLUUID& id, const std::strin speakerp->lookupName(); } } + else + { + LL_WARNS("Speakers") << "Speaker " << id << " not found" << llendl; + } } mSpeakerDelayRemover->unsetActionTimer(speakerp->mID); @@ -354,6 +359,7 @@ void LLSpeakerMgr::update(BOOL resort_ok) if (moderator_muted_voice != speakerp->mModeratorMutedVoice) { speakerp->mModeratorMutedVoice = moderator_muted_voice; + LL_DEBUGS("Speakers") << (speakerp->mModeratorMutedVoice? "Muted" : "Umuted") << " speaker " << speaker_id<< llendl; speakerp->fireEvent(new LLSpeakerVoiceModerationEvent(speakerp)); } @@ -484,6 +490,7 @@ bool LLSpeakerMgr::removeSpeaker(const LLUUID& speaker_id) } } + LL_DEBUGS("Speakers") << "Removed speaker " << speaker_id << llendl; fireEvent(new LLSpeakerListChangeEvent(this, speaker_id), "remove"); update(TRUE); @@ -595,7 +602,10 @@ void LLIMSpeakerMgr::setSpeakers(const LLSD& speakers) speaker_it->second["mutes"]["text"]; // Fire event only if moderator changed if ( is_moderator != speakerp->mIsModerator ) + { + LL_DEBUGS("Speakers") << "Speaker " << agent_id << (is_moderator ? "is now" : "no longer is") << " a moderator" << llendl; fireEvent(new LLSpeakerUpdateModeratorEvent(speakerp), "update_moderator"); + } } } } @@ -665,7 +675,10 @@ void LLIMSpeakerMgr::updateSpeakers(const LLSD& update) speakerp->mIsModerator = agent_info["is_moderator"]; // Fire event only if moderator changed if ( is_moderator != speakerp->mIsModerator ) + { + LL_DEBUGS("Speakers") << "Speaker " << agent_id << (is_moderator ? "is now" : "no longer is") << " a moderator" << llendl; fireEvent(new LLSpeakerUpdateModeratorEvent(speakerp), "update_moderator"); + } } if (agent_info.has("mutes")) @@ -857,6 +870,7 @@ void LLActiveSpeakerMgr::updateSpeakerList() // always populate from active voice channel if (LLVoiceChannel::getCurrentVoiceChannel() != mVoiceChannel) //MA: seems this is always false { + LL_DEBUGS("Speakers") << "Removed all speakers" << llendl; fireEvent(new LLSpeakerListChangeEvent(this, LLUUID::null), "clear"); mSpeakers.clear(); mSpeakersSorted.clear(); diff --git a/indra/newview/llspeakers.h b/indra/newview/llspeakers.h index 35f2ee7056..b9358cf37c 100644 --- a/indra/newview/llspeakers.h +++ b/indra/newview/llspeakers.h @@ -208,6 +208,8 @@ private: class LLSpeakerMgr : public LLOldEvents::LLObservable { + LOG_CLASS(LLSpeakerMgr); + public: LLSpeakerMgr(LLVoiceChannel* channelp); virtual ~LLSpeakerMgr(); @@ -271,6 +273,8 @@ protected: class LLIMSpeakerMgr : public LLSpeakerMgr { + LOG_CLASS(LLIMSpeakerMgr); + public: LLIMSpeakerMgr(LLVoiceChannel* channel); @@ -320,6 +324,8 @@ protected: class LLActiveSpeakerMgr : public LLSpeakerMgr, public LLSingleton<LLActiveSpeakerMgr> { + LOG_CLASS(LLActiveSpeakerMgr); + public: LLActiveSpeakerMgr(); protected: @@ -328,6 +334,7 @@ protected: class LLLocalSpeakerMgr : public LLSpeakerMgr, public LLSingleton<LLLocalSpeakerMgr> { + LOG_CLASS(LLLocalSpeakerMgr); public: LLLocalSpeakerMgr(); ~LLLocalSpeakerMgr (); |