Version 15.120.3

This commit is contained in:
Antonio Cañas Vargas 2016-01-19 02:08:44 +01:00
parent 5c072bc4d1
commit 5933e9cb58
4 changed files with 90 additions and 61 deletions

View File

@ -1754,17 +1754,25 @@ a:hover img.CENTRE_PHOTO_SHOW
margin:0;
resize:none;
}
/*
.SOCIAL_FORM_POST:focus {
height:200px;
}
*/
.SOCIAL_TXT
{
padding-top:2px;
color:#404040;
font-size:13pt;
}
.SOCIAL_ICON_COMMENT
{
display:inline-block;
padding-top:10px;
vertical-align:bottom;
}
.SOCIAL_ICON_COMMENT_DISABLED
{
display:inline-block;
padding-top:10px;
opacity:0.1;
vertical-align:bottom;
}
.SOCIAL_ICON_SHARE_FAV
{
display:inline-block;
@ -1777,7 +1785,7 @@ a:hover img.CENTRE_PHOTO_SHOW
display:inline-block;
padding-top:10px;
padding-left:20px;
opacity:0.2;
opacity:0.1;
vertical-align:bottom;
}
.SOCIAL_ICON_REMOVE

View File

@ -122,13 +122,14 @@
/****************************** Public constants *****************************/
/*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 15.120.2 (2016-01-19)"
#define CSS_FILE "swad15.120.2.css"
#define Log_PLATFORM_VERSION "SWAD 15.120.3 (2016-01-19)"
#define CSS_FILE "swad15.120.3.css"
#define JS_FILE "swad15.118.4.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 15.120.3: Jan 19, 2016 Minor changes in layout of timeline. (193517 lines)
Version 15.120.2: Jan 19, 2016 Code optimization on sharers or favers. (193491 lines)
Version 15.120.1: Jan 19, 2016 Show number of users who marked a social note as favourite. (193533 lines)
Version 15.120: Jan 19, 2016 Mark/unmark social notes as favourites. (193475 lines)

View File

@ -50,7 +50,7 @@
/*****************************************************************************/
#define Soc_WIDTH_TIMELINE "560px"
#define Soc_MAX_SHARERS_FAVERS_SHOWN 10 // Maximum number of users shown who have share/fav a social note
#define Soc_MAX_SHARERS_FAVERS_SHOWN 6 // Maximum number of users shown who have share/fav a social note
#define Soc_MAX_BYTES_SUMMARY 1000
#define Soc_MAX_CHARS_IN_POST 1000
@ -261,6 +261,7 @@ static long Soc_ReceiveSocialPost (void);
static void Soc_PutIconToToggleCommentSocialNote (const char UniqueId[Soc_MAX_LENGTH_ID],
bool PutText);
static void Soc_PutIconCommentDisabled (void);
static void Soc_PutHiddenFormToWriteNewCommentToSocialNote (long NotCod,
const char IdNewComment[Soc_MAX_LENGTH_ID]);
static unsigned long Soc_GetNumCommentsInSocialNote (long NotCod);
@ -1115,7 +1116,7 @@ static void Soc_WriteSocialNote (const struct SocialNote *SocNot,
if (SocNot->NoteType == Soc_NOTE_SOCIAL_POST)
{
/* Write post content */
fprintf (Gbl.F.Out,"<div class=\"DAT\">");
fprintf (Gbl.F.Out,"<div class=\"SOCIAL_TXT\">");
Soc_GetAndWriteSocialPost (SocNot->Cod);
fprintf (Gbl.F.Out,"</div>");
}
@ -1225,8 +1226,9 @@ static void Soc_WriteSocialNote (const struct SocialNote *SocNot,
NumComments = Soc_GetNumCommentsInSocialNote (SocNot->NotCod);
/* Put icon to add a comment */
if (!NumComments &&
!SocNot->Unavailable) // Unavailable social notes can not be commented
if (NumComments || SocNot->Unavailable) // Unavailable social notes can not be commented
Soc_PutIconCommentDisabled ();
else
Soc_PutIconToToggleCommentSocialNote (IdNewComment,false);
/* Put icons to share/unshare */
@ -2005,6 +2007,25 @@ static void Soc_PutIconToToggleCommentSocialNote (const char UniqueId[Soc_MAX_LE
"</div>");
}
/*****************************************************************************/
/****** Put an icon to toggle on/off the form to comment a social note *******/
/*****************************************************************************/
static void Soc_PutIconCommentDisabled (void)
{
extern const char *The_ClassForm[The_NUM_THEMES];
extern const char *Txt_Comment;
/***** Disabled icon to comment a social note *****/
fprintf (Gbl.F.Out,"<div class=\"SOCIAL_ICON_COMMENT_DISABLED\">"
"<img src=\"%s/write64x64.gif\""
" alt=\"%s\" title=\"%s\""
" class=\"ICON20x20\" />"
"</div>",
Gbl.Prefs.IconsURL,
Txt_Comment,Txt_Comment);
}
/*****************************************************************************/
/******************* Form to comment a social publishing *********************/
/*****************************************************************************/
@ -2182,7 +2203,7 @@ static void Soc_WriteSocialComment (struct SocialComment *SocCom,
Soc_WriteDateTime (SocCom->DateTimeUTC);
/* Write content of the social comment */
fprintf (Gbl.F.Out,"<div class=\"DAT\">");
fprintf (Gbl.F.Out,"<div class=\"SOCIAL_TXT\">");
Msg_WriteMsgContent (SocCom->Content,Cns_MAX_BYTES_LONG_TEXT,true,false);
fprintf (Gbl.F.Out,"</div>");
@ -2337,8 +2358,7 @@ static void Soc_PutFormToShareSocialNote (long NotCod)
" class=\"ICON20x20\" />"
"</div>",
Gbl.Prefs.IconsURL,
Txt_Share,
Txt_Share);
Txt_Share,Txt_Share);
Act_FormEnd ();
}
@ -2378,7 +2398,7 @@ static void Soc_PutFormToFavSocialNote (long NotCod)
static void Soc_PutFormToUnshareSocialNote (long NotCod)
{
extern const char *Txt_Unshare;
extern const char *Txt_SOCIAL_NOTE_Shared;
/***** Form to share social publishing *****/
if (Gbl.Usrs.Other.UsrDat.UsrCod > 0)
@ -2396,7 +2416,7 @@ static void Soc_PutFormToUnshareSocialNote (long NotCod)
" class=\"ICON20x20\" />"
"</div>",
Gbl.Prefs.IconsURL,
Txt_Unshare,Txt_Unshare);
Txt_SOCIAL_NOTE_Shared,Txt_SOCIAL_NOTE_Shared);
Act_FormEnd ();
}
@ -2407,7 +2427,7 @@ static void Soc_PutFormToUnshareSocialNote (long NotCod)
static void Soc_PutFormToUnfavSocialNote (long NotCod)
{
extern const char *Txt_Favourite;
extern const char *Txt_SOCIAL_NOTE_Favourite;
/***** Form to share social publishing *****/
if (Gbl.Usrs.Other.UsrDat.UsrCod > 0)
@ -2425,7 +2445,7 @@ static void Soc_PutFormToUnfavSocialNote (long NotCod)
" class=\"ICON20x20\" />"
"</div>",
Gbl.Prefs.IconsURL,
Txt_Favourite,Txt_Favourite);
Txt_SOCIAL_NOTE_Favourite,Txt_SOCIAL_NOTE_Favourite);
Act_FormEnd ();
}

