- $('.threaded-notices').each(function() {
- var list = $(this);
- var notice = list.closest('.notice');
- SN.U.NoticeInlineReplyPlaceholder(notice);
- });
- $('.replyform').live('submit', function(event) {
- //SN.U.FormXHR($(this));
- var form = $(this);
- $.ajax({
- type: 'POST',
- dataType: 'xml',
- url: SN.U.RewriteAjaxAction(form.attr('action')),
- data: form.serialize() + '&ajax=1',
- beforeSend: function(xhr) {
- form
- .addClass(SN.C.S.Processing)
- .find('.submit')
- .addClass(SN.C.S.Disabled)
- .attr(SN.C.S.Disabled, SN.C.S.Disabled)
- .end()
- .find('textarea')
- .addClass(SN.C.S.Disabled)
- .attr(SN.C.S.Disabled, SN.C.S.Disabled);
- },
- error: function (xhr, textStatus, errorThrown) {
- alert(errorThrown || textStatus);
- },
- success: function(data, textStatus) {
- if (typeof($('form', data)[0]) != 'undefined') {
- form_new = document._importNode($('form', data)[0], true);
- form.replaceWith(form_new);
- }
- else {
- form.replaceWith(document._importNode($('p', data)[0], true));
- }
- }
+ $('li.notice-reply-placeholder input')
+ .live('focus', function() {
+ var notice = $(this).closest('li.notice');
+ SN.U.NoticeInlineReplyTrigger(notice);
+ return false;