# Preventing Mouse Clicks from Re-Focusing?

**URL:** <https://forum.kirupa.com/t/preventing-mouse-clicks-from-re-focusing/282192>\
**Category:** flash\
**Created:** [February 18, 2009, 8:29pm UTC](https://forum.kirupa.com/t/preventing-mouse-clicks-from-re-focusing/282192 "2009-02-18T20:29:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![xanderdavis](https://avatars.discourse-cdn.com/v4/letter/x/7c8e57/32.png) [@xanderdavis](https://forum.kirupa.com/u/xanderdavis)\
**Post date:** [February 18, 2009, 8:29pm UTC](https://forum.kirupa.com/t/preventing-mouse-clicks-from-re-focusing/282192/1 "2009-02-18T20:29:17Z")

</div>

\*\*(\*\***This is within a Document Class external Manager.as)**  
(Game controls are called in Controls.as and successfully assigned to Manager.root via addEventListeners within Controls)

```auto

Manager.root = this;
this.root.addEventListener(FocusEvent.MOUSE_FOCUS_CHANGE, dont);

private function dont(e:FocusEvent):void
{
e.preventDefault();
}

var game:Levels = new Levels;
this.addChild(game);
game.mouseChildren = false;
stage.focus = game;

```

**Keyboard controls work… until you click.** Why doesn’t preventDefault(); work? How can I stop the mouse from re-assigning focus upon click?

Thanks for your help! I’m sure a solution will also be handy for many others.

:bounce:
