# MOUSE\_OVER Listener problem

**URL:** <https://forum.kirupa.com/t/mouse-over-listener-problem/267584>\
**Category:** flash\
**Created:** [August 3, 2008, 12:53pm UTC](https://forum.kirupa.com/t/mouse-over-listener-problem/267584 "2008-08-03T12:53:51Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![balajee](https://avatars.discourse-cdn.com/v4/letter/b/ed655f/32.png) [@balajee](https://forum.kirupa.com/u/balajee)\
**Post date:** [August 3, 2008, 12:53pm UTC](https://forum.kirupa.com/t/mouse-over-listener-problem/267584/1 "2008-08-03T12:53:51Z")

</div>

I have problem in MOUSE\_MOVE listener  
the logic is that mouse should hide while hitTestObject and the custom mouse should appear.Problem is mouse is appearing but it is blinking and even i tried  
[COLOR=DarkRed]sinu\_mc.addEventListener(MouseEvent.MOUSE\_OUT,outListener,true);[/COLOR]  
in the above code cur(custom mouse) isn’t blinking but while moving out from hitTestObject custom mouse is appearing sometimes and it’s n’t so accurate and please help me to overcome this.

one more problem i faced  
[COLOR=Navy]cur.x = mouseX;  
cur.y = mouseY;[/COLOR] inside the [COLOR=SeaGreen]overlistener[/COLOR]  
but the position is difference from mouseX and mouseY and how to make synchronize that  
movieclip with mouseX,Y properties.  
[FONT=Arial Black]-----------------------------------  
[COLOR=Red] SOURCE CODE[/COLOR]  
-----------------------------------[/FONT]  
var cur:cursor = new cursor ();//movieclip with linkage id cursor

sinu\_mc.addEventListener(MouseEvent.MOUSE\_MOVE,[COLOR=SeaGreen]overListener[/COLOR]);  
[COLOR=DarkRed]sinu\_mc.addEventListener(MouseEvent.MOUSE\_OUT,outListener);[/COLOR]

function overListener(m:MouseEvent){  
if(sinu\_mc.hitTestPoint(mouseX,mouseY,true)){  
Mouse.hide();  
sinu\_mc.addChild(cur);  
cur.startDrag(true);  
cur.scaleX = cur.scaleY = .5;  
[COLOR=Navy]cur.x = mouseX  
cur.y = mouseY;[/COLOR]  
}  
}

function outListener(m:MouseEvent){  
Mouse.show();  
sinu\_mc.removeChild(cur);  
}
