Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Improved Firefox support

  • Loading branch information...
commit 29e0187d19fa802cac437252217d3e30b28a5d48 1 parent 6c43998
@joelambert authored
View
2  change.log
@@ -4,6 +4,8 @@ Added a new 3D transition called `explode`
Updated `cols` param to `columns` in `blocks` transition
+Made `bars3d` work properly in Firefox
+
1.4.3 (2012/01/10)
------------------
View
8 js/src/flux.transitions.bars3d.js
@@ -64,6 +64,10 @@
this.slider.image1.css3({
'perspective': this.options.perspective,
'perspective-origin': '50% 50%'
+ }).css({
+ '-moz-transform': 'perspective('+this.options.perspective+'px)',
+ '-moz-perspective': 'none',
+ '-moz-transform-style': 'preserve-3d'
});
var _this = this,
@@ -74,6 +78,10 @@
// Get notified when the last transition has completed
bars.last().transitionEnd(function(event){
+ _this.slider.image1.css3({
+ 'transform-style': 'flat'
+ });
+
_this.slider.image2.show();
_this.finished();
View
9 js/src/flux.transitions.explode.js
@@ -33,6 +33,10 @@
this.slider.image1.css3({
'perspective': this.options.perspective,
'perspective-origin': '50% 50%'
+ }).css({
+ '-moz-transform': 'perspective('+this.options.perspective+'px)',
+ '-moz-perspective': 'none',
+ '-moz-transform-style': 'preserve-3d'
});
var _this = this;
@@ -41,6 +45,9 @@
// Get notified when the last transition has completed
this.maxDelayTile.transitionEnd(function(){
+ _this.slider.image1.css3({
+ 'transform-style': 'flat'
+ });
_this.finished();
});
@@ -49,7 +56,7 @@
$(block).css({
'opacity': '0'
}).css3({
- 'transform': flux.browser.translate(0, 0, 700) + " rotate3d("+Math.round(Math.random())+", "+Math.round(Math.random())+", "+Math.round(Math.random())+", 90deg) "
+ 'transform': flux.browser.translate(0, 0, 700) + " rotate3d("+(Math.round(Math.random()*2)-1)+", "+(Math.round(Math.random()*2)-1)+", "+(Math.round(Math.random()*2)-1)+", 90deg) "
});
});
}, 50);
Please sign in to comment.
Something went wrong with that request. Please try again.