selector
This commit is contained in:
parent
34daa5fd2f
commit
698d146c63
@ -1327,15 +1327,12 @@
|
|||||||
return captcha;
|
return captcha;
|
||||||
},
|
},
|
||||||
change: function(e) {
|
change: function(e) {
|
||||||
var a, p;
|
|
||||||
if (this.files[0].size > QR.MAX_FILE_SIZE) {
|
if (this.files[0].size > QR.MAX_FILE_SIZE) {
|
||||||
alert('Error: File too large.');
|
alert('Error: File too large.');
|
||||||
QR.resetFile(this);
|
QR.resetFile(this);
|
||||||
return $('[type=file]', QR.qr).click();
|
return $('[type=file]', QR.qr).click();
|
||||||
} else {
|
} else {
|
||||||
p = this.parentNode;
|
if (this === $('#files div:last-of-type input', QR.qr)) {
|
||||||
a = p.parentNode;
|
|
||||||
if (a.id === 'files' && !p.nextSibling) {
|
|
||||||
return QR.attach();
|
return QR.attach();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1042,9 +1042,7 @@ QR =
|
|||||||
QR.resetFile @
|
QR.resetFile @
|
||||||
$('[type=file]', QR.qr).click()
|
$('[type=file]', QR.qr).click()
|
||||||
else
|
else
|
||||||
p = @parentNode
|
if @ is $('#files div:last-of-type input', QR.qr)
|
||||||
a = p.parentNode
|
|
||||||
if a.id is 'files' and not p.nextSibling
|
|
||||||
QR.attach()
|
QR.attach()
|
||||||
close: ->
|
close: ->
|
||||||
$.rm QR.qr
|
$.rm QR.qr
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user