This project is archived and is in readonly mode.

#953 ✓wontfix
Chi Shang Cheng

Tween of background-position using keyword unit fails (Webkit)

Reported by Chi Shang Cheng | July 27th, 2010 @ 03:42 PM

When you start a Tween of background-position and you don't use numerical values, e.g. 'center top', Safari will not be able to animate this tween. Both IE and FF will render this fine.


myDiv.setStyle('background-position', 'center 0px');
var myTween = new Fx.Tween(myDiv, {
  duration: 'long',
  property: 'background-position',
  onComplete: function() {

// Safari will return '50% 0px' when it should show '50% 20px', starting value is not changed

} }); myTween.start('center 20px');

N.B. You can't use percentage units, because Mootools will turn it into pixel values (e.g. '50%' to '50px').

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Shared Ticket Bins

People watching this ticket