--- loncom/interface/loncommon.pm 2011/12/20 22:43:34 1.1040
+++ loncom/interface/loncommon.pm 2011/12/20 23:57:51 1.1041
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# a pile of common routines
#
-# $Id: loncommon.pm,v 1.1040 2011/12/20 22:43:34 raeburn Exp $
+# $Id: loncommon.pm,v 1.1041 2011/12/20 23:57:51 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -6739,6 +6739,7 @@ sub headtag {
$result.=&modal_window();
$result.=&togglebox_script();
$result.=&wishlist_window();
+ $result.=&LCprogressbarUpdate_script();
} else {
if ($args->{'add_modal'}) {
$result.=&modal_window();
@@ -6749,6 +6750,9 @@ sub headtag {
if ($args->{'add_togglebox'}) {
$result.=&togglebox_script();
}
+ if ($args->{'add_progressbar'}) {
+ $result.=&LCprogressbarUpdate_script();
+ }
}
if (ref($args->{'redirect'})) {
my ($time,$url,$inhibit_continue) = @{$args->{'redirect'}};
@@ -7057,6 +7061,46 @@ sub modal_adhoc_script {
ENDADHOC
}
+sub modal_adhoc_inner {
+ my ($funcname,$width,$height,$content)=@_;
+ my $innerwidth=$width-20;
+ $content=&js_ready(
+ &start_page('Dialog',undef,{'only_body'=>1,'add_progressbar'=>1,'bgcolor'=>'#FFFFFF'}).
+ &start_scrollbox($width.'px',$innerwidth.'px',$height.'px').
+ $content.
+ &end_scrollbox().
+ &end_page()
+ );
+ return &modal_adhoc_script($funcname,$width,$height,$content);
+}
+
+sub modal_adhoc_window {
+ my ($funcname,$width,$height,$content,$linktext)=@_;
+ return &modal_adhoc_inner($funcname,$width,$height,$content).
+ "".$linktext."";
+}
+
+sub modal_adhoc_launch {
+ my ($funcname,$width,$height,$content)=@_;
+ return &modal_adhoc_inner($funcname,$width,$height,$content).(<