Jump to content
Search Community

Search the Community

Showing results for tags 'swipe'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • GreenSock Forums
    • GSAP
    • Banner Animation
    • Jobs & Freelance
  • Flash / ActionScript Archive
    • GSAP (Flash)
    • Loading (Flash)
    • TransformManager (Flash)

Categories

There are no results to display.


Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Found 7 results

  1. TrevorRice

    Don't reverse tween in timeline

    Is it possible to target a specific tween in a timeline and not have it go in reverse when the timeline's progress is going from 1 to 0? function createTimeline(progress, ...elems) { let tl = new TimelineMax({ paused: true }); tl.add('beginning') .fromTo(elems[0], 1, { x: '-100%' }, { x: '0%', ease: Power0.easeNone }) .fromTo(elems[1], 1, { y: '100%' }, { y: '0%', ease: Power0.easeNone }, 'beginning') .add('middle') .fromTo(elems[0], 1, { x: '0%' }, { x: '100%', ease: Power0.easeNone, immediateRender: false }) .fromTo(elems[1], 1, { y: '0%' }, { y: '-100%', ease: Power0.easeNone, immediateRender: false }, 'middle') .add('end') .progress(progress); return tl; } I am using a dragging/swiping callback to control the progress of my timelines, but I'd like to, regardless of the direction of the progress, have the tweens associated with elems[1] to always go from y:'100%' -> y:'0%' -> y:'-100%'. Right now, if the progress is going from 1 to 0, the tweens associated with elems[1] go from y:'-100%' -> y:'0%' -> y:'100%', which makes sense, but it's not what I'm looking for. I can make a CodePen if that would help. Thank you! EDIT Heres a CodePen: http://codepen.io/TrevorRice/pen/YGbyvv/?editors=1010
  2. Hello Everyone! I encountered a problem for which I can not find a solution. I would like to make the transition from one slide to another, something very similar to CSS clip. The problem is that I need a diagonal bar to sweep the screen from right to the left, showing the content that lies beneath. Does anyone have any idea on how to achieve that? I have attached a picture that might explain a little bit better what I am trying to do. Any help is very much appreciated!
  3. Hi! Can you give me guides on how to make frames to chance diagonally. It's about a banner animation, and I need the frame to angle swipe (with 1px line) from top left to bottom right, clearing copy from previous frame. The next frame should appear under! Thanks in advance!
  4. JustinLBannister

    Multi-Finger Swipe on Draggable

    Just wanted to know if there was a way to implement two finger or three finger swipe with a draggable element. I haven't come across this in any of the documentation or forums just yet. Thanks.
  5. Hello.. I'm having trouble finding a very basic swipe example.. .. I don't need to drag anything around.. .. I just need to listen to a swipe up or down and call the appropriate function. I've got a little something now based off of some examples, but again.. .. i end up dragging the stage round when I just want to listen for a swipe direction. Any suggestions? Here is my simple code: var DD = Draggable.create($("#stage"), { type:'y', lockAxis:true, onRelease:function() { var dir = this.getDirection("start"); console.log('swipe! onDragStart() ' + dir) if (dir === "up"){ next(); }else if(dir === "down"){ prev(); } } }); ALSO, I tried attaching it to the body, but the only direction that would log was "right". Thanks,
  6. GreenBeak

    BlitMask for swiping gesture

    Hi! First of all, @Jack: thanks a lot for the awesome Greensock framework! Currently I'm building an application that supports swiping. It's has a fairly large resolution. The application itself has a screen size of 1920x1080, but the swipable content is roughly 15000px wide (height being 1080). So I was thinking, since the swiping was not very smooth, that I could use BlitMask to reduce the unneccessary calculations. However, I'm doing something wrong, since the mask itself doesn't seem to work correctly for dragging and swiping gestures. I have the following line in my code ('bm' is defined at the top of the class): this.bm = new BlitMask(this.mc, this.mc.x, this.mc.y, 1920, 1080, true, true, 0, false); However, the BlitMask seems to be an object laying over all the other objects, meaning my EventListeners on the content are not recognized. Is there some workaround for this or am I mistaken here and the error lies somewhere else?
  7. Buzzafett

    iPhone Swipe Menu

    Need help creating an iPhone style menu, similar to Angry Birds or Cut the Rope. It needs to use either Adobe Gesture Events or Greensock ThrowProps. I tried using the ThrowProps example, but I need it to stop on each menu item. The code below uses swipe left/right Gesture Events and TweenLite, but I need help adding an overshoot to the first and last menu item. Maybe by adding an 'if else' statement. import com.greensock.*; import com.greensock.easing.* var offsetX:Number = 440; // Swipe Gesture Multitouch.inputMode = MultitouchInputMode.GESTURE; stage.addEventListener (TransformGestureEvent.GESTURE_SWIPE, swipeHandler); function swipeHandler(event:TransformGestureEvent):void { switch(event.offsetX){ // swipe left case -1: { TweenLite.to(mc, 1, {x:mc.x - offsetX, ease:Expo.easeOut}); break; } // swipe right case 1: { TweenLite.to(mc, 1, {x:mc.x + offsetX, ease:Expo.easeOut}); break; } } } stage.addEventListener(Event.ENTER_FRAME, traceXPosition); function traceXPosition(evt:Event) { trace("movieClip Position: " + mc.x); }
×
×
  • Create New...