# Detecting mouse outside stage

**URL:** <https://forum.kirupa.com/t/detecting-mouse-outside-stage/290821>\
**Category:** flash\
**Created:** [June 20, 2009, 1:17am UTC](https://forum.kirupa.com/t/detecting-mouse-outside-stage/290821 "2009-06-20T01:17:00Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kirbyprime](https://avatars.discourse-cdn.com/v4/letter/k/f475e1/32.png) [@Kirbyprime](https://forum.kirupa.com/u/Kirbyprime)\
**Post date:** [June 20, 2009, 1:17am UTC](https://forum.kirupa.com/t/detecting-mouse-outside-stage/290821/1 "2009-06-20T01:17:00Z")

</div>

Was wondering if anyone knows how to solve this.

I have a swf that needs to change states based on whether or not the mouse is hovering over the swf or if it’s outside.

I’ve tried doing things such as stage.addEventListener(MouseEvent.MOUSE\_OUT, fnc) but it triggers whenever the mouse goes past different movieclips within the swf.

And since I have interactive elements, I can’t just slap a movieclip over everything and add a listener to that.

So if anyone knows how I can handle this, I’d be very grateful.

Thanks in advance.
