embed panel: add reload and resize methods, add event handlers
This commit is contained in:
parent
405080d73c
commit
625793ec76
1 changed files with 20 additions and 8 deletions
|
@ -355,14 +355,26 @@ pandora.ui.embedPanel = function() {
|
||||||
return that;
|
return that;
|
||||||
};
|
};
|
||||||
|
|
||||||
$(window).on({
|
that.reloadPanel = function() {
|
||||||
resize: function() {
|
Ox.print('RELOAD::')
|
||||||
var sizes = getSizes();
|
that.setElement(
|
||||||
$player.options({width: window.innerWidth, height: sizes.videoHeight});
|
pandora.$ui.embedPanel = pandora.ui.embedPanel()
|
||||||
$outerPanel.size(0, sizes.innerHeight);
|
);
|
||||||
options.showTimeline && $timeline.options({width: window.innerWidth - 16});
|
};
|
||||||
options.showAnnotations && $annotations.options({width: window.innerWidth});
|
|
||||||
}
|
that.resizePanel = function() {
|
||||||
|
var sizes = getSizes();
|
||||||
|
$player.options({width: window.innerWidth, height: sizes.videoHeight});
|
||||||
|
$outerPanel.size(0, sizes.innerHeight);
|
||||||
|
options.showTimeline && $timeline.options({width: window.innerWidth - 16});
|
||||||
|
options.showAnnotations && $annotations.options({width: window.innerWidth});
|
||||||
|
};
|
||||||
|
|
||||||
|
that.bindEvent({
|
||||||
|
pandora_item: that.reloadPanel,
|
||||||
|
pandora_itemview: that.reloadPanel,
|
||||||
|
pandora_videopoints: that.reloadPanel,
|
||||||
|
pandora_hash: that.reloadPanel
|
||||||
});
|
});
|
||||||
|
|
||||||
return that;
|
return that;
|
||||||
|
|
Loading…
Reference in a new issue