});
/* mark everything as known on click. */
- $(postElement).click(function(event) {
- if ($(event.target).hasClass("click-to-show")) {
- return false;
- }
- markPostAsKnown(this);
- });
+ (function(postElement) {
+ $(postElement).click(function(event) {
+ if ($(event.target).hasClass("click-to-show")) {
+ return false;
+ }
+ markPostAsKnown(postElement, false);
+ });
+ })(postElement);
/* hide reply input field. */
$(postElement).find(".create-reply").addClass("hidden");
}
$(".click-to-show", postElement).removeClass("new");
});
- markReplyAsKnown($(postElements).find(".reply"));
+ markReplyAsKnown($(postElements).find(".reply"), true);
}
function markReplyAsKnown(replyElements, skipRequest) {