diff --git a/swad_changelog.h b/swad_changelog.h index 280bf0e75..9931ce732 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -172,13 +172,14 @@ /****************************** Public constants *****************************/ /*****************************************************************************/ -#define Log_PLATFORM_VERSION "SWAD 16.68 (2016-11-22)" +#define Log_PLATFORM_VERSION "SWAD 16.68.1 (2016-11-22)" #define CSS_FILE "swad16.68.css" #define JS_FILE "swad16.46.1.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.68.1: Nov 22, 2016 Code refactoringrelated to notifications and contextual checkbox. (207438 lines) Version 16.68: Nov 22, 2016 Change in text related to notifications. Changes in contextual links in notifications. (207406 lines) Version 16.67.3: Nov 22, 2016 Contextual help on notifications. (207355 lines) diff --git a/swad_layout.c b/swad_layout.c index ea4a06b72..e18a0d96a 100644 --- a/swad_layout.c +++ b/swad_layout.c @@ -1002,7 +1002,7 @@ static void Lay_ShowRightColumn (void) } /*****************************************************************************/ -/***************** Show an icon with a link in contextual menu ***************/ +/**************** Show an icon with a link in contextual menu ****************/ /*****************************************************************************/ void Lay_PutContextualLink (Act_Action_t NextAction, @@ -1013,19 +1013,75 @@ void Lay_PutContextualLink (Act_Action_t NextAction, { extern const char *The_ClassFormBold[The_NUM_THEMES]; + /***** Separator *****/ if (Text) fprintf (Gbl.F.Out," "); // This space is necessary to enable // jumping to the next line on narrow screens + /***** Start form *****/ Act_FormStart (NextAction); if (FuncParams) FuncParams (); + + /***** Put icon with link *****/ Lay_PutIconLink (Icon,Title,Text, Text ? The_ClassFormBold[Gbl.Prefs.Theme] : NULL, OnSubmit); + + /***** End form *****/ Act_FormEnd (); + /***** Separator *****/ + if (Text) + fprintf (Gbl.F.Out," "); // This space is necessary to enable + // jumping to the next line on narrow screens + } + +/*****************************************************************************/ +/******************** Show a checkbox in contextual menu *********************/ +/*****************************************************************************/ + +void Lay_PutContextualCheckbox (Act_Action_t NextAction, + const char *CheckboxName,bool Checked, + const char *Title,const char *Text) + { + extern const char *The_ClassFormBold[The_NUM_THEMES]; + + /***** Separator *****/ + if (Text) + fprintf (Gbl.F.Out," "); // This space is necessary to enable + // jumping to the next line on narrow screens + + /***** Start form *****/ + Act_FormStart (NextAction); + + /***** Start container *****/ + fprintf (Gbl.F.Out,"