From 0041d485b1c5a1b18c9d5b2ae016f2c1e5ea6b8e Mon Sep 17 00:00:00 2001 From: Steven Bennetts Date: Thu, 22 Oct 2009 00:21:18 +0000 Subject: Merging revisions 2129-2144 of https://svn.aws.productengine.com/secondlife/pe/stable-2 into P:\svn\viewer-2.0.0-3, respecting ancestry * Bugs: EXT-1293 EXT-1611 EXT-1613 EXT-1176 EXT-1724 EXT-1186 EXT-1662 EXT-1760 EXT-1720 * Dev: EXT-1575 EXT-1770 EXT-1232 EXT-1234 --- indra/newview/llpanelpick.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'indra/newview/llpanelpick.cpp') diff --git a/indra/newview/llpanelpick.cpp b/indra/newview/llpanelpick.cpp index 664ebfd7a4..cb9f641bf8 100644 --- a/indra/newview/llpanelpick.cpp +++ b/indra/newview/llpanelpick.cpp @@ -38,6 +38,7 @@ #include "llpanel.h" #include "message.h" #include "llagent.h" +#include "llagentpicksinfo.h" #include "llbutton.h" #include "lllineeditor.h" #include "llparcel.h" @@ -310,6 +311,7 @@ LLPanelPickEdit::LLPanelPickEdit() : LLPanelPickInfo() , mLocationChanged(false) , mNeedData(true) + , mNewPick(false) { } @@ -325,6 +327,8 @@ void LLPanelPickEdit::onOpen(const LLSD& key) // creating new Pick if(pick_id.isNull()) { + mNewPick = true; + setAvatarId(gAgent.getID()); resetData(); @@ -356,6 +360,7 @@ void LLPanelPickEdit::onOpen(const LLSD& key) // editing existing pick else { + mNewPick = false; LLPanelPickInfo::onOpen(key); enableSaveButton(false); @@ -463,6 +468,14 @@ void LLPanelPickEdit::sendUpdate() pick_data.enabled = TRUE; LLAvatarPropertiesProcessor::instance().sendPickInfoUpdate(&pick_data); + + if(mNewPick) + { + // Assume a successful create pick operation, make new number of picks + // available immediately. Actual number of picks will be requested in + // LLAvatarPropertiesProcessor::sendPickInfoUpdate and updated upon server respond. + LLAgentPicksInfo::getInstance()->incrementNumberOfPicks(); + } } void LLPanelPickEdit::onPickChanged(LLUICtrl* ctrl) -- cgit v1.3