summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2013-11-26 20:17:23 -0800
committerMerov Linden <merov@lindenlab.com>2013-11-26 20:17:23 -0800
commit66dff9d93bca7c6bdc18d57bb16a40c9753f6711 (patch)
tree3f9f246ebe220846c347e1c4fabbfa2250b89952 /indra/newview
parent1cee31191c049011d0894763044cdcd7b85c00bf (diff)
ACME-1220 : Fixed. Do not accumulate callbacks when reinitializing market place
Diffstat (limited to 'indra/newview')
-rwxr-xr-xindra/newview/llfloateroutbox.cpp12
-rwxr-xr-xindra/newview/llmarketplacefunctions.h1
2 files changed, 8 insertions, 5 deletions
diff --git a/indra/newview/llfloateroutbox.cpp b/indra/newview/llfloateroutbox.cpp
index 90da9ad2c0..de96f75602 100755
--- a/indra/newview/llfloateroutbox.cpp
+++ b/indra/newview/llfloateroutbox.cpp
@@ -297,13 +297,15 @@ void LLFloaterOutbox::initializeMarketPlace()
//
// Initialize the marketplace import API
//
-
LLMarketplaceInventoryImporter& importer = LLMarketplaceInventoryImporter::instance();
- importer.setInitializationErrorCallback(boost::bind(&LLFloaterOutbox::initializationReportError, this, _1, _2));
- importer.setStatusChangedCallback(boost::bind(&LLFloaterOutbox::importStatusChanged, this, _1));
- importer.setStatusReportCallback(boost::bind(&LLFloaterOutbox::importReportResults, this, _1, _2));
- importer.initialize();
+ if (!importer.isInitialized())
+ {
+ importer.setInitializationErrorCallback(boost::bind(&LLFloaterOutbox::initializationReportError, this, _1, _2));
+ importer.setStatusChangedCallback(boost::bind(&LLFloaterOutbox::importStatusChanged, this, _1));
+ importer.setStatusReportCallback(boost::bind(&LLFloaterOutbox::importReportResults, this, _1, _2));
+ importer.initialize();
+ }
}
void LLFloaterOutbox::setStatusString(const std::string& statusString)
diff --git a/indra/newview/llmarketplacefunctions.h b/indra/newview/llmarketplacefunctions.h
index 7f645e2fe2..abe60890a3 100755
--- a/indra/newview/llmarketplacefunctions.h
+++ b/indra/newview/llmarketplacefunctions.h
@@ -90,6 +90,7 @@ public:
void initialize();
bool triggerImport();
bool isImportInProgress() const { return mImportInProgress; }
+ bool isInitialized() const { return mInitialized; }
U32 getMarketPlaceStatus() const { return mMarketPlaceStatus; }
protected: