X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fmain%2Fresources%2Fstatic%2Fjavascript%2Fsone.js;h=22b7eb2fddd1877dd63d6c9730ba44e2817fca32;hb=26c0e6947244544c083ea97d7b42bcc1b0ea7d3b;hp=6ff4cebccc16b82157738db2af13e4d09aaae3a6;hpb=90c0deafa5446199a89d9b7e1b8c1f239d0c667a;p=Sone.git diff --git a/src/main/resources/static/javascript/sone.js b/src/main/resources/static/javascript/sone.js index 6ff4ceb..22b7eb2 100644 --- a/src/main/resources/static/javascript/sone.js +++ b/src/main/resources/static/javascript/sone.js @@ -71,7 +71,6 @@ function addCommentLink(postId, element, insertAfterThisElement) { commentElement = (function(postId) { separator = $(" · ").addClass("separator"); var commentElement = $("
Comment
").addClass("show-reply-form").click(function() { - markPostAsKnown(getPostElement(this)); replyElement = $("#sone .post#" + postId + " .create-reply"); replyElement.removeClass("hidden"); replyElement.removeClass("light"); @@ -606,7 +605,6 @@ function ajaxifyPost(postElement) { if (success) { $(inputField).val(""); loadNewReply(replyId, soneId, postId); - markPostAsKnown(getPostElement(inputField)); $("#sone .post#" + postId + " .create-reply").addClass("hidden"); $("#sone .post#" + postId + " .create-reply .sender").hide(); $("#sone .post#" + postId + " .create-reply .select-sender").show(); @@ -630,12 +628,10 @@ function ajaxifyPost(postElement) { /* convert all “like” buttons to javascript functions. */ $(postElement).find(".like-post").submit(function() { likePost(getPostId(this)); - markPostAsKnown(getPostElement(this)); return false; }); $(postElement).find(".unlike-post").submit(function() { unlikePost(getPostId(this)); - markPostAsKnown(getPostElement(this)); return false; }); @@ -698,12 +694,10 @@ function ajaxifyPost(postElement) { function ajaxifyReply(replyElement) { $(replyElement).find(".like-reply").submit(function() { likeReply(getReplyId(this)); - markPostAsKnown(getPostElement(this)); return false; }); $(replyElement).find(".unlike-reply").submit(function() { unlikeReply(getReplyId(this)); - markPostAsKnown(getPostElement(this)); return false; }); (function(replyElement) { @@ -728,11 +722,6 @@ function ajaxifyReply(replyElement) { untrustSone(getReplyAuthor(this)); return false; }); - - /* mark post and all replies as known on click. */ - $(replyElement).click(function() { - markPostAsKnown(getPostElement(this)); - }); } /**