diff --git a/css/swad_desktop.css b/css/swad_desktop.css index 1de977ec6..f05da22a8 100644 --- a/css/swad_desktop.css +++ b/css/swad_desktop.css @@ -338,14 +338,15 @@ hr.YELLOW_SEPARA {height:0; border-top:0; border-bottom:#BD4815 dotted 1px;} #CENTRAL_ZONE { min-width:740px; + min-height:740px; width:100%; margin:-7px 0 0 0; padding:10px 0; border-radius:6px; box-shadow:inset -2px -2px 1px 0 rgba(50, 50, 50, 0.2); text-align:center; - overflow:hidden; vertical-align:top; + overflow:hidden; position:relative; display:inline-block; } diff --git a/css/swad_mobile.css b/css/swad_mobile.css index e594513a3..792563f20 100644 --- a/css/swad_mobile.css +++ b/css/swad_mobile.css @@ -193,13 +193,16 @@ p {margin:0;} #CENTRAL_ZONE { min-width:740px; + min-height:740px; width:100%; margin:-6px 0 0 0; padding:10px 0; border-radius:8px; box-shadow:inset -2px -2px 1px 0 rgba(50, 50, 50, 0.2); text-align:center; + vertical-align:top; overflow:hidden; + position:relative; display:inline-block; } diff --git a/swad_changelog.h b/swad_changelog.h index 6ae03c279..b449515e5 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -35,11 +35,12 @@ /****************************** Public constants *****************************/ /*****************************************************************************/ -#define Log_PLATFORM_VERSION "SWAD 14.49 (2014/12/31)" +#define Log_PLATFORM_VERSION "SWAD 14.49.1 (2014/12/31)" // 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 | tail -1 /* + Version 14.49.1 :Dec 31, 2014 Changes in layout. (174432 lines) Version 14.49 :Dec 31, 2014 Option to admin one user removed from main menu. Fixed bugs in layout. Fixed bugs in admin of one user. (174419 lines) diff --git a/swad_config.h b/swad_config.h index f0ee54dc1..8b331695b 100644 --- a/swad_config.h +++ b/swad_config.h @@ -289,7 +289,7 @@ #define Cfg_MIN_NUM_COURSES_TO_CONFIRM_SHOW_BIG_LIST 500 // If the number of courses in a list is greater than this, ask me for confirmation before showing the list /* Layout */ -#define Cfg_LAYOUT_MOBILE_NUM_COLUMNS 4 +#define Cfg_LAYOUT_MOBILE_NUM_COLUMNS 3 /* Notifications */ #define Cfg_MAX_CHARS_NOTIF_SUMMARY_SWAD 50 diff --git a/swad_layout.c b/swad_layout.c index 955a223af..824d2b6b2 100644 --- a/swad_layout.c +++ b/swad_layout.c @@ -130,7 +130,7 @@ void Lay_WriteStartOfPage (void) extern const unsigned Txt_Current_CGI_SWAD_Language; extern const char *The_TabOnBgColors[The_NUM_THEMES]; extern const char *Txt_NEW_YEAR_GREETING; - unsigned ColspanCentralPart = 3; + unsigned ColspanCentralPart; // char QueryDebug[1024]; /***** If, when this function is called, the head is being written, or the head is already written ==> @@ -259,17 +259,27 @@ void Lay_WriteStartOfPage (void) Lay_WritePageTopHeading (); - if (Gbl.Prefs.Layout == Lay_LAYOUT_DESKTOP) + switch (Gbl.Prefs.Layout) { - if (Gbl.Prefs.SideCols == Lay_SHOW_BOTH_COLUMNS) // 11: both side columns visible, left and right - ColspanCentralPart = 1; - else if (Gbl.Prefs.SideCols != Lay_HIDE_BOTH_COLUMNS) // 10 or 01: only one side column visible, left or right - ColspanCentralPart = 2; + case Lay_LAYOUT_DESKTOP: + if (Gbl.Prefs.SideCols == Lay_SHOW_BOTH_COLUMNS) + ColspanCentralPart = 1; // 11: both side columns visible, left and right + else if (Gbl.Prefs.SideCols == Lay_HIDE_BOTH_COLUMNS) + ColspanCentralPart = 3; // 00: both side columns hidden + else + ColspanCentralPart = 2; // 10 or 01: only one side column visible, left or right + break; + case Lay_LAYOUT_MOBILE: + ColspanCentralPart = 3; + break; + default: + break; } + fprintf (Gbl.F.Out,"" "
" + " style=\"background-color:%s;\">" "" "", ColspanCentralPart, @@ -290,15 +300,6 @@ void Lay_WriteStartOfPage (void) " vertical-align:top;\">"); Lay_WriteMenuThisTabDesktop (); fprintf (Gbl.F.Out,""); - - /* Start of main zone for actions output */ - fprintf (Gbl.F.Out,""); @@ -1232,8 +1243,8 @@ static void Lay_WriteMenuThisTabMobile (void) (NumAct == Act_Actions[Gbl.CurrentAct].SuperAction) ? The_ClassMenuOn[Gbl.Prefs.Theme] : The_ClassMenuOff[Gbl.Prefs.Theme]); fprintf (Gbl.F.Out,"" + " alt=\"\" class=\"ICON64x64\"" + " style=\"margin:4px;\" />" "
%s
" "" "" @@ -1241,8 +1252,6 @@ static void Lay_WriteMenuThisTabMobile (void) "", Gbl.Prefs.PathIconSet,Cfg_ICON_ACTION_64x64, Act_Actions[NumAct].Icon, - Title, - Title, Txt_MENU_BR[Gbl.CurrentTab][NumOptInMenu]); if ((NumOptVisible % Cfg_LAYOUT_MOBILE_NUM_COLUMNS) ==
"); - - Usr_WarningWhenDegreeTypeDoesntAllowDirectLogin (); - - /* If it is mandatory to read any information about course */ - if (Gbl.CurrentCrs.Info.ShowMsgMustBeRead) - Inf_WriteMsgYouMustReadInfo (); break; case Lay_LAYOUT_MOBILE: /* Tab content */ @@ -318,6 +319,16 @@ void Lay_WriteStartOfPage (void) } /***** Main zone *****/ + /* Start of main zone for actions output */ + fprintf (Gbl.F.Out,""); + + Usr_WarningWhenDegreeTypeDoesntAllowDirectLogin (); + + /* If it is mandatory to read any information about course */ + if (Gbl.CurrentCrs.Info.ShowMsgMustBeRead) + Inf_WriteMsgYouMustReadInfo (); + /* Write title of the current action */ if (Gbl.Prefs.Layout == Lay_LAYOUT_DESKTOP && Act_Actions[Act_Actions[Gbl.CurrentAct].SuperAction].IndexInMenu >= 0) @@ -1131,7 +1142,7 @@ static void Lay_WriteMenuThisTabDesktop (void) { IsTheSelectedAction = (NumAct == Act_Actions[Gbl.CurrentAct].SuperAction); - Title = Act_GetTitleAction (NumAct); + Title = Act_GetSubtitleAction (NumAct); if (SeparationBetweenPreviousAndCurrentOption) { @@ -1217,7 +1228,7 @@ static void Lay_WriteMenuThisTabMobile (void) break; if (Act_CheckIfIHavePermissionToExecuteAction (NumAct)) { - Title = Act_GetTitleAction (NumAct); + Title = Act_GetSubtitleAction (NumAct); if (NumOptVisible % Cfg_LAYOUT_MOBILE_NUM_COLUMNS == 0) fprintf (Gbl.F.Out,"