make small timeline work in player view

This commit is contained in:
rolux 2011-01-18 04:07:40 +00:00
parent 3885b3967a
commit 5b56748e32

View file

@ -979,6 +979,7 @@ var pandora = new Ox.App({
height: app.$ui.contentPanel.size(1), height: app.$ui.contentPanel.size(1),
showAnnotations: app.user.ui.showAnnotations, showAnnotations: app.user.ui.showAnnotations,
showControls: app.user.ui.showControls, showControls: app.user.ui.showControls,
subtitles: subtitles,
videoHeight: video.height, videoHeight: video.height,
videoId: app.user.ui.item, videoId: app.user.ui.item,
videoWidth: video.width, videoWidth: video.width,
@ -989,7 +990,9 @@ var pandora = new Ox.App({
change: function(event, data) { change: function(event, data) {
// showAnnotations, showControls, videoSize // showAnnotations, showControls, videoSize
UI.set(data); UI.set(data);
} },
enterfullscreen: enterFullscreen,
exitfullscreen: exitFullscreen
}))/*.bindEvent({ }))/*.bindEvent({
resize: function(event, data) { resize: function(event, data) {
app.$ui.player.options({ app.$ui.player.options({
@ -1053,6 +1056,7 @@ var pandora = new Ox.App({
}); });
*/ */
} }
app.$ui.total.html(result.data.item.title + ' (' + result.data.item.director.join(', ') + ')')
}); });
} }
that.display = function() { that.display = function() {
@ -3019,6 +3023,30 @@ var pandora = new Ox.App({
callback(value); callback(value);
} }
function enterFullscreen() {
app.$ui.appPanel.size(0, 0);
app.user.ui.showSidebar && app.$ui.mainPanel.size(0, 0);
app.$ui.rightPanel.size(0, 0).size(2, 0);
!app.user.ui.showMovies && app.$ui.contentPanel.css({
top: (-112 - app.ui.scrollbarSize) + 'px' // fixme: rightPanel.size(0, 0) doesn't preserve negative top of browser
});
app.user.ui.showMovies && app.$ui.contentPanel.size(0, 0);
app.$ui.player.options({
height: app.$document.height() - 2,
width: app.$document.width() - 2
})
}
function exitFullscreen() {
app.$ui.appPanel.size(0, 20);
app.user.ui.showSidebar && app.$ui.mainPanel.size(0, app.user.ui.sidebarSize);
app.$ui.rightPanel.size(0, 24).size(2, 16);
!app.user.ui.showMovies && app.$ui.contentPanel.css({
top: 24 + (-112 - app.ui.scrollbarSize) + 'px' // fixme: rightPanel.size(0, 0) doesn't preserve negative top of browser
});
app.user.ui.showMovies && app.$ui.contentPanel.size(0, 112 + app.ui.scrollbarSize);
}
function getAlignment(key) { // fixme: make static function getAlignment(key) { // fixme: make static
return ['person', 'string', 'text', 'title'].indexOf( return ['person', 'string', 'text', 'title'].indexOf(
Ox.getObjectById(app.config.sortKeys, key).type Ox.getObjectById(app.config.sortKeys, key).type