--- loncom/interface/statistics/lonproblemanalysis.pm 2004/03/12 20:29:48 1.78 +++ loncom/interface/statistics/lonproblemanalysis.pm 2004/03/12 21:06:32 1.79 @@ -1,6 +1,6 @@ # The LearningOnline Network with CAPA # -# $Id: lonproblemanalysis.pm,v 1.78 2004/03/12 20:29:48 matthew Exp $ +# $Id: lonproblemanalysis.pm,v 1.79 2004/03/12 21:06:32 matthew Exp $ # # Copyright Michigan State University Board of Trustees # @@ -192,6 +192,7 @@ sub BuildProblemAnalysisPage { ######################################################### sub NumericalResponseAnalysis { my ($r,$problem,$ProblemData,$Students) = @_; + my $c = $r->connection(); my ($resource,$respid) = ($problem->{'resource'}, $problem->{'respid'}); my $analysis_html; @@ -209,6 +210,7 @@ sub NumericalResponseAnalysis { # # This next call causes all the waiting around that people complain about my ($max,$min) = &GetStudentAnswers($r,$problem,$Students); + return if ($c->aborted()); # # Collate the data my %Data; @@ -312,6 +314,7 @@ sub circle { sub GetStudentAnswers { my ($r,$problem,$Students) = @_; + my $c = $r->connection(); my %Answers; my ($resource,$partid,$respid) = ($problem->{'resource'}, $problem->{'part'}, @@ -323,6 +326,7 @@ sub GetStudentAnswers { $r->print("\n"); $r->rflush(); foreach my $student (@$Students) { + last if ($c->aborted()); my $sname = $student->{'username'}; my $sdom = $student->{'domain'}; my $answer = &Apache::lonstathelpers::analyze_problem_as_student @@ -331,6 +335,7 @@ sub GetStudentAnswers { &mt('last student')); $student->{'answer'} = $answer; } + return if ($c->aborted()); $r->print("
\n"); $r->rflush(); # close progress window