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.cpp18
1 files changed, 16 insertions, 2 deletions
diff --git a/indra/llui/llpanel.cpp b/indra/llui/llpanel.cpp
index ad5cdca5cc..0136a41d61 100644
--- a/indra/llui/llpanel.cpp
+++ b/indra/llui/llpanel.cpp
@@ -58,6 +58,11 @@
static LLDefaultWidgetRegistry::Register<LLPanel> r1("panel", &LLPanel::fromXML);
+const LLPanel::Params& LLPanel::getDefaultParams()
+{
+ return LLUICtrlFactory::getDefaultParams<LLPanel::Params>();
+}
+
LLPanel::Params::Params()
: has_border("border", false),
bg_opaque_color("bg_opaque_color"),
@@ -114,6 +119,14 @@ void LLPanel::addBorder(LLViewBorder::Params p)
addChild( mBorder );
}
+void LLPanel::addBorder()
+{
+ LLViewBorder::Params p;
+ p.border_thickness(LLPANEL_BORDER_WIDTH);
+ addBorder(p);
+}
+
+
void LLPanel::removeBorder()
{
if (mBorder)
@@ -885,10 +898,11 @@ LLView* LLPanel::getChildView(const std::string& name, BOOL recurse, BOOL create
}
if (!view && create_if_missing)
{
- view = getDummyWidget<LLView>(name);
+ view = getDefaultWidget<LLView>(name);
if (!view)
{
- view = LLUICtrlFactory::createDummyWidget<LLView>(name);
+ // create LLViews explicitly, as they are not registered widget types
+ view = LLUICtrlFactory::createDefaultWidget<LLView>(name);
}
}
return view;