--- loncom/xml/londefdef.pm 2003/02/07 22:03:21 1.112 +++ loncom/xml/londefdef.pm 2003/02/14 19:35:55 1.113 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Tags Default Definition Module # -# $Id: londefdef.pm,v 1.112 2003/02/07 22:03:21 albertel Exp $ +# $Id: londefdef.pm,v 1.113 2003/02/14 19:35:55 www Exp $ # # # Copyright Michigan State University Board of Trustees @@ -49,6 +49,7 @@ use strict; use Apache::lonxml; use Apache::File(); use Image::Magick; +use Apache::lonmenu; BEGIN { @@ -183,7 +184,7 @@ sub start_html { my ($target,$token) = @_; my $currentstring = ''; if ($target eq 'web') { - $currentstring = &Apache::lonxml::registerurl(undef,$target). + $currentstring = &Apache::lonmenu::registerurl(undef,$target). $token->[2]; } return $currentstring; @@ -365,7 +366,7 @@ sub start_html { if ($target eq 'web') { if (!$Apache::lonxml::registered) { $currentstring.=''. - &Apache::lonxml::registerurl(undef,$target).''; + &Apache::lonmenu::registerurl(undef,$target).''; } my $onLoad=''; foreach my $key (keys(%{$token->[2]})) { @@ -374,7 +375,7 @@ sub start_html { delete($token->[2]->{$key}); } } - $token->[2]->{'onload'}=&Apache::lonxml::loadevents(). + $token->[2]->{'onload'}=&Apache::lonmenu::loadevents(). ';'.$onLoad; my $onUnload=''; foreach my $key (keys(%{$token->[2]})) { @@ -383,7 +384,7 @@ sub start_html { delete($token->[2]->{$key}); } } - $token->[2]->{'onunload'}=&Apache::lonxml::unloadevents(). + $token->[2]->{'onunload'}=&Apache::lonmenu::unloadevents(). ';'.$onUnload; $currentstring .= '<'.$token->[1]; @@ -397,7 +398,9 @@ sub start_html { EDITBUTTON - } + } else { + $currentstring.=&Apache::lonmenu::menubuttons(undef,$target); + } } elsif ($target eq 'tex') { $currentstring = '\begin{document}'; } @@ -1789,7 +1792,7 @@ sub end_allow { if ($target eq 'web') { if (!$Apache::lonxml::registered) { $currentstring.=''. - &Apache::lonxml::registerurl(undef,$target).''; + &Apache::lonmenu::registerurl(undef,$target).''; } $currentstring .= $token->[4]; }