From 4ef95615207e6adb8f785495837a27674f2d5ed1 Mon Sep 17 00:00:00 2001 From: James Campos Date: Sat, 6 Aug 2011 14:04:23 -0700 Subject: [PATCH] move qr.persist into main --- 4chan_x.user.js | 11 ++++------- script.coffee | 9 ++++----- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/4chan_x.user.js b/4chan_x.user.js index 757ff3d03..1defcf307 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -1352,12 +1352,6 @@ quote = $('a.quotejs:not(:first-child)', root); return $.bind(quote, 'click', qr.cb.quote); }, - persist: function() { - qr.dialog(); - if (conf['Auto Hide QR']) { - return $('#autohide', qr.el).checked = true; - } - }, push: function() { this.nextSibling.textContent = qr.captcha.push({ challenge: $('#recaptcha_challenge_field', qr.el).value, @@ -2808,7 +2802,10 @@ imgPreloading.init(); } if (conf['Quick Reply'] && conf['Persistent QR'] && canPost) { - qr.persist(); + qr.dialog(); + if (conf['Auto Hide QR']) { + $('#autohide', qr.el).checked = true; + } } if (conf['Post in Title']) { titlePost.init(); diff --git a/script.coffee b/script.coffee index f91c2f1c4..b5b0a4294 100644 --- a/script.coffee +++ b/script.coffee @@ -970,6 +970,7 @@ qr = # error handling # persistent captcha # code review + # rm Recaptcha init: -> g.callbacks.push qr.node $.bind window, 'message', qr.message @@ -1094,10 +1095,6 @@ qr = quote = $ 'a.quotejs:not(:first-child)', root $.bind quote, 'click', qr.cb.quote - persist: -> - qr.dialog() - $('#autohide', qr.el).checked = true if conf['Auto Hide QR'] - push: -> @nextSibling.textContent = qr.captcha.push challenge: $('#recaptcha_challenge_field', qr.el).value @@ -2215,7 +2212,9 @@ main = imgPreloading.init() if conf['Quick Reply'] and conf['Persistent QR'] and canPost - qr.persist() + qr.dialog() + if conf['Auto Hide QR'] + $('#autohide', qr.el).checked = true if conf['Post in Title'] titlePost.init()