From 6feb42e0095cfb46c11897d759bdd03033045f54 Mon Sep 17 00:00:00 2001 From: James Cook Date: Mon, 30 Nov 2009 15:45:15 -0800 Subject: De-inlined some UI param block definitions. --- indra/llui/lluictrl.cpp | 22 ++++++++++++++++++++++ indra/llui/lluictrl.h | 22 +++------------------- indra/llui/llview.cpp | 5 +++++ indra/llui/llview.h | 5 +---- 4 files changed, 31 insertions(+), 23 deletions(-) (limited to 'indra') diff --git a/indra/llui/lluictrl.cpp b/indra/llui/lluictrl.cpp index 1e0af1201f..706712ec5e 100644 --- a/indra/llui/lluictrl.cpp +++ b/indra/llui/lluictrl.cpp @@ -46,6 +46,28 @@ static LLDefaultChildRegistry::Register r("ui_ctrl"); template class LLUICtrl* LLView::getChild( const std::string& name, BOOL recurse) const; +LLUICtrl::CallbackParam::CallbackParam() +: name("name"), + function_name("function"), + parameter("parameter"), + control_name("control") // Shortcut to control -> "control_name" for backwards compatability +{ + addSynonym(parameter, "userdata"); +} + +LLUICtrl::EnableControls::EnableControls() +: enabled("enabled_control"), + disabled("disabled_control") +{} + +LLUICtrl::ControlVisibility::ControlVisibility() +: visible("visibility_control"), + invisible("invisibility_control") +{ + addSynonym(visible, "visiblity_control"); + addSynonym(invisible, "invisiblity_control"); +} + LLUICtrl::Params::Params() : tab_stop("tab_stop", true), chrome("chrome", false), diff --git a/indra/llui/lluictrl.h b/indra/llui/lluictrl.h index ac916c9a43..b20ff5d798 100644 --- a/indra/llui/lluictrl.h +++ b/indra/llui/lluictrl.h @@ -75,14 +75,7 @@ public: Optional control_name; - CallbackParam() - : name("name"), - function_name("function"), - parameter("parameter"), - control_name("control") // Shortcut to control -> "control_name" for backwards compatability - { - addSynonym(parameter, "userdata"); - } + CallbackParam(); }; struct CommitCallbackParam : public LLInitParam::Block @@ -105,23 +98,14 @@ public: Alternative enabled; Alternative disabled; - EnableControls() - : enabled("enabled_control"), - disabled("disabled_control") - {} + EnableControls(); }; struct ControlVisibility : public LLInitParam::Choice { Alternative visible; Alternative invisible; - ControlVisibility() - : visible("visibility_control"), - invisible("invisibility_control") - { - addSynonym(visible, "visiblity_control"); - addSynonym(invisible, "invisiblity_control"); - } + ControlVisibility(); }; struct Params : public LLInitParam::Block { diff --git a/indra/llui/llview.cpp b/indra/llui/llview.cpp index e7e8b1b858..23e4131e6d 100644 --- a/indra/llui/llview.cpp +++ b/indra/llui/llview.cpp @@ -83,6 +83,11 @@ template class LLView* LLView::getChild( static LLDefaultChildRegistry::Register r("view"); +LLView::Follows::Follows() +: string(""), + flags("flags", FOLLOWS_LEFT | FOLLOWS_TOP) +{} + LLView::Params::Params() : name("name", std::string("unnamed")), enabled("enabled", true), diff --git a/indra/llui/llview.h b/indra/llui/llview.h index 8ee05675c1..d485244a05 100644 --- a/indra/llui/llview.h +++ b/indra/llui/llview.h @@ -111,10 +111,7 @@ public: Alternative string; Alternative flags; - Follows() - : string(""), - flags("flags", FOLLOWS_LEFT | FOLLOWS_TOP) - {} + Follows(); }; struct Params : public LLInitParam::Block -- cgit v1.2.3