--- loncom/homework/edit.pm 2013/12/03 17:22:08 1.150
+++ loncom/homework/edit.pm 2014/11/28 18:23:03 1.152
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# edit mode helpers
#
-# $Id: edit.pm,v 1.150 2013/12/03 17:22:08 bisitz Exp $
+# $Id: edit.pm,v 1.152 2014/11/28 18:23:03 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -296,7 +296,7 @@ sub get_insert_list {
my $descrip=$Apache::lonxml::insertlist{"$tag.description"};
my $tagnum =$Apache::lonxml::insertlist{"$tag.num"};
$options{$descrip} ="\n";
+ &mt($descrip)."\n";
}
foreach my $option (sort(keys(%options))) {$result.=$options{$option};}
if ($result) { $result=''.$result; }
@@ -796,6 +796,49 @@ sub submit_dont_ask {
return ' onclick="is_submit=true;'.$extra_action.'" ';
}
+sub js_update_linknum {
+ return (<
+SCRIPT
+
+}
sub textarea_sizes {
my ($data)=@_;
@@ -941,7 +984,7 @@ sub hidden_arg {
}
sub checked_arg {
- my ($description,$name,$list,$token) = @_;
+ my ($description,$name,$list,$token,$onclick,$useid) = @_;
my $result;
my $optionlist="";
my $allselected=$token->[2]{$name};
@@ -964,7 +1007,10 @@ sub checked_arg {
last;
}
}
- $result.=&element_change_detection().' />'.$text.''."\n";
+ if ($useid) {
+ $result .= ' id="'.&html_element_name($name).'" ';
+ }
+ $result.=&element_change_detection().$onclick.' />'.$text.''."\n";
}
return $result;
}