Fix #167. keyup isn't triggered when pasting for example.
This commit is contained in:
parent
edaa5b42f4
commit
a0b8006250
@ -1562,7 +1562,7 @@
|
||||
}
|
||||
},
|
||||
dialog: function() {
|
||||
var e, fileInput, input, mimeTypes, spoiler, thread, threads, _i, _j, _len, _len2, _ref, _ref2;
|
||||
var e, fileInput, input, mimeTypes, name, spoiler, thread, threads, _i, _j, _len, _len2, _ref, _ref2;
|
||||
qr.el = ui.dialog('qr', 'top:0;right:0;', '\
|
||||
<div class=move>\
|
||||
Quick Reply <input type=checkbox id=autohide title=Auto-hide>\
|
||||
@ -1629,8 +1629,12 @@
|
||||
new qr.reply().select();
|
||||
_ref2 = ['name', 'email', 'sub', 'com'];
|
||||
for (_j = 0, _len2 = _ref2.length; _j < _len2; _j++) {
|
||||
input = _ref2[_j];
|
||||
$.on($("[name=" + input + "]", qr.el), 'keyup', function() {
|
||||
name = _ref2[_j];
|
||||
input = $("[name=" + input + "]", qr.el);
|
||||
$.on(input, 'keyup', function() {
|
||||
return qr.selected[this.name] = this.value;
|
||||
});
|
||||
$.on(input, 'change', function() {
|
||||
return qr.selected[this.name] = this.value;
|
||||
});
|
||||
}
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
master
|
||||
- Mayhem
|
||||
Fix text inputs not saved correctly in the QR.
|
||||
|
||||
2.25.3
|
||||
- Mayhem
|
||||
|
||||
@ -1201,8 +1201,10 @@ qr =
|
||||
|
||||
new qr.reply().select()
|
||||
# save selected reply's data
|
||||
for input in ['name', 'email', 'sub', 'com']
|
||||
$.on $("[name=#{input}]", qr.el), 'keyup', -> qr.selected[@name] = @value
|
||||
for name in ['name', 'email', 'sub', 'com']
|
||||
input = $ "[name=#{input}]", qr.el
|
||||
$.on input, 'keyup', -> qr.selected[@name] = @value
|
||||
$.on input, 'change', -> qr.selected[@name] = @value
|
||||
# sync between tabs
|
||||
$.sync 'qr.persona', (persona) ->
|
||||
return if qr.replies.length isnt 1
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user