diff --git a/css/swad18.138.css b/css/swad18.138.css index f25133d73..6a20a61d3 100644 --- a/css/swad18.138.css +++ b/css/swad18.138.css @@ -90,7 +90,7 @@ a:hover /* Default ==> underlined */ { text-decoration:underline; } -.TAB_OFF a, .TAB_ON a, .MENU_LIST_ITEM a /* Tabs and menus are the exceptions */ +.TAB_OFF a, .TAB_ON a, .MENU_LIST_ITEM a, .CONTEXT_OPT a /* Tabs and menus are the exceptions */ { text-decoration:none; } @@ -2621,6 +2621,12 @@ a:hover img.CENTRE_PHOTO_SHOW text-align:center; vertical-align:top; } +.MATCH_SHOW_RESULTS + { + text-align:center; + padding-bottom:16pt; + font-size:13pt; + } .MATCH_NUM_PLAYERS { text-align:center; diff --git a/sql/swad.sql b/sql/swad.sql index 268857379..98e1a42c3 100644 --- a/sql/swad.sql +++ b/sql/swad.sql @@ -640,6 +640,7 @@ CREATE TABLE IF NOT EXISTS gam_matches ( QstCod INT NOT NULL DEFAULT -1, QstStartTime DATETIME NOT NULL, ShowingAnswers ENUM('N','Y') NOT NULL DEFAULT 'N', + ShowResults ENUM('N','Y') NOT NULL DEFAULT 'N', UNIQUE INDEX(MchCod), INDEX(GamCod)); -- diff --git a/swad_action.c b/swad_action.c index de558e584..46454356a 100644 --- a/swad_action.c +++ b/swad_action.c @@ -617,6 +617,7 @@ Assessment: NEW. ActShoAnsMchTch Show full current question, including answers, when playing a match (by a teacher) NEW. ActPrvQstMchTch Show previous question when playing a match (by a teacher) 457. ActNxtQstMchTch Show next question when playing a match (by a teacher) + NEW. ActChgDisResMchTch Change display of results when playing a match (by a teacher) NEW. ActRefMchTch Refresh current question when playing a match (as teacher) NEW. ActShoMchTch Show finished match results @@ -2162,6 +2163,7 @@ struct Act_Actions Act_Actions[Act_NUM_ACTIONS] = /* ActShoAnsMchTch */{1793,-1,TabUnk,ActSeeAllGam ,0x230,0x200, 0, 0, 0, 0, 0,Act_CONT_NORM,Act_BRW_2ND_TAB,Gam_GetMatchBeingPlayed ,Gam_ShowAnssQstMatchTch ,NULL}, /* ActPrvQstMchTch */{1790,-1,TabUnk,ActSeeAllGam ,0x230,0x200, 0, 0, 0, 0, 0,Act_CONT_NORM,Act_BRW_2ND_TAB,Gam_GetMatchBeingPlayed ,Gam_PrevQstMatchTch ,NULL}, /* ActNxtQstMchTch */{1672,-1,TabUnk,ActSeeAllGam ,0x230,0x200, 0, 0, 0, 0, 0,Act_CONT_NORM,Act_BRW_2ND_TAB,Gam_GetMatchBeingPlayed ,Gam_NextQstMatchTch ,NULL}, + /* ActChgDisResMchTch*/{1794,-1,TabUnk,ActSeeAllGam ,0x230,0x200, 0, 0, 0, 0, 0,Act_CONT_NORM,Act_BRW_2ND_TAB,Gam_GetMatchBeingPlayed ,Gam_CurrQstMatchTch ,NULL}, /* ActRefMchTch */{1788,-1,TabUnk,ActSeeAllGam ,0x230,0x200, 0, 0, 0, 0, 0,Act_CONT_NORM,Act_AJAX_RFRESH,Gam_GetMatchBeingPlayed ,Gam_RefreshMatchTch ,NULL}, /* ActShoMchTch */{1786,-1,TabUnk,ActSeeAllGam ,0x230,0x200, 0, 0, 0, 0, 0,Act_CONT_NORM,Act_BRW_1ST_TAB,NULL ,Gam_ShowFinishedMatchResults ,NULL}, @@ -4891,7 +4893,7 @@ Act_Action_t Act_FromActCodToAction[1 + Act_MAX_ACTION_COD] = // Do not reuse un ActDwnGamQst, // #1669 ActReqNewMchTch, // #1670 ActNewMchTch, // #1671 - ActNxtQstMchTch, // #1672 + ActNxtQstMchTch, // #1672 -1, // #1673 (obsolete action) ActSeePrj, // #1674 ActFrmNewPrj, // #1675 @@ -5013,6 +5015,7 @@ Act_Action_t Act_FromActCodToAction[1 + Act_MAX_ACTION_COD] = // Do not reuse un ActPauMchTch, // #1791 ActShoSteMchTch, // #1792 ActShoAnsMchTch, // #1793 + ActChgDisResMchTch, // #1794 }; /*****************************************************************************/ diff --git a/swad_action.h b/swad_action.h index 8929c1e1b..dd64dd343 100644 --- a/swad_action.h +++ b/swad_action.h @@ -64,9 +64,9 @@ typedef enum typedef signed int Act_Action_t; // Must be a signed type, because -1 is used to indicate obsolete action -#define Act_NUM_ACTIONS (1 + 4 + 64 + 38 + 12 + 42 + 36 + 19 + 110 + 174 + 437 + 176 + 169 + 16 + 68) +#define Act_NUM_ACTIONS (1 + 4 + 64 + 38 + 12 + 42 + 36 + 19 + 110 + 175 + 437 + 176 + 169 + 16 + 68) -#define Act_MAX_ACTION_COD 1793 +#define Act_MAX_ACTION_COD 1794 #define Act_MAX_OPTIONS_IN_MENU_PER_TAB 13 @@ -618,55 +618,56 @@ typedef signed int Act_Action_t; // Must be a signed type, because -1 is used to #define ActShoAnsMchTch (ActChgCrsTT1stDay + 125) #define ActPrvQstMchTch (ActChgCrsTT1stDay + 126) #define ActNxtQstMchTch (ActChgCrsTT1stDay + 127) -#define ActRefMchTch (ActChgCrsTT1stDay + 128) -#define ActShoMchTch (ActChgCrsTT1stDay + 129) -#define ActPlyMchStd (ActChgCrsTT1stDay + 130) -#define ActRefMchStd (ActChgCrsTT1stDay + 131) -#define ActAnsMchQstStd (ActChgCrsTT1stDay + 132) -#define ActFrmNewGam (ActChgCrsTT1stDay + 133) -#define ActEdiOneGam (ActChgCrsTT1stDay + 134) -#define ActNewGam (ActChgCrsTT1stDay + 135) -#define ActChgGam (ActChgCrsTT1stDay + 136) -#define ActReqRemGam (ActChgCrsTT1stDay + 137) -#define ActRemGam (ActChgCrsTT1stDay + 138) -#define ActReqRstGam (ActChgCrsTT1stDay + 139) -#define ActRstGam (ActChgCrsTT1stDay + 140) -#define ActHidGam (ActChgCrsTT1stDay + 141) -#define ActShoGam (ActChgCrsTT1stDay + 142) -#define ActAddOneGamQst (ActChgCrsTT1stDay + 143) -#define ActGamLstTstQst (ActChgCrsTT1stDay + 144) -#define ActAddTstQstToGam (ActChgCrsTT1stDay + 145) -#define ActReqRemGamQst (ActChgCrsTT1stDay + 146) -#define ActRemGamQst (ActChgCrsTT1stDay + 147) -#define ActUp_GamQst (ActChgCrsTT1stDay + 148) -#define ActDwnGamQst (ActChgCrsTT1stDay + 149) +#define ActChgDisResMchTch (ActChgCrsTT1stDay + 128) +#define ActRefMchTch (ActChgCrsTT1stDay + 129) +#define ActShoMchTch (ActChgCrsTT1stDay + 130) +#define ActPlyMchStd (ActChgCrsTT1stDay + 131) +#define ActRefMchStd (ActChgCrsTT1stDay + 132) +#define ActAnsMchQstStd (ActChgCrsTT1stDay + 133) +#define ActFrmNewGam (ActChgCrsTT1stDay + 134) +#define ActEdiOneGam (ActChgCrsTT1stDay + 135) +#define ActNewGam (ActChgCrsTT1stDay + 136) +#define ActChgGam (ActChgCrsTT1stDay + 137) +#define ActReqRemGam (ActChgCrsTT1stDay + 138) +#define ActRemGam (ActChgCrsTT1stDay + 139) +#define ActReqRstGam (ActChgCrsTT1stDay + 140) +#define ActRstGam (ActChgCrsTT1stDay + 141) +#define ActHidGam (ActChgCrsTT1stDay + 142) +#define ActShoGam (ActChgCrsTT1stDay + 143) +#define ActAddOneGamQst (ActChgCrsTT1stDay + 144) +#define ActGamLstTstQst (ActChgCrsTT1stDay + 145) +#define ActAddTstQstToGam (ActChgCrsTT1stDay + 146) +#define ActReqRemGamQst (ActChgCrsTT1stDay + 147) +#define ActRemGamQst (ActChgCrsTT1stDay + 148) +#define ActUp_GamQst (ActChgCrsTT1stDay + 149) +#define ActDwnGamQst (ActChgCrsTT1stDay + 150) -#define ActSeeSvy (ActChgCrsTT1stDay + 150) -#define ActAnsSvy (ActChgCrsTT1stDay + 151) -#define ActFrmNewSvy (ActChgCrsTT1stDay + 152) -#define ActEdiOneSvy (ActChgCrsTT1stDay + 153) -#define ActNewSvy (ActChgCrsTT1stDay + 154) -#define ActChgSvy (ActChgCrsTT1stDay + 155) -#define ActReqRemSvy (ActChgCrsTT1stDay + 156) -#define ActRemSvy (ActChgCrsTT1stDay + 157) -#define ActReqRstSvy (ActChgCrsTT1stDay + 158) -#define ActRstSvy (ActChgCrsTT1stDay + 159) -#define ActHidSvy (ActChgCrsTT1stDay + 160) -#define ActShoSvy (ActChgCrsTT1stDay + 161) -#define ActEdiOneSvyQst (ActChgCrsTT1stDay + 162) -#define ActRcvSvyQst (ActChgCrsTT1stDay + 163) -#define ActReqRemSvyQst (ActChgCrsTT1stDay + 164) -#define ActRemSvyQst (ActChgCrsTT1stDay + 165) +#define ActSeeSvy (ActChgCrsTT1stDay + 151) +#define ActAnsSvy (ActChgCrsTT1stDay + 152) +#define ActFrmNewSvy (ActChgCrsTT1stDay + 153) +#define ActEdiOneSvy (ActChgCrsTT1stDay + 154) +#define ActNewSvy (ActChgCrsTT1stDay + 155) +#define ActChgSvy (ActChgCrsTT1stDay + 156) +#define ActReqRemSvy (ActChgCrsTT1stDay + 157) +#define ActRemSvy (ActChgCrsTT1stDay + 158) +#define ActReqRstSvy (ActChgCrsTT1stDay + 159) +#define ActRstSvy (ActChgCrsTT1stDay + 160) +#define ActHidSvy (ActChgCrsTT1stDay + 161) +#define ActShoSvy (ActChgCrsTT1stDay + 162) +#define ActEdiOneSvyQst (ActChgCrsTT1stDay + 163) +#define ActRcvSvyQst (ActChgCrsTT1stDay + 164) +#define ActReqRemSvyQst (ActChgCrsTT1stDay + 165) +#define ActRemSvyQst (ActChgCrsTT1stDay + 166) -#define ActSeeOneExaAnn (ActChgCrsTT1stDay + 166) -#define ActSeeDatExaAnn (ActChgCrsTT1stDay + 167) -#define ActEdiExaAnn (ActChgCrsTT1stDay + 168) -#define ActRcvExaAnn (ActChgCrsTT1stDay + 169) -#define ActPrnExaAnn (ActChgCrsTT1stDay + 170) -#define ActReqRemExaAnn (ActChgCrsTT1stDay + 171) -#define ActRemExaAnn (ActChgCrsTT1stDay + 172) -#define ActHidExaAnn (ActChgCrsTT1stDay + 173) -#define ActShoExaAnn (ActChgCrsTT1stDay + 174) +#define ActSeeOneExaAnn (ActChgCrsTT1stDay + 167) +#define ActSeeDatExaAnn (ActChgCrsTT1stDay + 168) +#define ActEdiExaAnn (ActChgCrsTT1stDay + 169) +#define ActRcvExaAnn (ActChgCrsTT1stDay + 170) +#define ActPrnExaAnn (ActChgCrsTT1stDay + 171) +#define ActReqRemExaAnn (ActChgCrsTT1stDay + 172) +#define ActRemExaAnn (ActChgCrsTT1stDay + 173) +#define ActHidExaAnn (ActChgCrsTT1stDay + 174) +#define ActShoExaAnn (ActChgCrsTT1stDay + 175) /*****************************************************************************/ /******************************** Files tab **********************************/ diff --git a/swad_changelog.h b/swad_changelog.h index a43a595e2..8f8ffe418 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -460,10 +460,15 @@ En OpenSWAD: ps2pdf source.ps destination.pdf */ -#define Log_PLATFORM_VERSION "SWAD 18.142.3 (2019-09-10)" +#define Log_PLATFORM_VERSION "SWAD 18.143 (2019-09-10)" #define CSS_FILE "swad18.138.css" #define JS_FILE "swad18.130.2.js" /* + Version 18.143: Sep 10, 2019 Checkbox to show results in matches. (244543 lines) + 2 changes necessary in database: +ALTER TABLE gam_matches ADD COLUMN ShowResults ENUM('N','Y') NOT NULL DEFAULT 'N' AFTER ShowingAnswers; +INSERT INTO actions (ActCod,Language,Obsolete,Txt) VALUES ('1794','es','N','Cambiar presentación de resultados en partida (como profesor)'); + Version 18.142.3: Sep 10, 2019 Animation on teacher's screen when match paused. Code refactoring in matches. (244454 lines) Version 18.142.2: Sep 10, 2019 Elapsed time in question not shown in start and end. (244391 lines) diff --git a/swad_database.c b/swad_database.c index ecc749afe..02a7d8d68 100644 --- a/swad_database.c +++ b/swad_database.c @@ -1382,8 +1382,9 @@ mysql> DESCRIBE gam_matches; | QstCod | int(11) | NO | | -1 | | | QstStartTime | datetime | NO | | NULL | | | ShowingAnswers | enum('N','Y') | NO | | N | | +| ShowResults | enum('N','Y') | NO | | N | | +----------------+---------------+------+-----+---------+----------------+ -10 rows in set (0.00 sec) +11 rows in set (0.00 sec) */ DB_CreateTable ("CREATE TABLE IF NOT EXISTS gam_matches (" "MchCod INT NOT NULL AUTO_INCREMENT," @@ -1396,6 +1397,7 @@ mysql> DESCRIBE gam_matches; "QstCod INT NOT NULL DEFAULT -1," "QstStartTime DATETIME NOT NULL," "ShowingAnswers ENUM('N','Y') NOT NULL DEFAULT 'N'," + "ShowResults ENUM('N','Y') NOT NULL DEFAULT 'N'," "UNIQUE INDEX(MchCod)," "INDEX(GamCod)"); diff --git a/swad_game.c b/swad_game.c index b118cacec..eac21d9e9 100644 --- a/swad_game.c +++ b/swad_game.c @@ -114,6 +114,7 @@ struct Match long QstCod; time_t QstStartTimeUTC; bool ShowingAnswers; + bool ShowResults; bool BeingPlayed; unsigned NumPlayers; } Status; @@ -223,7 +224,8 @@ static void Gam_ShowMatchStatusForTch (struct Match *Match); static void Gam_ShowMatchStatusForStd (struct Match *Match); static void Gam_ShowLeftColumnTch (struct Match *Match); static void Gam_ShowLeftColumnStd (struct Match *Match); -static void Gam_ShowButtons (struct Match *Match); +static void Gam_PutMatchControlButtons (struct Match *Match); +static void Gam_PutCheckboxResult (struct Match *Match); static void Gam_ShowNumQstInGame (struct Match *Match); static void Gam_ShowNumPlayers (struct Match *Match); static void Gam_ShowMatchTitle (struct Match *Match); @@ -2701,7 +2703,8 @@ static void Gam_ListMatches (struct Game *Game,bool PutFormNewMatch) "QstInd," // row[ 6] "QstCod," // row[ 7] "UNIX_TIMESTAMP(QstStartTime)," // row[ 8] - "ShowingAnswers" // row[ 9] + "ShowingAnswers," // row[ 9] + "ShowResults" // row[10] " FROM gam_matches" " WHERE GamCod=%ld%s" " ORDER BY MchCod", @@ -2762,7 +2765,8 @@ void Gam_GetDataOfMatchByCod (struct Match *Match) "QstInd," // row[ 6] "QstCod," // row[ 7] "UNIX_TIMESTAMP(QstStartTime)," // row[ 8] - "ShowingAnswers" // row[ 9] + "ShowingAnswers," // row[ 9] + "ShowResults" // row[10] " FROM gam_matches" " WHERE MchCod=%ld" " AND GamCod IN" // Extra check @@ -2786,6 +2790,7 @@ void Gam_GetDataOfMatchByCod (struct Match *Match) Match->Status.QstCod = -1L; Match->Status.QstStartTimeUTC = (time_t) 0; Match->Status.ShowingAnswers = false; + Match->Status.ShowResults = false; Match->Status.BeingPlayed = false; } @@ -3027,7 +3032,8 @@ static void Gam_GetMatchDataFromRow (MYSQL_RES *mysql_res, row[ 7] QstCod row[ 8] UNIX_TIMESTAMP(QstStartTime) row[ 9] ShowingAnswers - */ + row[10] ShowResults + */ /* Current question index (row[6]) */ Match->Status.QstInd = Gam_GetQstIndFromStr (row[6]); @@ -3040,6 +3046,9 @@ static void Gam_GetMatchDataFromRow (MYSQL_RES *mysql_res, /* Get whether to show question answers or not (row(9)) */ Match->Status.ShowingAnswers = (row[9][0] == 'Y'); + /* Get whether to show results or not (row(10)) */ + Match->Status.ShowResults = (row[10][0] == 'Y'); + /***** Get whether the match is being played or not *****/ if (Match->Status.QstInd >= Gam_AFTER_LAST_QUESTION) // Finished Match->Status.BeingPlayed = false; @@ -3324,7 +3333,8 @@ static long Gam_CreateMatch (long GamCod,char Title[Gam_MAX_BYTES_TITLE + 1]) MchCod = DB_QueryINSERTandReturnCode ("can not create match", "INSERT gam_matches" " (GamCod,UsrCod,StartTime,EndTime,Title," - "QstInd,QstCod,QstStartTime,ShowingAnswers)" + "QstInd,QstCod,QstStartTime," + "ShowingAnswers,ShowResults)" " VALUES" " (%ld," // GamCod "%ld," // UsrCod @@ -3334,7 +3344,8 @@ static long Gam_CreateMatch (long GamCod,char Title[Gam_MAX_BYTES_TITLE + 1]) "0," // QstInd: Match has not started, so not the first question yet "-1," // QstCod: Non-existent question "NOW()," // QstStartTime - "'N')", // ShowingAnswers: Don't show answers initially + "'N'," // ShowingAnswers: Don't show answers initially + "'N')", // ShowResults: Don't show results initially GamCod, Gbl.Usrs.Me.UsrDat.UsrCod, // Game creator Title); @@ -3359,13 +3370,16 @@ static void Gam_UpdateMatchStatusInDB (struct Match *Match) "gam_matches.QstInd=%u," "gam_matches.QstCod=%ld," "gam_matches.QstStartTime=NOW()," - "gam_matches.ShowingAnswers='%c'" + "gam_matches.ShowingAnswers='%c'," + "gam_matches.ShowResults='%c'" " WHERE gam_matches.MchCod=%ld" " AND gam_matches.GamCod=games.GamCod" " AND games.CrsCod=%ld", // Extra check Match->Status.QstInd,Match->Status.QstCod, Match->Status.ShowingAnswers ? 'Y' : 'N', + Match->Status.ShowResults ? 'Y' : + 'N', Match->MchCod,Gbl.Hierarchy.Crs.CrsCod); if (Match->Status.BeingPlayed) @@ -3589,7 +3603,7 @@ void Gam_ShowAnssQstMatchTch (void) } /*****************************************************************************/ -/* Show previous match status (previous question, answers...) (by a teacher) */ +/************* Show previous question in a match (by a teacher) **************/ /*****************************************************************************/ void Gam_PrevQstMatchTch (void) @@ -3617,7 +3631,7 @@ void Gam_PrevQstMatchTch (void) } /*****************************************************************************/ -/***** Show next match status (next question, answers...) (by a teacher) *****/ +/*************** Show next question in a match (by a teacher) ****************/ /*****************************************************************************/ void Gam_NextQstMatchTch (void) @@ -3644,6 +3658,35 @@ void Gam_NextQstMatchTch (void) fprintf (Gbl.F.Out,""); } +/*****************************************************************************/ +/************** Show current question in a match (by a teacher) **************/ +/*****************************************************************************/ + +void Gam_CurrQstMatchTch (void) + { + struct Match Match; + + /***** Remove old players. + This function must be called before getting match status. *****/ + Gam_RemoveOldPlayers (); + + /***** Get data of the match from database *****/ + Match.MchCod = Gbl.Games.MchCodBeingPlayed; + Gam_GetDataOfMatchByCod (&Match); + + /***** Get if results should be displayed *****/ + // Match.Status.ShowResults = Par_GetParToBool ("ShowResults"); + Match.Status.ShowResults = !Match.Status.ShowResults; + + /***** Update match status in database *****/ + Gam_UpdateMatchStatusInDB (&Match); + + /***** Show current match status *****/ + fprintf (Gbl.F.Out,"
"); + Gam_ShowMatchStatusForTch (&Match); + fprintf (Gbl.F.Out,"
"); + } + /*****************************************************************************/ /******************* Set match status to previous question *******************/ /*****************************************************************************/ @@ -3803,7 +3846,10 @@ static void Gam_ShowLeftColumnTch (struct Match *Match) fprintf (Gbl.F.Out,""); /***** Buttons *****/ - Gam_ShowButtons (Match); + Gam_PutMatchControlButtons (Match); + + /***** Checkbox to show results *****/ + Gam_PutCheckboxResult (Match); /***** Number of players *****/ Gam_ShowNumPlayers (Match); @@ -3845,10 +3891,10 @@ static void Gam_ShowLeftColumnStd (struct Match *Match) } /*****************************************************************************/ -/********************* Show buttons to control a match ***********************/ +/********************** Put buttons to control a match ***********************/ /*****************************************************************************/ -static void Gam_ShowButtons (struct Match *Match) +static void Gam_PutMatchControlButtons (struct Match *Match) { extern const char *Txt_Stem; extern const char *Txt_MATCH_Start; @@ -3862,10 +3908,10 @@ static void Gam_ShowButtons (struct Match *Match) unsigned PrvQstInd; // Previous question index unsigned NxtQstInd; // Next question index - /* Start buttons container */ + /***** Start buttons container *****/ fprintf (Gbl.F.Out,"
"); - /* Left button */ + /***** Left button *****/ fprintf (Gbl.F.Out,"
"); if (Match->Status.QstInd < Gam_AFTER_LAST_QUESTION) // Unfinished { @@ -3906,7 +3952,7 @@ static void Gam_ShowButtons (struct Match *Match) fprintf (Gbl.F.Out,"
"); - /* Center button */ + /***** Center button *****/ fprintf (Gbl.F.Out,"
"); if (Match->Status.BeingPlayed) /* Put button to pause match */ @@ -3926,7 +3972,7 @@ static void Gam_ShowButtons (struct Match *Match) } fprintf (Gbl.F.Out,"
"); - /* Right button */ + /***** Right button *****/ fprintf (Gbl.F.Out,"
"); if (Match->Status.QstInd >= Gam_AFTER_LAST_QUESTION) // Finished /* Put button to close browser tab */ @@ -3962,7 +4008,48 @@ static void Gam_ShowButtons (struct Match *Match) } fprintf (Gbl.F.Out,"
"); - /* End buttons container */ + /***** End buttons container *****/ + fprintf (Gbl.F.Out,"
"); + } + +/*****************************************************************************/ +/***************** Put checkbox to select if show results ********************/ +/*****************************************************************************/ + +static void Gam_PutCheckboxResult (struct Match *Match) + { + extern const char *Txt_View_results; + + /***** Start container *****/ + fprintf (Gbl.F.Out,"
"); + + /***** Start form *****/ + Frm_StartForm (ActChgDisResMchTch); + Gam_PutParamMatchCod (Match->MchCod); // Current match being played + + /***** Put icon with link *****/ + /* Submitting onmousedown instead of default onclick + is necessary in order to be fast + and not lose clicks due to refresh */ + fprintf (Gbl.F.Out,"
" + "" + "" + " %s" + "" + "
", + Txt_View_results, + Gbl.Form.Id, + Match->Status.ShowResults ? "fas fa-toggle-on" : + "fas fa-toggle-off", + Txt_View_results); + + /***** End form *****/ + Frm_EndForm (); + + /***** End container *****/ fprintf (Gbl.F.Out,"
"); } @@ -4141,7 +4228,7 @@ static void Gam_ShowQuestionAndAnswersStd (struct Match *Match) is necessary in order to be fast and not lose clicks due to refresh */ Frm_StartForm (ActAnsMchQstStd); - Gam_PutParamMatchCod (Match->MchCod); // Current match being played + Gam_PutParamMatchCod (Match->MchCod); // Current match being played Gam_PutParamQstInd (Match->Status.QstInd); // Current question index shown Gam_PutParamAnswer (Index); // Index for this option fprintf (Gbl.F.Out,"