From 590ebe74e42fea57921f1e760e544bbf12133efa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Ca=C3=B1as=20Vargas?= Date: Tue, 24 Nov 2015 13:27:46 +0100 Subject: [PATCH] Version 15.44.8 --- swad_changelog.h | 3 +- swad_config.h | 36 ++++++++++++++++++------ swad_layout.c | 73 +++++++++++++++++------------------------------- swad_role.c | 4 +-- 4 files changed, 57 insertions(+), 59 deletions(-) diff --git a/swad_changelog.h b/swad_changelog.h index b66669643..70bfef496 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -111,11 +111,12 @@ /****************************** Public constants *****************************/ /*****************************************************************************/ -#define Log_PLATFORM_VERSION "SWAD 15.44.7 (2015/11/24)" +#define Log_PLATFORM_VERSION "SWAD 15.44.8 (2015/11/24)" // 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 15.44.8: Nov 24, 2015 Code refactoring in layout. (187895 lines) Version 15.44.7: Nov 24, 2015 Code refactoring in layout. (187901 lines) Version 15.44.6: Nov 24, 2015 Code refactoring in layout. (187893 lines) Version 15.44.5: Nov 24, 2015 Code refactoring in layout. (187894 lines) diff --git a/swad_config.h b/swad_config.h index d5f9bbf0a..50a55ebb0 100644 --- a/swad_config.h +++ b/swad_config.h @@ -51,8 +51,6 @@ #define Cfg_PLATFORM_SHORT_NAME "SWAD" #define Cfg_PLATFORM_FULL_NAME "SWAD (Shared Workspace At a Distance)" #define Cfg_PLATFORM_PAGE_TITLE "SWAD local" // This title will appear on browser top -#define Cfg_PLATFORM_LOGO_DESKTOP "openswad220x40.png" // Logo displayed in the top of the page -#define Cfg_PLATFORM_LOGO_MOBILE "openswad330x60.png" // Logo displayed in the top of the page #define Cfg_PLATFORM_SERVER "localhost" // Server name (main part of the URL) #define Cfg_HTTPS_URL_SWAD_CGI "https://localhost/swad" // Without ending slash #define Cfg_HTTPS_URL_SWAD_PUBLIC "https://localhost/swad" // Without ending slash @@ -61,6 +59,13 @@ #define Cfg_PATH_SWAD_PUBLIC "/var/www/html/swad" // Main public directory for public SWAD pages, icons, etc. #define Cfg_PATH_SWAD_PRIVATE "/var/www/swad" // Main private directory for SWAD private data +#define Cfg_PLATFORM_LOGO_DESKTOP_FILE "openswad240x40.png" // Logo displayed in the top of the page +#define Cfg_PLATFORM_LOGO_DESKTOP_WIDTH 240 +#define Cfg_PLATFORM_LOGO_DESKTOP_HEIGHT 40 +#define Cfg_PLATFORM_LOGO_MOBILE_FILE "openswad330x60.png" // Logo displayed in the top of the page +#define Cfg_PLATFORM_LOGO_MOBILE_WIDTH 330 +#define Cfg_PLATFORM_LOGO_MOBILE_HEIGHT 60 + #define Cfg_PLATFORM_RESPONSIBLE_NAME "Antonio Cañas Vargas" // Main responsible for the platform #define Cfg_PLATFORM_RESPONSIBLE_E_MAIL "webmaster@openswad.org" // Main responsible for the platform #define Cfg_HELP_WEB "http://cevug.ugr.es/contactar/contactar_multilang_simple_.php?amb=tic" // Web to solve questions and problems @@ -99,8 +104,6 @@ #define Cfg_PLATFORM_SHORT_NAME "OpenSWAD" #define Cfg_PLATFORM_FULL_NAME "OpenSWAD (Open Shared Workspace At a Distance)" #define Cfg_PLATFORM_PAGE_TITLE "OpenSWAD (free platform for learning & educational management)" // This title will appear on browser top -#define Cfg_PLATFORM_LOGO_DESKTOP "openswad220x40.png" // Logo displayed in the top of the page -#define Cfg_PLATFORM_LOGO_MOBILE "openswad330x60.png" // Logo displayed in the top of the page #define Cfg_PLATFORM_SERVER "openswad.org" // Server name (main part of the URL) #define Cfg_HTTPS_URL_SWAD_CGI "https://openswad.org" // Without ending slash #define Cfg_HTTPS_URL_SWAD_PUBLIC "https://openswad.org/swad" // Without ending slash @@ -109,6 +112,13 @@ #define Cfg_PATH_SWAD_PUBLIC "/var/www/html/swad" // Main public directory for public SWAD pages, icons, etc. #define Cfg_PATH_SWAD_PRIVATE "/var/www/swad" // Main private directory for SWAD private data +#define Cfg_PLATFORM_LOGO_DESKTOP_FILE "openswad240x40.png" // Logo displayed in the top of the page +#define Cfg_PLATFORM_LOGO_DESKTOP_WIDTH 240 +#define Cfg_PLATFORM_LOGO_DESKTOP_HEIGHT 40 +#define Cfg_PLATFORM_LOGO_MOBILE_FILE "openswad330x60.png" // Logo displayed in the top of the page +#define Cfg_PLATFORM_LOGO_MOBILE_WIDTH 330 +#define Cfg_PLATFORM_LOGO_MOBILE_HEIGHT 60 + #define Cfg_PLATFORM_RESPONSIBLE_NAME "Antonio Caņas Vargas" // Main responsible for the platform #define Cfg_PLATFORM_RESPONSIBLE_E_MAIL "webmaster@openswad.org" // Main responsible for the platform #define Cfg_HELP_WEB "http://openswad.org/SWAD-sheet.pdf" // Web to solve questions and problems @@ -164,8 +174,6 @@ #define Cfg_PLATFORM_SHORT_NAME "SWAD" #define Cfg_PLATFORM_FULL_NAME "SWAD (Shared Workspace At a Distance)" #define Cfg_PLATFORM_PAGE_TITLE "SWAD UGR" // This title will appear on browser top -#define Cfg_PLATFORM_LOGO_DESKTOP "swad220x40.png" // Logo displayed in the top of the page -#define Cfg_PLATFORM_LOGO_MOBILE "swad330x60.png" // Logo displayed in the top of the page #define Cfg_PLATFORM_SERVER "swad.ugr.es" // Server name (main part of the URL) #define Cfg_HTTPS_URL_SWAD_CGI "https://swad.ugr.es" // Without ending slash #define Cfg_HTTPS_URL_SWAD_PUBLIC "https://swad.ugr.es/swad" // Without ending slash @@ -174,6 +182,13 @@ #define Cfg_PATH_SWAD_PUBLIC "/var/www/html/swad" // Main public directory for public SWAD pages, icons, etc. #define Cfg_PATH_SWAD_PRIVATE "/var/www/swad" // Main private directory for SWAD private data +#define Cfg_PLATFORM_LOGO_DESKTOP_FILE "swad160x40.png" // Logo displayed in the top of the page +#define Cfg_PLATFORM_LOGO_DESKTOP_WIDTH 160 +#define Cfg_PLATFORM_LOGO_DESKTOP_HEIGHT 40 +#define Cfg_PLATFORM_LOGO_MOBILE_FILE "swad210x60.png" // Logo displayed in the top of the page +#define Cfg_PLATFORM_LOGO_MOBILE_WIDTH 210 +#define Cfg_PLATFORM_LOGO_MOBILE_HEIGHT 60 + #define Cfg_PLATFORM_RESPONSIBLE_NAME "CEVUG" // Main responsible for the platform #define Cfg_PLATFORM_RESPONSIBLE_E_MAIL "sctecnico@ugr.es" // Main responsible for the platform #define Cfg_HELP_WEB "http://cevug.ugr.es/contactar/contactar_multilang_simple_.php?amb=tic" // Web to solve questions and problems @@ -219,8 +234,6 @@ #define Cfg_PLATFORM_SHORT_NAME "SWAD" #define Cfg_PLATFORM_FULL_NAME "SWAD (Shared Workspace At a Distance)" #define Cfg_PLATFORM_PAGE_TITLE "SWAD UNA" // This title will appear on browser top -#define Cfg_PLATFORM_LOGO_DESKTOP "swad220x40.png" // Logo displayed in the top of the page -#define Cfg_PLATFORM_LOGO_MOBILE "swad330x60.png" // Logo displayed in the top of the page #define Cfg_PLATFORM_SERVER "www.cevuna.una.py" // Server name (main part of the URL) #define Cfg_HTTPS_URL_SWAD_CGI "https://www.cevuna.una.py/swad" // Without ending slash #define Cfg_HTTPS_URL_SWAD_PUBLIC "https://www.cevuna.una.py/swad" // Without ending slash @@ -229,6 +242,13 @@ #define Cfg_PATH_SWAD_PUBLIC "/var/www/html/swad" // Main public directory for public SWAD pages, icons, etc. #define Cfg_PATH_SWAD_PRIVATE "/var/www/swad" // Main private directory for SWAD private data +#define Cfg_PLATFORM_LOGO_DESKTOP_FILE "swad160x40.png" // Logo displayed in the top of the page +#define Cfg_PLATFORM_LOGO_DESKTOP_WIDTH 160 +#define Cfg_PLATFORM_LOGO_DESKTOP_HEIGHT 40 +#define Cfg_PLATFORM_LOGO_MOBILE_FILE "swad210x60.png" // Logo displayed in the top of the page +#define Cfg_PLATFORM_LOGO_MOBILE_WIDTH 210 +#define Cfg_PLATFORM_LOGO_MOBILE_HEIGHT 60 + #define Cfg_PLATFORM_RESPONSIBLE_NAME "Carmen Varela Báez" // Main responsible for the platform #define Cfg_PLATFORM_RESPONSIBLE_E_MAIL "cevuna@rec.una.py" // Main responsible for the platform #define Cfg_HELP_WEB "http://www.cevuna.una.py/" // Web to solve questions and problems diff --git a/swad_layout.c b/swad_layout.c index 0faa573a0..e7994af97 100644 --- a/swad_layout.c +++ b/swad_layout.c @@ -700,17 +700,6 @@ static void Lay_WriteScriptCustomDropzone (void) static void Lay_WritePageTopHeadingDesktop (void) { extern const char *The_ClassHead[The_NUM_THEMES]; - const struct - { - const char *Icon; - const unsigned Width; - const unsigned Height; - } LogoLayout = - { - Cfg_PLATFORM_LOGO_DESKTOP, - 220, - 40, - }; const char *ClassHeadRow1[The_NUM_THEMES] = { "WHITE_HEAD_ROW_1", // The_THEME_WHITE @@ -720,14 +709,30 @@ static void Lay_WritePageTopHeadingDesktop (void) }; /***** 1st. row *****/ - /* 1st. row, 1st. column: search */ + /* 1st. row, 2nd. column: logo */ fprintf (Gbl.F.Out,"" "" "" "" - "", + ClassHeadRow1[Gbl.Prefs.Theme], + The_ClassHead[Gbl.Prefs.Theme], + Cfg_PLATFORM_LOGO_DESKTOP_WIDTH, + Cfg_HTTPS_URL_SWAD_CGI, + Gbl.Prefs.IconsURL,Cfg_PLATFORM_LOGO_DESKTOP_FILE, + Cfg_PLATFORM_SHORT_NAME,Cfg_PLATFORM_FULL_NAME, + Cfg_PLATFORM_LOGO_DESKTOP_WIDTH, + Cfg_PLATFORM_LOGO_DESKTOP_HEIGHT); + + /* 1st. row, 1st. column: search */ + fprintf (Gbl.F.Out,""); - - /* 1st. row, 2nd. column: logo */ - fprintf (Gbl.F.Out,"", - The_ClassHead[Gbl.Prefs.Theme], - Cfg_HTTPS_URL_SWAD_CGI, - Gbl.Prefs.IconsURL,LogoLayout.Icon, - Cfg_PLATFORM_SHORT_NAME,Cfg_PLATFORM_FULL_NAME, - LogoLayout.Width, - LogoLayout.Height); + fprintf (Gbl.F.Out,""); /* 1st. row, 3rd. column: logged user or language selection */ fprintf (Gbl.F.Out,"", ClassHeadRow1[Gbl.Prefs.Theme], - LogoLayout.Width + 20, + Cfg_PLATFORM_LOGO_MOBILE_WIDTH, Cfg_HTTPS_URL_SWAD_CGI, - Gbl.Prefs.IconsURL,LogoLayout.Icon, + Gbl.Prefs.IconsURL,Cfg_PLATFORM_LOGO_MOBILE_FILE, Cfg_PLATFORM_SHORT_NAME,Cfg_PLATFORM_FULL_NAME, - LogoLayout.Width, - LogoLayout.Height); + Cfg_PLATFORM_LOGO_MOBILE_WIDTH, + Cfg_PLATFORM_LOGO_MOBILE_HEIGHT); /***** 1st. row, 2nd. column: logged user / language selection *****/ diff --git a/swad_role.c b/swad_role.c index a4509ef56..0a807774e 100644 --- a/swad_role.c +++ b/swad_role.c @@ -288,8 +288,8 @@ void Rol_PutFormToChangeMyRole (bool FormInHead) extern const char *Txt_ROLES_SINGUL_Abc[Rol_NUM_ROLES][Usr_NUM_SEXS]; static const unsigned SelectorWidth[Lay_NUM_LAYOUTS] = { - 112, // Lay_LAYOUT_DESKTOP - 112, // Lay_LAYOUT_MOBILE + 130, // Lay_LAYOUT_DESKTOP + 200, // Lay_LAYOUT_MOBILE }; Rol_Role_t Role;
" - "
", - ClassHeadRow1[Gbl.Prefs.Theme]); + "
" + "" + "\"%s\"" + "" + ""); Act_FormStart ( Gbl.CurrentCrs.Crs.CrsCod > 0 ? ActCrsSch : (Gbl.CurrentDeg.Deg.DegCod > 0 ? ActDegSch : (Gbl.CurrentCtr.Ctr.CtrCod > 0 ? ActCtrSch : @@ -737,24 +742,7 @@ static void Lay_WritePageTopHeadingDesktop (void) Sco_PutParamScope (Sco_SCOPE_SYS); Sch_PutFormToSearch (Gbl.Prefs.PathTheme); Act_FormEnd (); - fprintf (Gbl.F.Out,"" - "" - "" - "\"%s\"" - "" - "", @@ -849,17 +837,6 @@ static void Lay_WritePageTopHeadingDesktop (void) static void Lay_WritePageTopHeadingMobile (void) { extern const char *The_ClassHead[The_NUM_THEMES]; - const struct - { - const char *Icon; - const unsigned Width; - const unsigned Height; - } LogoLayout = - { - Cfg_PLATFORM_LOGO_MOBILE, - 330, - 60, - }; const char *ClassHeadRow1[The_NUM_THEMES] = { "WHITE_HEAD_ROW_1", // The_THEME_WHITE @@ -879,12 +856,12 @@ static void Lay_WritePageTopHeadingMobile (void) "" "