From 2463d0bcf7c352c167aa4bda31ae54dc1acd3624 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Ca=C3=B1as=20Vargas?= Date: Mon, 26 Dec 2016 16:30:46 +0100 Subject: [PATCH] Version 16.107.1 --- swad_changelog.h | 4 ++- swad_test.c | 66 ++++++++++++++++++++++++++---------------------- 2 files changed, 39 insertions(+), 31 deletions(-) diff --git a/swad_changelog.h b/swad_changelog.h index 15af66542..7d2eb0809 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -189,13 +189,15 @@ /****************************** Public constants *****************************/ /*****************************************************************************/ -#define Log_PLATFORM_VERSION "SWAD 16.107 (2016-12-26)" +#define Log_PLATFORM_VERSION "SWAD 16.107.1 (2016-12-26)" #define CSS_FILE "swad16.106.5.css" #define JS_FILE "swad16.101.js" // Number of lines (includes comments but not blank lines) has been got with the following command: // nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*?.h sql/swad*.sql | tail -1 /* + Version 16.107.1: Dec 26, 2016 Changes in behaviour of labels in forms. + Code refactoring in tests. (211515 lines) Version 16.107: Dec 26, 2016 Changes in behaviour of labels in forms. Code refactoring in tests. (211510 lines) Version 16.106.20:Dec 26, 2016 Changes in warning about next time to take a test. (211486 lines) diff --git a/swad_test.c b/swad_test.c index 4a458780c..d587b837a 100644 --- a/swad_test.c +++ b/swad_test.c @@ -218,6 +218,7 @@ static int Tst_CountNumAnswerTypesInList (void); static void Tst_PutFormEditOneQst (char *Stem,char *Feedback); static void Tst_PutFloatInputField (const char *Label,const char *Field, double Value); +static void Tst_PutTFInputField (const char *Label,char Value); static void Tst_FreeTextChoiceAnswers (void); static void Tst_FreeTextChoiceAnswer (unsigned NumOpt); @@ -4662,37 +4663,17 @@ static void Tst_PutFormEditOneQst (char *Stem,char *Feedback) /* T/F answer */ fprintf (Gbl.F.Out,"" "" - "" - "" - "" - "" - "" - "
" - "" - "%s " - "" - "%s" - "
" - "" - "", - Txt_TF_QST[1]); + ""); + Tst_PutTFInputField (Txt_TF_QST[0],'T'); + Tst_PutTFInputField (Txt_TF_QST[1],'F'); + fprintf (Gbl.F.Out,"" + ""); /* Questions can be shuffled? */ fprintf (Gbl.F.Out,"" "" - "" + "" + "" + "" "", Txt_Shuffle); @@ -4814,7 +4798,7 @@ static void Tst_PutFormEditOneQst (char *Stem,char *Feedback) OptionsDisabled); /* Feedback */ - fprintf (Gbl.F.Out,"
%s (%s):
" + fprintf (Gbl.F.Out,""); /* End of right column */ fprintf (Gbl.F.Out,"" @@ -4874,6 +4859,27 @@ static void Tst_PutFloatInputField (const char *Label,const char *Field, ""); } +/*****************************************************************************/ +/*********************** Put input field for T/F answer **********************/ +/*****************************************************************************/ + +static void Tst_PutTFInputField (const char *Label,char Value) + { + extern const char *The_ClassForm[The_NUM_THEMES]; + + fprintf (Gbl.F.Out,"", + Label); + } + /*****************************************************************************/ /********************* Initialize a new question to zero *********************/ /*****************************************************************************/