-
Notifications
You must be signed in to change notification settings - Fork 2
/
ScrollMTEvent.as
38 lines (30 loc) · 1.53 KB
/
ScrollMTEvent.as
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package
{
import flash.events.Event;
public class ScrollMTEvent extends Event
{
/**This event dispatches to parent. the container scrollers must listen to this to stop their scroll controlling*/
internal static const TRY_TO_SCROLL:String = "TRY_TO_SCROLL" ;
/**The scrollable object taouced to start scroll but the scroll didn't start yet.*/
public static const TOUCHED_TO_SCROLL:String = "TOUCHED_TO_SCROLL" ;
/**This event will dispatch on all scrolled items childs to tell them that they are scrolling*/
public static const YOU_ARE_SCROLLING_FROM_YOUR_PARENT:String = "YOU_ARE_SCROLLING_FROM_YOUR_PARENT";
public static const LOCK_SCROLL_TILL_MOUSE_UP:String = "LOCK_SCROLL_TILL_MOUSE_UP";
/**It will force the scroller to scroll up or down from the command from it's childs*/
public static const SCROLL_THE_SCROLLER:String = "SCROLL_THE_SCROLLER" ;
/**User is dragging but the scroll prosess may not started yet */
public static const LISTEN_TO_SCROLL:String = "LISTEN_TO_SCROLL" ;
public var freeScrollOnTarget_TD:Boolean ;
public var freeScrollOnTarget_LR:Boolean ;
public var dx:Number,
dy:Number;
public function ScrollMTEvent(type:String, bubbles:Boolean=false, cancelable:Boolean=false,FreeScrollOnTarget_TD:Boolean=false,FreeScrollOnTarget_LR:Boolean=false,deltaScrollX:Number=0,deltaScrollY:Number=0)
{
super(type, bubbles, cancelable);
freeScrollOnTarget_LR = FreeScrollOnTarget_LR ;
freeScrollOnTarget_TD = FreeScrollOnTarget_TD ;
dx = deltaScrollX ;
dy = deltaScrollY ;
}
}
}