Skip to content

Commit

Permalink
merge
Browse files Browse the repository at this point in the history
  • Loading branch information
davidhellsing committed Aug 25, 2012
2 parents 976ce7f + ce7e5f0 commit 8b680fb
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 18 deletions.
1 change: 1 addition & 0 deletions docs/references/changelog.rst
Expand Up @@ -4,6 +4,7 @@ Changelog

1.2.9
-----
* Fixed an IE8 bug with initial inherited opacity for images
* Added fullscreen functionality from within an iframe gallery, assuming that the iframe and parent window protocol, host and ports match.

1.2.8
Expand Down
43 changes: 25 additions & 18 deletions src/galleria.js
Expand Up @@ -911,8 +911,9 @@ var undef,
$loader.remove();

// If failed, tell the dev to download the latest theme
Galleria.raise( 'Theme CSS could not load after 20 sec. Please download the latest theme at http://galleria.io/customer/', true );

Galleria.raise( 'Theme CSS could not load after 20 sec. ' + Galleria.QUIRK ?
'Your browser is in Quirks Mode, please add a correct doctype.' :
'Please download the latest theme at http://galleria.io/customer/.', true );
},
timeout: 20000
});
Expand Down Expand Up @@ -997,7 +998,7 @@ var undef,
$(params.next).css({
opacity: 0,
left: 0
}).show();
});
Utils.animate(params.next, {
opacity: 1
},{
Expand Down Expand Up @@ -1595,18 +1596,17 @@ Galleria = function() {
fullscreen.scrolled = $win.scrollTop();
window.scrollTo(0, 0);

var enter = function() {
if ( self._options.trueFullscreen && _nativeFullscreen.support ) {
_nativeFullscreen.enter( self, callback );
} else {
fullscreen._enter( callback );
}
};

var version = NAV.match(/version\/([0-9.]{3,5})/);
var version = NAV.match( /version\/([0-9.]{3,5})/ ),
enter = function() {
if ( self._options.trueFullscreen && _nativeFullscreen.support ) {
_nativeFullscreen.enter( self, callback );
} else {
fullscreen._enter( callback );
}
};

// Safari 6 work around
if ( Galleria.SAFARI && version && version.length && version[1] && parseFloat( version[1] ) >= 6 ) {
if ( Galleria.SAFARI && version && parseFloat( version[1] ) >= 6 ) {
window.setTimeout( enter, 1 );
} else {
enter();
Expand Down Expand Up @@ -1658,7 +1658,9 @@ Galleria = function() {

if ( IFRAME && fullscreen.iframe ) {
fullscreen.iframe.scrolled = $( window.parent ).scrollTop();
window.parent.scrollTo(0, 0);
}

// begin styleforce
Utils.forceStyles(self.get('container'), {
position: 'fixed',
Expand Down Expand Up @@ -2492,6 +2494,11 @@ Galleria.prototype = {
// hide all content
$( this._target ).children().hide();

// Warn for quirks mode
if ( Galleria.QUIRK ) {
Galleria.raise('Your page is in Quirks mode, Galleria may not render correctly. Please validate your HTML and add a correct doctype.');
}

// now we just have to wait for the theme...
if ( typeof Galleria.theme === 'object' ) {
this._init();
Expand Down Expand Up @@ -2546,11 +2553,6 @@ Galleria.prototype = {
// bind the gallery to run when data is ready
this.bind( Galleria.DATA, function() {

// Warn for quirks mode
if ( Galleria.QUIRK ) {
Galleria.raise('Your page is in Quirks mode, Galleria may not render correctly. Please validate your HTML.');
}

// save the new data
this._original.data = this._data;

Expand Down Expand Up @@ -5643,6 +5645,11 @@ Galleria.Picture.prototype = {

this.image = new Image();

// IE8 opacity inherit bug
if ( Galleria.IE8 ) {
$( this.image ).css( 'filter', 'inherit' );
}

var i = 0,
reload = false,
resort = false,
Expand Down

0 comments on commit 8b680fb

Please sign in to comment.