2011-11-30 14:32:12 +00:00
|
|
|
Ox.load('UI', function() {
|
|
|
|
|
|
|
|
var $arrayInput = Ox.ArrayInput({
|
|
|
|
label: 'ArrayInput',
|
|
|
|
max: 3,
|
|
|
|
value: ['foo', 'bar']
|
|
|
|
})
|
|
|
|
.css({margin: '16px'})
|
|
|
|
.appendTo(Ox.$body);
|
|
|
|
|
2011-12-21 13:42:47 +00:00
|
|
|
Ox.Button({
|
|
|
|
title: 'Value'
|
|
|
|
})
|
|
|
|
.css({marginLeft: '16px'})
|
|
|
|
.bindEvent({
|
|
|
|
click: function() {
|
|
|
|
Ox.print($arrayInput.options('value'));
|
|
|
|
}
|
|
|
|
})
|
|
|
|
.appendTo(Ox.$body)
|
|
|
|
|
2011-11-30 14:32:12 +00:00
|
|
|
Ox.Button({
|
|
|
|
title: 'Reset'
|
|
|
|
})
|
|
|
|
.css({marginLeft: '16px'})
|
|
|
|
.bindEvent({
|
|
|
|
click: function() {
|
2011-12-21 15:33:52 +00:00
|
|
|
$arrayInput.value(['foo', 'bar']);
|
2011-11-30 14:32:12 +00:00
|
|
|
}
|
|
|
|
})
|
|
|
|
.appendTo(Ox.$body)
|
|
|
|
|
|
|
|
});
|