|
|
@ -86,9 +86,7 @@ function postToElem( post, kind, promoted ) { |
|
|
|
postInfoName.text(n).attr('href', $.MAL.userUrl(n)); |
|
|
|
postInfoName.text(n).attr('href', $.MAL.userUrl(n)); |
|
|
|
getFullname( n, postInfoName ); |
|
|
|
getFullname( n, postInfoName ); |
|
|
|
//elem.find('.post-info-tag').text("@" + n);
|
|
|
|
//elem.find('.post-info-tag').text("@" + n);
|
|
|
|
if( n === defaultScreenName ) { |
|
|
|
|
|
|
|
setPostInfoSent(n,k,elem.find('.post-info-sent')); |
|
|
|
setPostInfoSent(n,k,elem.find('.post-info-sent')); |
|
|
|
} |
|
|
|
|
|
|
|
getAvatar( n, elem.find('.avatar') ); |
|
|
|
getAvatar( n, elem.find('.avatar') ); |
|
|
|
elem.find('.post-info-time').text(timeGmtToText(t)).attr('title', timeSincePost(t)); |
|
|
|
elem.find('.post-info-time').text(timeGmtToText(t)).attr('title', timeSincePost(t)); |
|
|
|
|
|
|
|
|
|
|
@ -145,6 +143,7 @@ function postToElem( post, kind, promoted ) { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
function setPostInfoSent(n, k, item) { |
|
|
|
function setPostInfoSent(n, k, item) { |
|
|
|
|
|
|
|
if( n === defaultScreenName && k >= 0 ) { |
|
|
|
getPostMaxAvailability(n,k, |
|
|
|
getPostMaxAvailability(n,k, |
|
|
|
function(args,count) { |
|
|
|
function(args,count) { |
|
|
|
if( count >= 3 ) { // assume 3 peers (me + 2) is enough for "sent"
|
|
|
|
if( count >= 3 ) { // assume 3 peers (me + 2) is enough for "sent"
|
|
|
@ -155,6 +154,7 @@ function setPostInfoSent(n, k, item) { |
|
|
|
} |
|
|
|
} |
|
|
|
}, {n:n,k:k,item:item}); |
|
|
|
}, {n:n,k:k,item:item}); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// format dmdata (returned by getdirectmsgs) to display in "snippet" per user list
|
|
|
|
// format dmdata (returned by getdirectmsgs) to display in "snippet" per user list
|
|
|
|
function dmDataToSnippetItem(dmData, remoteUser) { |
|
|
|
function dmDataToSnippetItem(dmData, remoteUser) { |
|
|
@ -189,6 +189,7 @@ function dmDataToConversationItem(dmData, localUser, remoteUser) { |
|
|
|
dmItem.addClass(classDm); |
|
|
|
dmItem.addClass(classDm); |
|
|
|
getAvatar(from, dmItem.find(".post-photo").find("img") ); |
|
|
|
getAvatar(from, dmItem.find(".post-photo").find("img") ); |
|
|
|
dmItem.find(".post-info-time").text(timeGmtToText(dmData.time)).attr("title",timeSincePost(dmData.time)); |
|
|
|
dmItem.find(".post-info-time").text(timeGmtToText(dmData.time)).attr("title",timeSincePost(dmData.time)); |
|
|
|
|
|
|
|
setPostInfoSent(from,dmData.k,dmItem.find('.post-info-sent')); |
|
|
|
var mentions = []; |
|
|
|
var mentions = []; |
|
|
|
dmItem.find('.post-text').html(htmlFormatMsg(dmData.text, mentions)); |
|
|
|
dmItem.find('.post-text').html(htmlFormatMsg(dmData.text, mentions)); |
|
|
|
|
|
|
|
|
|
|
|