Loading ...
Sorry, an error occurred while loading the content.

35388Re: [ydn-javascript] Control of Easing Effects

Expand Messages
  • Frank Dietrich
    Aug 1, 2008
    • 0 Attachment
      >...I'd like to change the overshoot on backIn and the number of bounces on
      >bounceOut, but
      >can't seem to do it without overriding the methods, which seems inelegant.
      >


      You can define Your own easing methods. the Anim receives a parameter like
      YAHOO.util.Easing.easeOut

      But You could create Your own easing-object and pass this instead.
      Download the YAHOO js files and have a look in the non "-min" versions.

      You should be able to do

      var ddTech = new Object();

      ddTech.Easing ={
      easeInWithMyKindOfBounce: function(t, b, c, d) {
      return (t==0) ? b : c * Math.pow(.......
      },
      superEasyEasing: function(t, b, c, d) {
      return bla....
      }
      };


      then You should be able to call the Anim-instance with

      easing: ddTech.easeWithMyKindOfBounce


      HTH

      Frank
    • Show all 5 messages in this topic