fix reply mode switching
This commit is contained in:
parent
0df39c402a
commit
0b32a3b65d
@ -552,6 +552,11 @@ quickReply = (e) ->
|
|||||||
m clone,
|
m clone,
|
||||||
listener: ['submit', formSubmit]
|
listener: ['submit', formSubmit]
|
||||||
target: 'iframe'
|
target: 'iframe'
|
||||||
|
if getConfig 'Keyboard Actions'
|
||||||
|
inputs = $$ 'input[type=text], textarea', clone
|
||||||
|
for input in inputs
|
||||||
|
input.addEventListener 'focus', keyActRem, true
|
||||||
|
input.addEventListener 'blur', keyActAdd, true
|
||||||
if not g.REPLY
|
if not g.REPLY
|
||||||
#figure out which thread we're replying to
|
#figure out which thread we're replying to
|
||||||
xpath = 'preceding::span[@class="postername"][1]/preceding::input[1]'
|
xpath = 'preceding::span[@class="postername"][1]/preceding::input[1]'
|
||||||
@ -560,11 +565,6 @@ quickReply = (e) ->
|
|||||||
name: 'resto'
|
name: 'resto'
|
||||||
value: x(xpath, this).name
|
value: x(xpath, this).name
|
||||||
addTo clone, input
|
addTo clone, input
|
||||||
if getConfig 'Keyboard Actions'
|
|
||||||
inputs = $$ 'input[type=text], textarea', clone
|
|
||||||
for input in inputs
|
|
||||||
input.addEventListener 'focus', keyActRem, true
|
|
||||||
input.addEventListener 'blur', keyActAdd, true
|
|
||||||
else if getConfig 'Persistent QR'
|
else if getConfig 'Persistent QR'
|
||||||
submit = $ 'input[type=submit]', clone
|
submit = $ 'input[type=submit]', clone
|
||||||
auto = n 'label',
|
auto = n 'label',
|
||||||
|
|||||||
18
4chan_x.js
18
4chan_x.js
@ -714,6 +714,15 @@
|
|||||||
listener: ['submit', formSubmit],
|
listener: ['submit', formSubmit],
|
||||||
target: 'iframe'
|
target: 'iframe'
|
||||||
});
|
});
|
||||||
|
if (getConfig('Keyboard Actions')) {
|
||||||
|
inputs = $$('input[type=text], textarea', clone);
|
||||||
|
_ref = inputs;
|
||||||
|
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
|
||||||
|
input = _ref[_i];
|
||||||
|
input.addEventListener('focus', keyActRem, true);
|
||||||
|
input.addEventListener('blur', keyActAdd, true);
|
||||||
|
}
|
||||||
|
}
|
||||||
if (!g.REPLY) {
|
if (!g.REPLY) {
|
||||||
xpath = 'preceding::span[@class="postername"][1]/preceding::input[1]';
|
xpath = 'preceding::span[@class="postername"][1]/preceding::input[1]';
|
||||||
input = n('input', {
|
input = n('input', {
|
||||||
@ -722,15 +731,6 @@
|
|||||||
value: x(xpath, this).name
|
value: x(xpath, this).name
|
||||||
});
|
});
|
||||||
addTo(clone, input);
|
addTo(clone, input);
|
||||||
if (getConfig('Keyboard Actions')) {
|
|
||||||
inputs = $$('input[type=text], textarea', clone);
|
|
||||||
_ref = inputs;
|
|
||||||
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
|
|
||||||
input = _ref[_i];
|
|
||||||
input.addEventListener('focus', keyActRem, true);
|
|
||||||
input.addEventListener('blur', keyActAdd, true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else if (getConfig('Persistent QR')) {
|
} else if (getConfig('Persistent QR')) {
|
||||||
submit = $('input[type=submit]', clone);
|
submit = $('input[type=submit]', clone);
|
||||||
auto = n('label', {
|
auto = n('label', {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user