@ -276,21 +276,20 @@ if(typeof VMM != 'undefined') {
} ,
} ,
prop : function ( element , aName , value ) {
prop : function ( element , aName , value ) {
if ( typeof jQuery == 'undefined' || ! /[1-9]\.[3-9].[1-9]/ . test ( jQuery . fn . jquery ) ) {
if ( typeof jQuery == 'undefined' || ! ( 'prop' in jQuery . fn ) ) {
VMM . Lib . attribute ( element , aName , value ) ;
return VMM . Lib . attribute ( element , aName , value ) ;
} else if ( typeof value != 'undefined' ) {
return jQuery ( element ) . prop ( aName , value ) ;
} else {
} else {
jQuery ( element ) . prop ( aName , value ) ;
return jQuery ( element ) . prop ( aName ) ;
}
}
} ,
} ,
attribute : function ( element , aName , value ) {
attribute : function ( element , aName , value ) {
if ( typeof ( jQuery ) != 'undefined' ) {
if ( value != null && value != "" ) {
if ( typeof ( value ) != 'undefined' && value != null && value != "" ) {
if ( typeof ( jQuery ) != 'undefined' ) {
return jQuery ( element ) . attr ( aName , value ) ;
jQuery ( element ) . attr ( aName , value ) ;
}
} else {
} else {
if ( typeof ( jQuery ) != 'undefined' ) {
return jQuery ( element ) . attr ( aName ) ;
return jQuery ( element ) . attr ( aName ) ;
}
}
}
}
@ -422,8 +421,9 @@ if(typeof VMM != 'undefined') {
}
}
} ,
} ,
// TODO: Consider removing this as it's referenced by one commented line
delay _animate : function ( delay , element , duration , ease , att , callback _function ) {
delay _animate : function ( delay , element , duration , ease , att , callback _function ) {
if ( VMM . Browser . device == "mobile" || VMM . Browser . device == "tablet" ) {
if ( VMM . Browser . features . css . transitions && ! ( 'scrollTop' in _att ) ) {
var _tdd = Math . round ( ( duration / 1500 ) * 10 ) / 10 ,
var _tdd = Math . round ( ( duration / 1500 ) * 10 ) / 10 ,
_ _duration = _tdd + 's' ;
_ _duration = _tdd + 's' ;
@ -446,7 +446,7 @@ if(typeof VMM != 'undefined') {
var _ease = "easein" ,
var _ease = "easein" ,
_que = false ,
_que = false ,
_duration = 1000 ,
_duration = 1000 ,
_att = { } ;
_att ;
if ( duration != null ) {
if ( duration != null ) {
if ( duration < 1 ) {
if ( duration < 1 ) {
@ -467,20 +467,18 @@ if(typeof VMM != 'undefined') {
if ( att != null ) {
if ( att != null ) {
_att = att
_att = att ;
} else {
} else {
_att = { opacity : 0 }
_att = { opacity : 0 } ;
}
}
if ( VMM . Browser . features . css . transitions && ! ( 'scrollTop' in _att ) ) {
if ( VMM . Browser . device == "mobile" || VMM . Browser . device == "tablet" ) {
var _tdd = Math . round ( ( _duration / 1500 ) * 10 ) / 10 ,
var _tdd = Math . round ( ( _duration / 1500 ) * 10 ) / 10 ,
_ _duration = _tdd + 's' ;
_ _duration = _tdd + 's' ;
_ease = " cubic-bezier(0.33, 0.66, 0.66, 1)" ;
_ease = " cubic-bezier(0.33, 0.66, 0.66, 1)" ;
//_ease = " ease-in-out";
//_ease = " ease-in-out";
for ( x in _att ) {
for ( var x in _att ) {
if ( Object . prototype . hasOwnProperty . call ( _att , x ) ) {
if ( Object . prototype . hasOwnProperty . call ( _att , x ) ) {
trace ( x + " to " + _att [ x ] ) ;
trace ( x + " to " + _att [ x ] ) ;
VMM . Lib . css ( element , '-webkit-transition' , x + ' ' + _ _duration + _ease ) ;
VMM . Lib . css ( element , '-webkit-transition' , x + ' ' + _ _duration + _ease ) ;