View File

@ -11055,27 +11055,6 @@ const char *Txt_Family_address =
"Endere&ccedil;o Fam&iacute;lia";
#endif
const char *Txt_Favourite =
#if L==1
"Favorit";
#elif L==2
"Favorit";
#elif L==3
"Favourite";
#elif L==4
"Favorito";
#elif L==5
"Favori";
#elif L==6
"Favorito"; // Okoteve traducción
#elif L==7
"Preferito";
#elif L==8
"Ulubiony";
#elif L==9
"Favorito";
#endif
const char *Txt_Feedback =
#if L==1
"Realimentaci&oacute;n"; // Necessita traduccio
@ -35782,6 +35761,27 @@ const char *Txt_SOCIAL_NOTE[Soc_NUM_NOTE_TYPES] =
#endif
};
const char *Txt_SOCIAL_NOTE_Favourite =
#if L==1
"Favorit";
#elif L==2
"Favorit";
#elif L==3
"Favourite";
#elif L==4
"Favorito";
#elif L==5
"Favori";
#elif L==6
"Favorito"; // Okoteve traducción
#elif L==7
"Preferito";
#elif L==8
"Ulubiony";
#elif L==9
"Favorito";
#endif
const char *Txt_SOCIAL_NOTE_Favourited_by_X_USERS = // Warning: it is very important to include %u in the following sentences
#if L==1
"Marcat com favorit per %u";
@ -35803,6 +35803,27 @@ const char *Txt_SOCIAL_NOTE_Favourited_by_X_USERS = // Warning: it is very impor
"Marcado como favorito por %u";
#endif
const char *Txt_SOCIAL_NOTE_Shared =
#if L==1
"Compartit";
#elif L==2
"Geteilt";
#elif L==3
"Shared";
#elif L==4
"Compartido";
#elif L==5
"Partag&eacute;";
#elif L==6
"Compartido"; // Okoteve traducción
#elif L==7
"Condiviso";
#elif L==8
"Udost&eogon;pnione";
#elif L==9
"Compartilhado";
#endif
const char *Txt_SOCIAL_NOTE_Shared_by_X_USERS = // Warning: it is very important to include %u in the following sentences
#if L==1
"Compartit per %u";
@ -47225,27 +47246,6 @@ const char *Txt_Unread_BR_msgs =
"N&atilde;o<br />lidas";
#endif
const char *Txt_Unshare =
#if L==1
"Compartir";
#elif L==2
"Teilen";
#elif L==3
"Unshare";
#elif L==4
"Dejar de compartir";
#elif L==5
"Arr&ecirc;ter le partage";
#elif L==6
"Dejar de compartir"; // Okoteve traducción
#elif L==7
"Interrompere la condivisione";
#elif L==8
"Zatrzymaj udost&eogon;pnianie";
#elif L==9
"Descompartilhar";
#endif
const char *Txt_Update =
#if L==1
"Actualitzar";