horizontal scrolling
This commit is contained in:
parent
0c99311b8d
commit
22f5597e6f
@ -1259,20 +1259,20 @@
|
||||
}
|
||||
},
|
||||
attach: function() {
|
||||
var div, file, files;
|
||||
var box, file, files;
|
||||
files = $('#files', QR.qr);
|
||||
div = $.el('div', {
|
||||
box = $.el('span', {
|
||||
innerHTML: "<input type=file name=upfile accept='" + QR.accept + "'><img alt='click here'><a class=x>X</a>"
|
||||
});
|
||||
file = $('input', div);
|
||||
file = $('input', box);
|
||||
$.bind(file, 'change', QR.change);
|
||||
$.bind($('img', div), 'click', function() {
|
||||
$.bind($('img', box), 'click', function() {
|
||||
return this.previousSibling.click();
|
||||
});
|
||||
$.bind($('.x', div), 'click', function() {
|
||||
$.bind($('.x', box), 'click', function() {
|
||||
return $.rm(this.parentNode);
|
||||
});
|
||||
$.add(files, div);
|
||||
$.add(files, box);
|
||||
return file.click();
|
||||
},
|
||||
captchaNode: function(e) {
|
||||
@ -3132,6 +3132,14 @@
|
||||
#qr #captcha {\
|
||||
position: relative;\
|
||||
}\
|
||||
#qr #files {\
|
||||
width: 300px;\
|
||||
white-space: nowrap;\
|
||||
overflow: auto;\
|
||||
}\
|
||||
#qr #files span {\
|
||||
position: relative;\
|
||||
}\
|
||||
#qr #files a {\
|
||||
position: absolute;\
|
||||
left: 0;\
|
||||
|
||||
@ -969,13 +969,13 @@ QR =
|
||||
attach: ->
|
||||
#$('#autopost', QR.qr).checked = true
|
||||
files = $ '#files', QR.qr
|
||||
div = $.el 'div',
|
||||
box = $.el 'span',
|
||||
innerHTML: "<input type=file name=upfile accept='#{QR.accept}'><img alt='click here'><a class=x>X</a>"
|
||||
file = $ 'input', div
|
||||
file = $ 'input', box
|
||||
$.bind file, 'change', QR.change
|
||||
$.bind $('img', div), 'click', -> @previousSibling.click()
|
||||
$.bind $('.x', div), 'click', -> $.rm @parentNode
|
||||
$.add files, div
|
||||
$.bind $('img', box), 'click', -> @previousSibling.click()
|
||||
$.bind $('.x', box), 'click', -> $.rm @parentNode
|
||||
$.add files, box
|
||||
file.click()
|
||||
captchaNode: (e) ->
|
||||
QR.captcha =
|
||||
@ -2449,6 +2449,14 @@ main =
|
||||
#qr #captcha {
|
||||
position: relative;
|
||||
}
|
||||
#qr #files {
|
||||
width: 300px;
|
||||
white-space: nowrap;
|
||||
overflow: auto;
|
||||
}
|
||||
#qr #files span {
|
||||
position: relative;
|
||||
}
|
||||
#qr #files a {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user