summaryrefslogtreecommitdiff
path: root/indra/llui/llpanel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llui/llpanel.cpp')
-rw-r--r--indra/llui/llpanel.cpp20
1 files changed, 16 insertions, 4 deletions
diff --git a/indra/llui/llpanel.cpp b/indra/llui/llpanel.cpp
index 7f23fe2671..0cd052eefa 100644
--- a/indra/llui/llpanel.cpp
+++ b/indra/llui/llpanel.cpp
@@ -80,6 +80,8 @@ LLPanel::Params::Params()
background_opaque("background_opaque", false),
bg_opaque_color("bg_opaque_color"),
bg_alpha_color("bg_alpha_color"),
+ bg_opaque_image_overlay("bg_opaque_image_overlay"),
+ bg_alpha_image_overlay("bg_alpha_image_overlay"),
bg_opaque_image("bg_opaque_image"),
bg_alpha_image("bg_alpha_image"),
min_width("min_width", 100),
@@ -103,6 +105,8 @@ LLPanel::LLPanel(const LLPanel::Params& p)
mBgOpaque(p.background_opaque),
mBgOpaqueColor(p.bg_opaque_color()),
mBgAlphaColor(p.bg_alpha_color()),
+ mBgOpaqueImageOverlay(p.bg_opaque_image_overlay),
+ mBgAlphaImageOverlay(p.bg_alpha_image_overlay),
mBgOpaqueImage(p.bg_opaque_image()),
mBgAlphaImage(p.bg_alpha_image()),
mDefaultBtn(NULL),
@@ -199,7 +203,7 @@ void LLPanel::draw()
// opaque, in-front look
if (mBgOpaqueImage.notNull())
{
- mBgOpaqueImage->draw( local_rect, UI_VERTEX_COLOR % alpha );
+ mBgOpaqueImage->draw( local_rect, mBgOpaqueImageOverlay % alpha );
}
else
{
@@ -212,7 +216,7 @@ void LLPanel::draw()
// transparent, in-back look
if (mBgAlphaImage.notNull())
{
- mBgAlphaImage->draw( local_rect, UI_VERTEX_COLOR % alpha );
+ mBgAlphaImage->draw( local_rect, mBgAlphaImageOverlay % alpha );
}
else
{
@@ -397,6 +401,12 @@ LLView* LLPanel::fromXML(LLXMLNodePtr node, LLView* parent, LLXMLNodePtr output_
if (!panelp)
{
panelp = LLUICtrlFactory::getInstance()->createFactoryPanel(name);
+ llassert(panelp);
+
+ if (!panelp)
+ {
+ return NULL; // :(
+ }
}
}
@@ -414,7 +424,7 @@ LLView* LLPanel::fromXML(LLXMLNodePtr node, LLView* parent, LLXMLNodePtr output_
panelp->mCommitCallbackRegistrar.popScope();
panelp->mEnableCallbackRegistrar.popScope();
- if (panelp && !panelp->getFactoryMap().empty())
+ if (!panelp->getFactoryMap().empty())
{
LLUICtrlFactory::instance().popFactoryFunctions();
}
@@ -475,6 +485,8 @@ void LLPanel::initFromParams(const LLPanel::Params& p)
setTransparentColor(p.bg_alpha_color().get());
mBgOpaqueImage = p.bg_opaque_image();
mBgAlphaImage = p.bg_alpha_image();
+ mBgOpaqueImageOverlay = p.bg_opaque_image_overlay;
+ mBgAlphaImageOverlay = p.bg_alpha_image_overlay;
}
static LLFastTimer::DeclareTimer FTM_PANEL_SETUP("Panel Setup");
@@ -936,7 +948,7 @@ LLPanel *LLPanel::childGetVisiblePanelWithHelp()
return ::childGetVisiblePanelWithHelp(this);
}
-void LLPanel::childSetPrevalidate(const std::string& id, BOOL (*func)(const LLWString &) )
+void LLPanel::childSetPrevalidate(const std::string& id, bool (*func)(const LLWString &) )
{
LLLineEditor* child = findChild<LLLineEditor>(id);
if (child)