Version 16.252.1

This commit is contained in:
Antonio Cañas Vargas 2017-09-10 18:58:26 +02:00
parent 498723ff9d
commit 37da7184be
2 changed files with 27 additions and 15 deletions

View File

@ -238,13 +238,14 @@
/****************************** Public constants *****************************/
/*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 16.252 (2017-09-08)"
#define Log_PLATFORM_VERSION "SWAD 16.252.1 (2017-09-09)"
#define CSS_FILE "swad16.251.8.css"
#define JS_FILE "swad16.206.3.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.252.1: Sep 09, 2017 Icons to move up and down questions in a game. (226864 lines)
Version 16.252: Sep 08, 2017 Icons to move up and down questions in a game. (226852 lines)
Version 16.251.13:Sep 07, 2017 Option Remote Control moved after Test. (226873 lines)
Version 16.251.12:Sep 07, 2017 Module swad_game is renamed swad_game. (226872 lines)

View File

@ -2727,6 +2727,7 @@ static void Gam_ListOneOrMoreQuestionsForEdition (struct Game *Game,
extern const char *Txt_Question;
extern const char *Txt_Move_up_X;
extern const char *Txt_Move_down_X;
extern const char *Txt_Movement_not_allowed;
extern const char *Txt_TST_STR_ANSWER_TYPES[Tst_NUM_ANS_TYPES];
unsigned NumQst;
MYSQL_ROW row;
@ -2763,6 +2764,8 @@ static void Gam_ListOneOrMoreQuestionsForEdition (struct Game *Game,
{
Gbl.RowEvenOdd = NumQst % 2;
sprintf (StrNumQst,"%u",NumQst + 1);
row = mysql_fetch_row (mysql_res);
/*
row[0] QstCod
@ -2793,20 +2796,28 @@ static void Gam_ListOneOrMoreQuestionsForEdition (struct Game *Game,
Act_FormEnd ();
/* Write icon to move up the question */
sprintf (StrNumQst,"%u",NumQst + 1);
sprintf (Gbl.Title,Txt_Move_up_X,StrNumQst);
Lay_PutContextualLink (ActEdiOneTstQst,NULL,Gam_PutParamsOneQst,
"up_on16x16.gif",
Gbl.Title,NULL,
NULL);
if (NumQst)
{
sprintf (Gbl.Title,Txt_Move_up_X,StrNumQst);
Lay_PutContextualLink (ActEdiOneTstQst,NULL,Gam_PutParamsOneQst,
"up_on16x16.gif",
Gbl.Title,NULL,
NULL);
}
else
Ico_PutIconWithText ("up_off16x16.gif",Txt_Movement_not_allowed,NULL);
/* Write icon to move down the question */
sprintf (Gbl.Title,Txt_Move_down_X,StrNumQst);
Lay_PutContextualLink (ActEdiOneTstQst,NULL,Gam_PutParamsOneQst,
"down_on16x16.gif",
Gbl.Title,NULL,
NULL);
if (NumQst + 1 < NumQsts)
{
sprintf (Gbl.Title,Txt_Move_down_X,StrNumQst);
Lay_PutContextualLink (ActEdiOneTstQst,NULL,Gam_PutParamsOneQst,
"down_on16x16.gif",
Gbl.Title,NULL,
NULL);
}
else
Ico_PutIconWithText ("down_off16x16.gif",Txt_Movement_not_allowed,NULL);
/* Write icon to edit the question */
Gbl.Test.QstCod = QstCod;
@ -2816,9 +2827,9 @@ static void Gam_ListOneOrMoreQuestionsForEdition (struct Game *Game,
/* Write number of question */
fprintf (Gbl.F.Out,"<td class=\"RIGHT_TOP COLOR%u\">"
"<div class=\"TEST_NUM_QST\">%u</div>",
"<div class=\"TEST_NUM_QST\">%s</div>",
Gbl.RowEvenOdd,
NumQst + 1);
StrNumQst);
/* Write answer type (row[1]) */
Gbl.Test.AnswerType = Tst_ConvertFromStrAnsTypDBToAnsTyp (row[1]);