package HTML::Mason::Commands; use strict; use vars qw($m $r); my $_escape = \&HTML::Mason::Parser::_escape_perl_expression; ; my $pmeth = { %{ Bric::Biz::Asset::Formatting->my_meths->{priority} } }; $pmeth->{value} = 3; HTML::Mason::Component::FileBased->new ( 'code'=>sub { my %ARGS; if (@_ % 2 == 0) { %ARGS = @_ } else { die "Odd number of parameters passed to component expecting name/value pairs" } my $widget = (!exists $ARGS{'widget'} ? die "no value sent for required parameter 'widget'" : $ARGS{'widget'}); my $_out = $m->current_sink; $m->debug_hook($m->current_comp->path) if (%DB::); ; my $rk = get_state_data($widget, 'reset_key'); # browser spacing stuff my $agent = $m->comp("/widgets/util/detectAgent.mc"); my $ieSpacer = ($agent->{os} ne "SomeNix") ? qq{
} : ''; my $infoIndent = ($agent->{browser} eq "Netscape") ? FIELD_INDENT - 7 : FIELD_INDENT; $m->comp('/widgets/wrappers/sharky/table_top.mc', 'caption' => 'Properties', 'number' => 1); $m->out($ieSpacer); $m->comp('/widgets/select_object/select_object.mc', 'object' => 'element', 'name' => $widget.'|at_id', 'field' => 'name', 'reset_key' => $rk, disp => 'Element'); $m->out($ieSpacer); $_out->('
Generic: '); $m->comp('/widgets/profile/checkbox.mc', name => $widget.'|no_at', value => 1); $_out->(' (not associated with any of the above elements)
'); $m->out($ieSpacer); $m->comp('/widgets/select_object/select_object.mc', 'object' => 'output_channel', 'name' => $widget.'|oc_id', 'field' => 'name', 'reset_key' => $rk, 'disp' => 'Output Channel'); $m->out($ieSpacer); $m->comp('/widgets/select_object/select_object.mc', 'object' => 'category', 'name' => $widget.'|cat_id', 'reset_key' => $rk, 'field' => 'name', 'disp' => 'Category'); $m->out($ieSpacer); $m->comp('/widgets/profile/displayFormElement.mc', key => "priority", vals => $pmeth); $m->out($ieSpacer); $m->comp('/widgets/wrappers/sharky/table_bottom.mc'); $m->comp("/widgets/wrappers/sharky/table_top.mc", caption => "Submit", number => 2, ghostly => 1); $_out->('
'); $_out->(' '); $_out->(' '); return undef; }, 'create_time'=>1001684335, 'declared_args'=> { '$widget' => { 'default' => undef } }, 'object_size'=>2993, 'parser_version'=>0.8 ) ;