summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2015-01-23 04:10:40 -0800
committerNat Goodspeed <nat@lindenlab.com>2015-01-23 04:10:40 -0800
commit60727c97f430cd392bba1f9122dc0fa8de48005f (patch)
tree36ea1c0c5cd0fa1bc43b8a8aca77af495f7fc0bc /indra
parentc301db972e975dabe96f6e70c27aa07b0bf51b1f (diff)
parentc93648e3d2a5a70a6fc8c0de46d45580798b0386 (diff)
Automated merge with http://bitbucket.org/lindenlab/viewer-tools-update
Diffstat (limited to 'indra')
-rwxr-xr-xindra/newview/lllogininstance.cpp16
-rwxr-xr-xindra/newview/lllogininstance.h1
-rwxr-xr-xindra/newview/tests/lllogininstance_test.cpp12
3 files changed, 12 insertions, 17 deletions
diff --git a/indra/newview/lllogininstance.cpp b/indra/newview/lllogininstance.cpp
index 03ef11d8e5..b4d0bb6823 100755
--- a/indra/newview/lllogininstance.cpp
+++ b/indra/newview/lllogininstance.cpp
@@ -58,7 +58,6 @@
#include "llmachineid.h"
#include "llupdaterservice.h"
#include "llevents.h"
-#include "llnotificationsutil.h"
#include "llappviewer.h"
#include <boost/scoped_ptr.hpp>
@@ -75,9 +74,14 @@ namespace {
{
public:
MandatoryUpdateMachine(LLLoginInstance & loginInstance, LLUpdaterService & updaterService);
-
+
void start(void);
-
+
+ LLNotificationsInterface& getNotificationsInterface() const
+ {
+ return mLoginInstance.getNotificationsInterface();
+ }
+
private:
class State;
class CheckingForUpdate;
@@ -87,6 +91,7 @@ namespace {
class WaitingForDownload;
boost::scoped_ptr<State> mState;
+ LLLoginInstance & mLoginInstance;
LLUpdaterService & mUpdaterService;
void setCurrentState(State * newState);
@@ -192,6 +197,7 @@ std::string construct_start_string();
MandatoryUpdateMachine::MandatoryUpdateMachine(LLLoginInstance & loginInstance, LLUpdaterService & updaterService):
+ mLoginInstance(loginInstance),
mUpdaterService(updaterService)
{
; // No op.
@@ -326,7 +332,7 @@ MandatoryUpdateMachine::Error::Error(MandatoryUpdateMachine & machine):
void MandatoryUpdateMachine::Error::enter(void)
{
LL_INFOS() << "entering error" << LL_ENDL;
- LLNotificationsUtil::add("FailedRequiredUpdateInstall", LLSD(), LLSD(), boost::bind(&MandatoryUpdateMachine::Error::onButtonClicked, this, _1, _2));
+ mMachine.getNotificationsInterface().add("FailedRequiredUpdateInstall", LLSD(), LLSD(), boost::bind(&MandatoryUpdateMachine::Error::onButtonClicked, this, _1, _2));
}
@@ -382,7 +388,7 @@ MandatoryUpdateMachine::StartingUpdaterService::StartingUpdaterService(Mandatory
void MandatoryUpdateMachine::StartingUpdaterService::enter(void)
{
LL_INFOS() << "entering start update service" << LL_ENDL;
- LLNotificationsUtil::add("UpdaterServiceNotRunning", LLSD(), LLSD(), boost::bind(&MandatoryUpdateMachine::StartingUpdaterService::onButtonClicked, this, _1, _2));
+ mMachine.getNotificationsInterface().add("UpdaterServiceNotRunning", LLSD(), LLSD(), boost::bind(&MandatoryUpdateMachine::StartingUpdaterService::onButtonClicked, this, _1, _2));
}
diff --git a/indra/newview/lllogininstance.h b/indra/newview/lllogininstance.h
index b0247da7c8..c6773bbf68 100755
--- a/indra/newview/lllogininstance.h
+++ b/indra/newview/lllogininstance.h
@@ -70,6 +70,7 @@ public:
void setPlatformInfo(const std::string platform, const std::string platform_version);
void setNotificationsInterface(LLNotificationsInterface* ni) { mNotifications = ni; }
+ LLNotificationsInterface& getNotificationsInterface() const { return *mNotifications; }
typedef boost::function<void()> UpdaterLauncherCallback;
void setUpdaterLauncher(const UpdaterLauncherCallback& ulc) { mUpdaterLauncher = ulc; }
diff --git a/indra/newview/tests/lllogininstance_test.cpp b/indra/newview/tests/lllogininstance_test.cpp
index 9ee6403739..1b0334498e 100755
--- a/indra/newview/tests/lllogininstance_test.cpp
+++ b/indra/newview/tests/lllogininstance_test.cpp
@@ -193,14 +193,6 @@ void LLAppViewer::forceQuit(void) {}
LLAppViewer * LLAppViewer::sInstance = 0;
//-----------------------------------------------------------------------------
-#include "llnotificationsutil.h"
-LLNotificationPtr LLNotificationsUtil::add(const std::string& name,
- const LLSD& substitutions,
- const LLSD& payload,
- boost::function<void (const LLSD&, const LLSD&)> functor) { return LLNotificationPtr((LLNotification*)0); }
-
-
-//-----------------------------------------------------------------------------
#include "llupdaterservice.h"
std::string const & LLUpdaterService::pumpName(void)
@@ -488,8 +480,6 @@ namespace tut
template<> template<>
void lllogininstance_object::test<3>()
{
- skip("test fails with Xcode 6, skipping");
-
set_test_name("Test Mandatory Update User Accepts");
// Part 1 - Mandatory Update, with User accepts response.
@@ -517,8 +507,6 @@ namespace tut
template<> template<>
void lllogininstance_object::test<4>()
{
- skip("test fails with Xcode 6, skipping");
-
set_test_name("Test Mandatory Update User Decline");
// Test connect with update needed.