From 9f68a59acb70b7d3133692acec937d481cb1487c Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Sun, 22 Sep 2013 21:53:06 +0200 Subject: [PATCH] Fix jQuery selectors for locating the reply input field. --- src/main/resources/static/javascript/sone.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/resources/static/javascript/sone.js b/src/main/resources/static/javascript/sone.js index 598c408..6c7f77c 100644 --- a/src/main/resources/static/javascript/sone.js +++ b/src/main/resources/static/javascript/sone.js @@ -75,7 +75,7 @@ function addCommentLink(postId, author, element, insertAfterThisElement) { replyElement.removeClass("hidden"); replyElement.removeClass("light"); (function(replyElement) { - replyElement.find("input.reply-input").blur(function() { + replyElement.find(":input.reply-input").blur(function() { if ($(this).hasClass("default")) { replyElement.addClass("light"); } @@ -83,7 +83,7 @@ function addCommentLink(postId, author, element, insertAfterThisElement) { replyElement.removeClass("light"); }); })(replyElement); - textArea = replyElement.find("input.reply-input").focus().data("textarea"); + textArea = replyElement.find(":input.reply-input").focus().data("textarea"); if (author != getCurrentSoneId()) { textArea.val(textArea.val() + "@sone://" + author + " "); } @@ -813,7 +813,7 @@ function ajaxifyPost(postElement) { /* ajaxify author/post links */ $(".post-status-line .permalink a", postElement).click(function() { if (!$(".create-reply", postElement).hasClass("hidden")) { - textArea = $("input.reply-input", postElement).focus().data("textarea"); + textArea = $(":input.reply-input", postElement).focus().data("textarea"); $(textArea).replaceSelection($(this).attr("href")); } return false; @@ -832,7 +832,7 @@ function ajaxifyPost(postElement) { /* process reply input fields. */ getTranslation("WebInterface.DefaultText.Reply", function(text) { - $(postElement).find("input.reply-input").each(function() { + $(postElement).find(":input.reply-input").each(function() { registerInputTextareaSwap(this, text, "text", false, false); }); }); @@ -935,7 +935,7 @@ function ajaxifyReply(replyElement) { /* ajaxify author links */ $(".reply-status-line .permalink a", replyElement).click(function() { if (!$(".create-reply", getPostElement(replyElement)).hasClass("hidden")) { - textArea = $("input.reply-input", getPostElement(replyElement)).focus().data("textarea"); + textArea = $(":input.reply-input", getPostElement(replyElement)).focus().data("textarea"); $(textArea).replaceSelection($(this).attr("href")); } return false; -- 2.7.4