Assorted DN and RLVa fixes from Phoenix

This commit is contained in:
siana
2011-01-01 06:37:56 +01:00
parent 5c79220049
commit d65a5ffeb7
26 changed files with 377 additions and 148 deletions

View File

@@ -59,9 +59,11 @@ public:
bool isStrict() const { return m_fStrict; }
bool isValid() const { return m_fValid; }
static ERlvBehaviour getBehaviourFromString(const std::string& strBhvr, bool* pfStrict = NULL);
static const std::string& getStringFromBehaviour(ERlvBehaviour eBhvr);
static bool hasStrictVariant(ERlvBehaviour eBhvr);
typedef std::map<std::string, ERlvBehaviour> bhvr_map_t;
static ERlvBehaviour getBehaviourFromString(const std::string& strBhvr, bool* pfStrict = NULL);
static bool getCommands(bhvr_map_t& cmdList, const std::string& strMatch);
static const std::string& getStringFromBehaviour(ERlvBehaviour eBhvr);
static bool hasStrictVariant(ERlvBehaviour eBhvr);
static void initLookupTable();
protected:
@@ -86,8 +88,7 @@ protected:
std::string m_strParam;
ERlvParamType m_eParamType;
typedef std::map<std::string, ERlvBehaviour> RlvBhvrTable;
static RlvBhvrTable m_BhvrMap;
static bhvr_map_t m_BhvrMap;
friend class RlvHandler;
};
@@ -317,7 +318,9 @@ protected:
public:
void addNotify(const LLUUID& idObj, S32 nChannel, const std::string& strFilter)
{
m_Notifications.insert(std::pair<LLUUID, notifyData>(idObj, notifyData(nChannel, strFilter)));
//m_Notifications.insert(std::pair<LLUUID, notifyData>(idObj, notifyData(nChannel, strFilter)));
// RLVa-HACK: see RlvBehaviourNotifyHandler::changed()
m_NotificationsDelayed.insert(std::pair<LLUUID, notifyData>(idObj, notifyData(nChannel, strFilter)));
}
void removeNotify(const LLUUID& idObj, S32 nChannel, const std::string& strFilter)
{
@@ -330,8 +333,6 @@ public:
break;
}
}
if (m_Notifications.empty())
delete this; // Delete ourself if we have nothing to do
}
void sendNotification(const std::string& strText, const std::string& strSuffix = LLStringUtil::null) const;
protected:
@@ -345,6 +346,7 @@ protected:
notifyData(S32 channel, const std::string& filter) : nChannel(channel), strFilter(filter) {}
};
std::multimap<LLUUID, notifyData> m_Notifications;
std::multimap<LLUUID, notifyData> m_NotificationsDelayed;
};
// ============================================================================