only load layers for video/timeline view
This commit is contained in:
parent
34eedfd6e5
commit
c0bb1da718
1 changed files with 12 additions and 14 deletions
|
@ -102,10 +102,10 @@ pandora.ui.item = function() {
|
|||
);
|
||||
|
||||
} else if (pandora.user.ui.itemView == 'video') {
|
||||
pandora.api.get({id: pandora.user.ui.item, keys: ['layers']}, function(r) {
|
||||
// fixme: duplicated
|
||||
var layers = [],
|
||||
video = {};
|
||||
pandora.api.get({id: pandora.user.ui.item, keys: ['layers']}, function(r) {
|
||||
pandora.site.layers.forEach(function(layer, i) {
|
||||
layers[i] = Ox.extend({}, layer, {items: r.data.layers[layer.id]});
|
||||
});
|
||||
|
@ -169,9 +169,9 @@ pandora.ui.item = function() {
|
|||
});
|
||||
|
||||
} else if (pandora.user.ui.itemView == 'timeline') {
|
||||
pandora.api.get({id: pandora.user.ui.item, keys: ['layers']}, function(r) {
|
||||
var layers = [],
|
||||
video = {};
|
||||
pandora.api.get({id: pandora.user.ui.item, keys: ['layers']}, function(r) {
|
||||
pandora.site.layers.forEach(function(layer) {
|
||||
layers.push(Ox.extend({items: r.data.layers[layer.id]}, layer));
|
||||
});
|
||||
|
@ -272,7 +272,6 @@ pandora.ui.item = function() {
|
|||
height: data.size
|
||||
});
|
||||
});
|
||||
});
|
||||
/*
|
||||
pandora.$ui.rightPanel.bindEvent('resize', function(data) {
|
||||
Ox.print('... rightPanel resize', data, pandora.$ui.timelinePanel.size(1))
|
||||
|
@ -281,8 +280,7 @@ pandora.ui.item = function() {
|
|||
});
|
||||
});
|
||||
*/
|
||||
|
||||
|
||||
});
|
||||
} else if (pandora.user.ui.itemView == 'map') {
|
||||
pandora.$ui.contentPanel.replaceElement(1, pandora.ui.navigationView('map', result.data.videoRatio));
|
||||
|
||||
|
|
Loading…
Reference in a new issue