fix bugs in map and video player

This commit is contained in:
rlx 2011-12-23 05:05:41 +00:00
parent 617ad0e5ca
commit 5803633835
2 changed files with 15 additions and 9 deletions

View file

@ -860,11 +860,20 @@ Ox.Map = function(options, self) {
$placeControl.appendTo(self.$map); $placeControl.appendTo(self.$map);
}); });
setTimeout(function() { setTimeout(function() {
var element = self.$map.$element[0].children[0].children[2].children[0]; var $element;
element.style.backgroundImage = '-webkit-linear-gradient(left, rgba(255, 255, 255, 0) 0px, rgba(255, 255, 255, 0.1) 50px)'; try {
element.style.color = 'rgb(192, 192, 192)'; $element = $(self.$map.find('a[href$="terms_maps.html"]').parent()).css({
element.style.textShadow = '1px 1px 0 rgb(64, 64, 64)'; color: 'rgb(192, 192, 192)',
element.children[3].style.color = 'rgb(192, 192, 192)'; textShadow: '1px 1px 0 rgb(64, 64, 64)'
});
['moz', 'o', 'webkit'].forEach(function(browser) {
$element.css({
backgroundImage: '-' + browser
+ '-linear-gradient(left, rgba(255, 255, 255, 0) 0px, rgba(255, 255, 255, 0.1) 50px)',
});
});
$element.children().css({color: 'rgb(192, 192, 192)'});
} catch (e) {}
}, 0) }, 0)
} }
} }

View file

@ -1000,9 +1000,7 @@ Ox.VideoPlayer = function(options, self) {
} }
} }
setSizes(function() { self.options.fullscreen ? setSizes(enterFullscreen) : setSizes();
self.options.fullscreen && enterFullscreen();
});
function censor() { function censor() {
if (self.options.type == 'play') { if (self.options.type == 'play') {
@ -2102,7 +2100,6 @@ Ox.VideoPlayer = function(options, self) {
} }
function toggleFullscreen(from) { function toggleFullscreen(from) {
// FIXME: hiding controls won't work if video begins in fullscreen
var parentOffset, playOnFullscreen; var parentOffset, playOnFullscreen;
self.options.fullscreen = !self.options.fullscreen; self.options.fullscreen = !self.options.fullscreen;
if (!self.options.paused) { if (!self.options.paused) {