This commit is contained in:
James Campos 2011-09-03 17:30:37 -07:00
parent 34daa5fd2f
commit 698d146c63
2 changed files with 2 additions and 7 deletions

View File

@ -1327,15 +1327,12 @@
return captcha;
},
change: function(e) {
var a, p;
if (this.files[0].size > QR.MAX_FILE_SIZE) {
alert('Error: File too large.');
QR.resetFile(this);
return $('[type=file]', QR.qr).click();
} else {
p = this.parentNode;
a = p.parentNode;
if (a.id === 'files' && !p.nextSibling) {
if (this === $('#files div:last-of-type input', QR.qr)) {
return QR.attach();
}
}

View File

@ -1042,9 +1042,7 @@ QR =
QR.resetFile @
$('[type=file]', QR.qr).click()
else
p = @parentNode
a = p.parentNode
if a.id is 'files' and not p.nextSibling
if @ is $('#files div:last-of-type input', QR.qr)
QR.attach()
close: ->
$.rm QR.qr