diff options
Diffstat (limited to 'indra/newview/llpanelgroupnotices.cpp')
-rw-r--r-- | indra/newview/llpanelgroupnotices.cpp | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/indra/newview/llpanelgroupnotices.cpp b/indra/newview/llpanelgroupnotices.cpp index a824025723..c2a6828837 100644 --- a/indra/newview/llpanelgroupnotices.cpp +++ b/indra/newview/llpanelgroupnotices.cpp @@ -38,6 +38,7 @@ #include "llinventory.h" #include "llviewerinventory.h" +#include "llinventoryfunctions.h" #include "llinventorymodel.h" #include "llfloaterinventory.h" #include "llagent.h" @@ -57,7 +58,7 @@ #include "roles_constants.h" #include "llviewerwindow.h" #include "llviewermessage.h" -#include "llnotifications.h" +#include "llnotificationsutil.h" static LLRegisterPanelClassWrapper<LLPanelGroupNotices> t_panel_group_notices("panel_group_notices"); @@ -304,6 +305,9 @@ BOOL LLPanelGroupNotices::postBuild() void LLPanelGroupNotices::activate() { + if(mNoticesList) + mNoticesList->deleteAllItems(); + BOOL can_send = gAgent.hasPowerInGroup(mGroupID,GP_NOTICES_SEND); BOOL can_receive = gAgent.hasPowerInGroup(mGroupID,GP_NOTICES_RECEIVE); @@ -372,7 +376,7 @@ void LLPanelGroupNotices::onClickSendMessage(void* data) if (self->mCreateSubject->getText().empty()) { // Must supply a subject - LLNotifications::instance().add("MustSpecifyGroupNoticeSubject"); + LLNotificationsUtil::add("MustSpecifyGroupNoticeSubject"); return; } send_group_notice( @@ -510,6 +514,9 @@ void LLPanelGroupNotices::processNotices(LLMessageSystem* msg) S32 i=0; S32 count = msg->getNumberOfBlocks("Data"); + + mNoticesList->setEnabled(TRUE); + for (;i<count;++i) { msg->getUUID("Data","NoticeID",id,i); @@ -646,6 +653,9 @@ void LLPanelGroupNotices::setGroupID(const LLUUID& id) LLGroupDropTarget* target = getChild<LLGroupDropTarget> ("drop_target"); target->setPanel (this); target->setGroup (mGroupID); + + if(mViewMessage) + mViewMessage->clear(); activate(); } |