update sequences dialog

This commit is contained in:
rolux 2012-06-16 14:21:32 +00:00
parent 982cafe1fb
commit c540f61f3d

View file

@ -209,7 +209,13 @@ pandora.ui.sequencesDialog = function() {
position: item.position position: item.position
}, function(result) { }, function(result) {
// result.data: {hash, id, in, out} // result.data: {hash, id, in, out}
Ox.print('RD:::', result.data) if (Ox.isEmpty(result.data)) {
result.data['in'] = item.position;
result.data.out = item.position + 1 / fps;
result.data.id = item.id + '/'
+ Ox.formatNumber(result.data['in'], 3) + '-'
+ Ox.formatNumber(result.data.out, 3)
}
sequence = Ox.extend({}, item, result.data); sequence = Ox.extend({}, item, result.data);
$clipButtons[sequence['in'] > 0 ? 'enableButton' : 'disableButton']('previous'); $clipButtons[sequence['in'] > 0 ? 'enableButton' : 'disableButton']('previous');
$clipButtons[sequence.out < item.duration ? 'enableButton' : 'disableButton']('next'); $clipButtons[sequence.out < item.duration ? 'enableButton' : 'disableButton']('next');
@ -238,6 +244,7 @@ pandora.ui.sequencesDialog = function() {
}); });
$innerPanel.replaceElement(0, $item); $innerPanel.replaceElement(0, $item);
} }
if (sequence.hash) {
$list = Ox.IconList({ $list = Ox.IconList({
fixedRatio: fixedRatio, fixedRatio: fixedRatio,
item: getItem, item: getItem,
@ -272,14 +279,13 @@ pandora.ui.sequencesDialog = function() {
$dialog[ $dialog[
data.ids.length ? 'enableButton' : 'disableButton' data.ids.length ? 'enableButton' : 'disableButton'
]('open'); ]('open');
},
pandora_sequencesort: function(data) {
Ox.print('SEQUENCESORT:', data)
$list.options({sort: data.value});
} }
}); });
} else {
$list = Ox.Element();
$status.html('0 Clips');
}
$innerPanel.replaceElement(1, $list); $innerPanel.replaceElement(1, $list);
Ox.print('SEQUENCE::', sequence)
$image.attr({src: getImageURL(sequence.hash)}); $image.attr({src: getImageURL(sequence.hash)});
}); });
}); });