FSData refactor: LLSingleton

Use LLSingleton instead of home brewed one.
Techwolf Lupindo 2011-11-18 22:05:45 -05:00
parent 2b2a4b2cfe
commit abf40530b6
2 changed files with 2 additions and 30 deletions

View File

@ -108,35 +108,11 @@ private:
};
std::string FSData::blacklist_version;
LLSD FSData::blocked_login_info = 0;
std::map<LLSD, std::string> legacy_tags;
BOOL FSData::msDataDone = FALSE;
FSData* FSData::sInstance;
FSData::FSData()
{
sInstance = this;
}
FSData::~FSData()
{
sInstance = NULL;
}
FSData* FSData::getInstance()
{
if(sInstance)return sInstance;
else
{
sInstance = new FSData();
return sInstance;
}
}
void FSData::startDownload()
{

View File

@ -32,6 +32,7 @@
#include <map>
#include <llsd.h>
#include <llinstantmessage.h>
#include "llsingleton.h"
struct LLSDcontent
{
@ -44,15 +45,10 @@ struct FSDataAgent
bool developer;
};
class FSData
class FSData : public LLSingleton<FSData>
{
LOG_CLASS(FSData);
FSData();
~FSData();
static FSData* sInstance;
public:
static FSData* getInstance();
void startDownload();
void processData(U32 status, std::string body);
void downloadClientTags();