version 1.65, 2006/12/19 00:40:38
|
version 1.67, 2006/12/19 14:53:17
|
Line 110 sub start_numericalhint {
|
Line 110 sub start_numericalhint {
|
my ($target,$token,$tagstack,$parstack,$parser,$safeeval,$style)=@_; |
my ($target,$token,$tagstack,$parstack,$parser,$safeeval,$style)=@_; |
#do everything in end, so intervening <responseparams> work |
#do everything in end, so intervening <responseparams> work |
&Apache::response::start_hintresponse($parstack,$safeeval); |
&Apache::response::start_hintresponse($parstack,$safeeval); |
|
&Apache::caparesponse::push_answer(); |
my $result; |
my $result; |
if ($target eq 'edit') { |
if ($target eq 'edit') { |
$result.=&Apache::edit::tag_start($target,$token); |
$result.=&Apache::edit::tag_start($target,$token); |
Line 177 sub end_numericalhint {
|
Line 178 sub end_numericalhint {
|
if (lc($hideunit) eq "yes") { delete($$args_ref{'unit'}); } |
if (lc($hideunit) eq "yes") { delete($$args_ref{'unit'}); } |
|
|
if ($$tagstack[-1] eq 'formulahint') { |
if ($$tagstack[-1] eq 'formulahint') { |
$$args_ref{'type'}='fml'; |
if ($$args_ref{'samples'}) { |
|
$$args_ref{'type'}='fml'; |
|
} else { |
|
$$args_ref{'type'}='math'; |
|
} |
} elsif ($$tagstack[-1] eq 'numericalhint') { |
} elsif ($$tagstack[-1] eq 'numericalhint') { |
$$args_ref{'type'}='float'; |
$$args_ref{'type'}='float'; |
} |
} |
Line 215 sub end_numericalhint {
|
Line 220 sub end_numericalhint {
|
} elsif ($target eq 'edit') { |
} elsif ($target eq 'edit') { |
$result.=&Apache::edit::end_row().&Apache::edit::end_table(); |
$result.=&Apache::edit::end_row().&Apache::edit::end_table(); |
} |
} |
|
&Apache::caparesponse::pop_answer(); |
&Apache::response::end_hintresponse(); |
&Apache::response::end_hintresponse(); |
return $result; |
return $result; |
} |
} |