Version 15.131.3

This commit is contained in:
Antonio Cañas Vargas 2016-01-27 13:20:08 +01:00
parent 1799cacf8e
commit 9758de7ada
4 changed files with 32 additions and 16 deletions

View File

@ -586,6 +586,11 @@ function readOldTimelineData () {
if (countOldTimeline < 20) // Set to Soc_MAX_OLD_PUBS_TO_GET_AND_SHOW
// No more old publishings
document.getElementById("view_old_posts_container").style.display = 'none';
else {
// There may be more publishings
document.getElementById('get_old_timeline').style.display=''; // Show icon to be hidden on click
document.getElementById('getting_old_timeline').style.display='none'; // Hide icon to be shown on click
}
}
}
}

View File

@ -4509,7 +4509,7 @@ void Act_LinkFormSubmitAnimated (const char *Title,const char *LinkStyle)
if (LinkStyle[0])
fprintf (Gbl.F.Out," class=\"%s\"",LinkStyle);
fprintf (Gbl.F.Out," onclick=\""
"document.getElementById('update_%d').style.display='none';" // Icon to be hiden on click
"document.getElementById('update_%d').style.display='none';" // Icon to be hidden on click
"document.getElementById('updating_%d').style.display='';" // Icon to be shown on click
"document.getElementById('%s').submit();"
"return false;\">",

View File

@ -116,23 +116,25 @@
// TODO: Enable chat for guests?
// TODO: Go to forum post (or at least to forum thread) from social timeline and notifications?
// TODO: Width of column for data in notifications is too short
// TODO: Recommendations about users to follow
/*****************************************************************************/
/****************************** Public constants *****************************/
/*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 15.131.2 (2016-01-26)"
#define Log_PLATFORM_VERSION "SWAD 15.131.3 (2016-01-27)"
#define CSS_FILE "swad15.131.2.css"
#define JS_FILE "swad15.121.7.js"
#define JS_FILE "swad15.131.3.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.131.3: Jan 27, 2016 Animated link to view old timeline. (195015 lines)
Version 15.131.2: Jan 26, 2016 Change in default color of links. (194998 lines)
Version 15.131.1: Jan 26, 2016 Optimization in the function that insert links in text. (194993 lines)
Version 15.131: Jan 26, 2016 Link around @nickname is inserted as form. (195011 lines)
Version 15.130.2: Jan 26, 2016 Optimization in the function that insert links in text. (194928 lines)
Version 15.130.1: Jan 26, 2016 Fixed bug when mentioning an user who does not exist. (194914 lines)
Version 15.130.1: Jan 26, 2016 Fixed bug when mentioning a user who does not exist. (194914 lines)
Version 15.130: Jan 26, 2016 Do not notify new social notes. (194913 lines)
22 changes necessary in database:
UPDATE notif SET NotifyEvent= 9 WHERE NotifyEvent=10;

View File

@ -51,7 +51,7 @@
/*****************************************************************************/
#define Soc_WIDTH_TIMELINE "560px"
#define Soc_MAX_SHARERS_FAVERS_SHOWN 6 // Maximum number of users shown who have share/fav a social note
#define Soc_MAX_SHARERS_FAVERS_SHOWN 7 // 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
@ -617,7 +617,7 @@ static void Soc_BuildQueryToGetTimeline (Soc_TimelineUsrOrGbl_t TimelineUsrOrGbl
With the current approach, we select one by one
the publishings and notes in a loop. In each iteration,
we get the more recent publishing (original, shared or commment)
of every set of publishings corresponding to the same note:
of every set of publishings corresponding to the same note,
checking that the note is not already retrieved.
After getting a publishing, its note code is stored
in order to not get it again.
@ -1011,15 +1011,26 @@ static void Soc_PutLinkToViewOldPublishings (void)
extern const char *The_ClassFormBold[The_NUM_THEMES];
extern const char *Txt_See_more;
/***** Link to view old publishings *****/
/***** Animated link to view old publishings *****/
fprintf (Gbl.F.Out,"<div id=\"view_old_posts_container\""
" class=\"SOCIAL_PUB VERY_LIGHT_BLUE\">"
"<a href=\"\" class=\"%s\""
" onclick=\"refreshOldTimeline();return false;\" />"
"%s"
"<a href=\"\" class=\"%s\" onclick=\""
"document.getElementById('get_old_timeline').style.display='none';" // Icon to be hidden on click
"document.getElementById('getting_old_timeline').style.display='';" // Icon to be shown on click
"refreshOldTimeline();"
"return false;\">"
"<img id=\"get_old_timeline\""
" src=\"%s/recycle16x16.gif\" alt=\"%s\" title=\"%s\""
" class=\"ICON20x20\" />"
"<img id=\"getting_old_timeline\""
" src=\"%s/working16x16.gif\" alt=\"%s\" title=\"%s\""
" class=\"ICON20x20\" style=\"display:none;\" />" // Animated icon hidden
"&nbsp;%s"
"</a>"
"</div>",
The_ClassFormBold[Gbl.Prefs.Theme],
Gbl.Prefs.IconsURL,Txt_See_more,Txt_See_more,
Gbl.Prefs.IconsURL,Txt_See_more,Txt_See_more,
Txt_See_more);
}
@ -1363,7 +1374,7 @@ static void Soc_WriteTopMessage (Soc_TopMessage_t TopMessage,long UsrCod)
}
/*****************************************************************************/
/************ Write name and nickname of autor of a social note **************/
/************ Write name and nickname of author of a social note *************/
/*****************************************************************************/
// All forms in this function and nested functions must have unique identifiers
@ -1438,10 +1449,8 @@ static void Soc_GetAndWriteSocialPost (long PstCod)
/***** Result should have a unique row *****/
if (NumRows == 1)
{
/***** Get number of rows *****/
row = mysql_fetch_row (mysql_res);
/****** Get content (row[0]) *****/
row = mysql_fetch_row (mysql_res);
strncpy (Content,row[0],Cns_MAX_BYTES_LONG_TEXT);
Content[Cns_MAX_BYTES_LONG_TEXT] = '\0';
}
@ -1542,7 +1551,7 @@ static void Soc_PutFormGoToAction (const struct SocialNote *SocNot)
};
if (SocNot->Unavailable || // File/notice... pointer by this social note is unavailable
if (SocNot->Unavailable || // File/notice... pointed by this social note is unavailable
Gbl.Form.Inside) // Inside another form
{
/***** Do not put form *****/
@ -2325,7 +2334,7 @@ static void Soc_WriteSocialComment (struct SocialComment *SocCom,
}
/*****************************************************************************/
/****** Write name and nickname of autor of a comment to a social note *******/
/****** Write name and nickname of author of a comment to a social note ******/
/*****************************************************************************/
// All forms in this function and nested functions must have unique identifiers