Automated merge with ssh://hg.lindenlab.com/viewer/viewer-2-0
commit
c189943583
|
|
@ -30,6 +30,9 @@
|
|||
* $/LicenseInfo$
|
||||
*/
|
||||
|
||||
// *NOTE: this module is a copy-paste of llui/llalertdialog.h
|
||||
// Can we re-implement this as a subclass of LLAlertDialog and
|
||||
// avoid all this code duplication? It already caused EXT-2232.
|
||||
|
||||
#include "llviewerprecompiledheaders.h" // must be first include
|
||||
|
||||
|
|
@ -56,7 +59,7 @@ const F32 DEFAULT_BUTTON_DELAY = 0.5f;
|
|||
const S32 MSG_PAD = 8;
|
||||
|
||||
/*static*/ LLControlGroup* LLToastAlertPanel::sSettings = NULL;
|
||||
/*static*/ LLToastAlertPanel::URLLoader* LLToastAlertPanel::sURLLoader;
|
||||
/*static*/ LLAlertURLLoader* LLToastAlertPanel::sURLLoader;
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Private methods
|
||||
|
|
|
|||
|
|
@ -30,6 +30,10 @@
|
|||
* $/LicenseInfo$
|
||||
*/
|
||||
|
||||
// *NOTE: this module is a copy-paste of llui/llalertdialog.h
|
||||
// Can we re-implement this as a subclass of LLAlertDialog and
|
||||
// avoid all this code duplication? It already caused EXT-2232.
|
||||
|
||||
#ifndef LL_TOASTALERTPANEL_H
|
||||
#define LL_TOASTALERTPANEL_H
|
||||
|
||||
|
|
@ -37,6 +41,7 @@
|
|||
#include "llfloater.h"
|
||||
#include "llui.h"
|
||||
#include "llnotifications.h"
|
||||
#include "llalertdialog.h"
|
||||
|
||||
class LLButton;
|
||||
class LLCheckBoxCtrl;
|
||||
|
|
@ -57,14 +62,7 @@ class LLToastAlertPanel
|
|||
public:
|
||||
typedef bool (*display_callback_t)(S32 modal);
|
||||
|
||||
class URLLoader
|
||||
{
|
||||
public:
|
||||
virtual void load(const std::string& url, bool force_open_externally = 0 ) = 0;
|
||||
virtual ~URLLoader() {}
|
||||
};
|
||||
|
||||
static void setURLLoader(URLLoader* loader)
|
||||
static void setURLLoader(LLAlertURLLoader* loader)
|
||||
{
|
||||
sURLLoader = loader;
|
||||
}
|
||||
|
|
@ -97,7 +95,7 @@ private:
|
|||
BOOL hasTitleBar() const;
|
||||
|
||||
private:
|
||||
static URLLoader* sURLLoader;
|
||||
static LLAlertURLLoader* sURLLoader;
|
||||
static LLControlGroup* sSettings;
|
||||
|
||||
struct ButtonData
|
||||
|
|
|
|||
|
|
@ -43,8 +43,9 @@
|
|||
#include "llfloatermediabrowser.h"
|
||||
#include "llfloaterreg.h"
|
||||
#include "llalertdialog.h"
|
||||
#include "lltoastalertpanel.h"
|
||||
|
||||
class URLLoader : public LLAlertDialog::URLLoader
|
||||
class URLLoader : public LLAlertURLLoader
|
||||
{
|
||||
virtual void load(const std::string& url , bool force_open_externally)
|
||||
{
|
||||
|
|
@ -65,6 +66,7 @@ static URLLoader sAlertURLLoader;
|
|||
void LLWeb::initClass()
|
||||
{
|
||||
LLAlertDialog::setURLLoader(&sAlertURLLoader);
|
||||
LLToastAlertPanel::setURLLoader(&sAlertURLLoader);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue