test with 3d transform disabled...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2013-02-22 18:44:11 +04:00
parent 81d398f0c9
commit f9b536716e

View File

@ -195,9 +195,12 @@ function unanimated(obj, func, time){
var USE_3D_TRANSFORM = false
// NOTE: at this point this works only on the X axis...
function setElementTransform(elem, offset, scale){
elem = $(elem)
var t3d = USE_3D_TRANSFORM ? 'translateZ(0px)' : ''
if(offset == null){
offset = getElementShift(elem)
// number -- only the x coord...
@ -217,7 +220,7 @@ function setElementTransform(elem, offset, scale){
var scale = getElementScale(elem)
}
if(USE_TRANSFORM){
var transform = 'translate('+ offset.left +'px, '+ offset.top +'px) scale('+ scale +') translateZ(0px)'
var transform = 'translate('+ offset.left +'px, '+ offset.top +'px) scale('+ scale +') ' + t3d
elem.css({
'-ms-transform' : transform,
'-webkit-transform' : transform,
@ -231,7 +234,7 @@ function setElementTransform(elem, offset, scale){
top: ''
})
} else {
var transform = 'translate(0px, 0px) scale('+ scale +') translateZ(0px)'
var transform = 'translate(0px, 0px) scale('+ scale +') ' + t3d
elem.css({
// NOTE: this will be wrong during a transition, that's why we
// can pass the pre-calculated offset as an argument...