From a3c32a1af6eae4b509a465b569fb8542fb227f1c Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Mon, 19 Sep 2011 20:30:29 +0200 Subject: [PATCH 1/3] fix qr, god damn aerosmith --- 4chan_x.user.js | 2 +- changelog | 6 +++++- script.coffee | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/4chan_x.user.js b/4chan_x.user.js index d96ebf0b8..0f8ce830c 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -2994,7 +2994,7 @@ var data, origin; origin = e.origin, data = e.data; if (origin === 'http://sys.4chan.org') { - return qr.message(data); + return qr.message(e); } }, css: '\ diff --git a/changelog b/changelog index ab7a0519e..f7f7df4d7 100644 --- a/changelog +++ b/changelog @@ -1,6 +1,10 @@ master -2.19.4 +2.20.1 +- mayhem + fix regression: qr not preventing errors + +2.20.0 - mayhem do not display inlined quotes within the quote preview fix cross threads quotes in expanded threads or inlined cross quotes diff --git a/script.coffee b/script.coffee index 990e30bfa..002893529 100644 --- a/script.coffee +++ b/script.coffee @@ -2347,7 +2347,7 @@ Main = message: (e) -> {origin, data} = e if origin is 'http://sys.4chan.org' - qr.message data + qr.message e css: ' /* dialog styling */ From 5e6bc5e34b0ad789e7cdea7e181ff49be6c6df39 Mon Sep 17 00:00:00 2001 From: James Campos Date: Mon, 19 Sep 2011 12:07:17 -0700 Subject: [PATCH 2/3] superior --- 4chan_x.user.js | 7 +++---- script.coffee | 5 ++--- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/4chan_x.user.js b/4chan_x.user.js index 0f8ce830c..77ecc4f66 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -1360,11 +1360,10 @@ $.bind($('#dummy', qr.el), 'keydown', qr.captchaKeydown); return $.add(d.body, qr.el); }, - message: function(e) { - var data, duration, fileCount; + message: function(data) { + var duration, fileCount; $('iframe[name=iframe]').src = 'about:blank'; fileCount = $('#files', qr.el).childElementCount; - data = e.data; if (data) { data = JSON.parse(data); $.extend($('#error', qr.el), data); @@ -2994,7 +2993,7 @@ var data, origin; origin = e.origin, data = e.data; if (origin === 'http://sys.4chan.org') { - return qr.message(e); + return qr.message(data); } }, css: '\ diff --git a/script.coffee b/script.coffee index 002893529..18507c931 100644 --- a/script.coffee +++ b/script.coffee @@ -1079,11 +1079,10 @@ qr = $.add d.body, qr.el - message: (e) -> + message: (data) -> $('iframe[name=iframe]').src = 'about:blank' fileCount = $('#files', qr.el).childElementCount - {data} = e if data # error message data = JSON.parse data $.extend $('#error', qr.el), data @@ -2347,7 +2346,7 @@ Main = message: (e) -> {origin, data} = e if origin is 'http://sys.4chan.org' - qr.message e + qr.message data css: ' /* dialog styling */ From 5cd6a6c8610de1ebefe4e595578ed35bb9e2a49c Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Tue, 20 Sep 2011 16:02:48 +0200 Subject: [PATCH 3/3] Stay classy. --- 4chan_x.user.js | 2 +- script.coffee | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/4chan_x.user.js b/4chan_x.user.js index 77ecc4f66..0e48c1f4f 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -1114,7 +1114,7 @@ var arr, checked, description, dialog, hiddenNum, hiddenThreads, html, input, key, li, main, obj, overlay, ul, _i, _len, _ref, _ref2; hiddenThreads = $.get("hiddenThreads/" + g.BOARD + "/", {}); hiddenNum = Object.keys(g.hiddenReplies).length + Object.keys(hiddenThreads).length; - html = "
| | |

    Backlink formatting
  • :
    Time formatting
  • :
  • Supported format specifiers:
  • Day: %a, %A, %d, %e
  • Month: %m, %b, %B
  • Year: %y
  • Hour: %k, %H, %l (lowercase L), %I (uppercase i), %p, %P
  • Minutes: %M
ActionsKeybinds
Close Options or QR
Quick spoiler
Open QR with post number inserted
Open QR without post number inserted
Submit post
Select next reply
Select previous reply
See next thread
See previous thread
Jump to the next page
Jump to the previous page
Jump to page 0
Open thread in current tab
Open thread in new tab
Expand thread
Watch thread
Hide thread
Expand selected image
Expand all images
Update now
Reset the unread count to 0
"; + html = "
| | |

    Backlink formatting
  • :
    Time formatting
  • :
  • Supported format specifiers:
  • Day: %a, %A, %d, %e
  • Month: %m, %b, %B
  • Year: %y
  • Hour: %k, %H, %l (lowercase L), %I (uppercase i), %p, %P
  • Minutes: %M
ActionsKeybinds
Close Options or QR
Quick spoiler
Open QR with post number inserted
Open QR without post number inserted
Submit post
Select next reply
Select previous reply
See next thread
See previous thread
Jump to the next page
Jump to the previous page
Jump to page 0
Open thread in current tab
Open thread in new tab
Expand thread
Watch thread
Hide thread
Expand selected image
Expand all images
Update now
Reset the unread count to 0
"; dialog = $.el('div', { id: 'options', innerHTML: html diff --git a/script.coffee b/script.coffee index 18507c931..e7f12dd9e 100644 --- a/script.coffee +++ b/script.coffee @@ -796,13 +796,13 @@ options =
- | | | + | | |