From 68a174d4d5fc19c4395248c2138f590988cc8461 Mon Sep 17 00:00:00 2001 From: acanas Date: Wed, 13 May 2020 13:37:15 +0200 Subject: [PATCH] Version19.228.2 --- swad_changelog.h | 3 ++- swad_exam_print.c | 29 ++++++++++++----------------- swad_test_print.c | 25 ++++++++++--------------- 3 files changed, 24 insertions(+), 33 deletions(-) diff --git a/swad_changelog.h b/swad_changelog.h index c3081177..bd942f21 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -548,10 +548,11 @@ enscript -2 --landscape --color --file-align=2 --highlight --line-numbers -o - * En OpenSWAD: ps2pdf source.ps destination.pdf */ -#define Log_PLATFORM_VERSION "SWAD 19.228.1 (2020-05-13)" +#define Log_PLATFORM_VERSION "SWAD 19.228.2 (2020-05-13)" #define CSS_FILE "swad19.217.css" #define JS_FILE "swad19.223.js" /* + Version 19.228.2: May 13, 2020 Code refactoring in exam prints. (303829 lines) Version 19.228.1: May 13, 2020 Code refactoring in exam prints. (303828 lines) Version 19.228: May 13, 2020 Code refactoring and bug fixing in exam prints. (303837 lines) Version 19.227.1: May 13, 2020 Cache of linked GIFs and videos. (303612 lines) diff --git a/swad_exam_print.c b/swad_exam_print.c index 82add70f..8b22b49c 100644 --- a/swad_exam_print.c +++ b/swad_exam_print.c @@ -1117,50 +1117,45 @@ void ExaPrn_ComputeAnswerScore (struct TstPrn_PrintedQuestion *PrintedQuestion, static void ExaPrn_GetCorrectAndComputeIntAnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, struct Tst_Question *Question) { - /***** Get the numerical value of the correct answer *****/ + /***** Get the numerical value of the correct answer, + and compute score *****/ ExaPrn_GetCorrectIntAnswerFromDB (Question); - - /***** Compute score *****/ TstPrn_ComputeIntAnsScore (PrintedQuestion,Question); } static void ExaPrn_GetCorrectAndComputeFltAnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, struct Tst_Question *Question) { - /***** Get the numerical value of the minimum and maximum correct answers *****/ + /***** Get the numerical value of the minimum and maximum correct answers, + and compute score *****/ ExaPrn_GetCorrectFltAnswerFromDB (Question); - - /***** Compute score *****/ TstPrn_ComputeFltAnsScore (PrintedQuestion,Question); } static void ExaPrn_GetCorrectAndComputeTF_AnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, - struct Tst_Question *Question) + struct Tst_Question *Question) { - /***** Get answer true or false *****/ + /***** Get answer true or false, + and compute score *****/ ExaPrn_GetCorrectTF_AnswerFromDB (Question); - - /***** Compute score *****/ TstPrn_ComputeTF_AnsScore (PrintedQuestion,Question); } static void ExaPrn_GetCorrectAndComputeChoAnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, - struct Tst_Question *Question) + struct Tst_Question *Question) { - /***** Get correct options of test question from database *****/ + /***** Get correct options of test question from database, + and compute score *****/ ExaPrn_GetCorrectChoAnswerFromDB (Question); - - /***** Compute the total score of this question *****/ TstPrn_ComputeChoAnsScore (PrintedQuestion,Question); } static void ExaPrn_GetCorrectAndComputeTxtAnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, struct Tst_Question *Question) { - /***** Get correct answers for this question from database *****/ + /***** Get correct text answers for this question from database, + and compute score *****/ ExaPrn_GetCorrectTxtAnswerFromDB (Question); - - /***** Compute score *****/ TstPrn_ComputeTxtAnsScore (PrintedQuestion,Question); } diff --git a/swad_test_print.c b/swad_test_print.c index b8df9f00..92cef5d1 100644 --- a/swad_test_print.c +++ b/swad_test_print.c @@ -425,50 +425,45 @@ void TstPrn_ComputeAnswerScore (struct TstPrn_PrintedQuestion *PrintedQuestion, static void TstPrn_GetCorrectAndComputeIntAnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, struct Tst_Question *Question) { - /***** Get the numerical value of the correct answer *****/ + /***** Get the numerical value of the correct answer, + and compute score *****/ TstPrn_GetCorrectIntAnswerFromDB (Question); - - /***** Compute score *****/ TstPrn_ComputeIntAnsScore (PrintedQuestion,Question); } static void TstPrn_GetCorrectAndComputeFltAnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, struct Tst_Question *Question) { - /***** Get the numerical value of the minimum and maximum correct answers *****/ + /***** Get the numerical value of the minimum and maximum correct answers, + and compute score *****/ TstPrn_GetCorrectFltAnswerFromDB (Question); - - /***** Compute score *****/ TstPrn_ComputeFltAnsScore (PrintedQuestion,Question); } static void TstPrn_GetCorrectAndComputeTF_AnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, struct Tst_Question *Question) { - /***** Get answer true or false *****/ + /***** Get answer true or false, + and compute score *****/ TstPrn_GetCorrectTF_AnswerFromDB (Question); - - /***** Compute score *****/ TstPrn_ComputeTF_AnsScore (PrintedQuestion,Question); } static void TstPrn_GetCorrectAndComputeChoAnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, struct Tst_Question *Question) { - /***** Get correct options of test question from database *****/ + /***** Get correct options of test question from database, + and compute score *****/ TstPrn_GetCorrectChoAnswerFromDB (Question); - - /***** Compute the total score of this question *****/ TstPrn_ComputeChoAnsScore (PrintedQuestion,Question); } static void TstPrn_GetCorrectAndComputeTxtAnsScore (struct TstPrn_PrintedQuestion *PrintedQuestion, struct Tst_Question *Question) { - /***** Get correct answers for this question from database *****/ + /***** Get correct text answers for this question from database, + and compute score *****/ TstPrn_GetCorrectTxtAnswerFromDB (Question); - - /***** Compute score *****/ TstPrn_ComputeTxtAnsScore (PrintedQuestion,Question); }