Jump to content

Search In
  • More options...
Find results that contain...
Find results in...


  • Posts

  • Joined

  • Last visited

Joe's Achievements



  1. Joe

    iOS Animation Issue

    Hello, First off, thanks for all the work on this great API. I've looked at many of the past posts on this topic and can't seem to find a remedy for my issue. I'm using a simple move tween with a bounceOut on a fixed position div, which works great on everything but iOS devices. I've tested on an updated iPad 1 (iOS 5.1.1), iPad 2 (mini, iOS 6.1.3), and an iPhone 4 (iOS 6.1.3). This is in both Safari and Chrome (both the most updated versions), and I'm using the most current release of GSAP JS (TweenMax.min.js). Could this be an issue with the way I'm calculating scroll positioning? jQuery(document).ready(function($) { //disables the requestAnimationFrame functionality and causes GSAP to use a simple setTimeout() internally (pretty much like jQuery). TweenLite.ticker.useRAF(false); var winHeight = $(window).height(), socPos = winHeight - $('#socialBox').height(); $('#socialBox').css('top', socPos); $(window).bind('scroll', function(e) { scrollBinder(); }); function scrollBinder() { var winScroll = $(window).scrollTop(), winHeight = $(window).height(), docHeight = $(document).height(), percent = (winScroll / (docHeight - winHeight)), targetDiv = $('#socialBox'), newPos = (winHeight * percent) * (-.65); if (newPos > socPos) { newPos = socPos; } if ($(window).width() > 480) { TweenMax.to(targetDiv, .75, { y : newPos, ease : Bounce.easeOut }); } } });