Problem with 3d rotation

[COLOR=Black][FONT=&quot] [FONT=Arial][SIZE=3]I was wondering if anyone would help me with a tiny problem I’m having. If you look at the test site at [/SIZE][/FONT][/FONT]http://www.designsuccess.com/proof[/COLOR][COLOR=Black][FONT=&quot][FONT=Arial][SIZE=3] using Mac OS X, you’ll notice that when you change focus from Safari or Firefox to another application, the main rotating menu goes berserk. Since I develop and design on Windows, I had not noticed the problem, but one of my partners uses a Mac and he pointed it out to me. I tried including a MOUSE_LEAVE event but the problem persists, here’s my code:[/SIZE][/FONT][/FONT][/COLOR][FONT=Arial][SIZE=3][COLOR=Black]
[/COLOR][/SIZE][/FONT]

    [FONT=Arial][SIZE=3][COLOR=Black]import gs.TweenMax;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]var ifRotate:Boolean = false;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]stage.addEventListener(MouseEvent.MOUSE_MOVE,init);[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]function init(e:Event) {[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                ifRotate = true;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]}[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]stage.addEventListener(Event.MOUSE_LEAVE,deActivate);[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]function deActivate(e:Event) {[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                ifRotate = false;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]}[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]stage.addEventListener(Event.ENTER_FRAME,loop);[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]this.menu_container.transform.matrix = new Matrix();[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]this.menu_container.z = -500;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]function loop(e:Event) {[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                this.menu_container.x = stage.stageWidth / 2;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                this.menu_container.y = stage.stageHeight / 2;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                this.menu_container.z = 0;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                this.menu_container.y = stage.stageHeight / 2;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                var distx = mouseX / stage.stageWidth;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                var disty = mouseY / stage.stageHeight;[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]var rX = (60-(120*disty));[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                var rY = (-60+(120*distx));[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]if (ifRotate) {[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                               TweenMax.to(this.menu_container, .75, {rotationX:rX, rotationY:rY});[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                } else {[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                               TweenMax.to(this.menu_container, .75, {rotationX:0, rotationY:0});[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]                }[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
  [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]}
[/COLOR][/SIZE][/FONT]

[FONT=Arial][SIZE=3][COLOR=Black]
[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
[/COLOR][/SIZE][/FONT] [FONT=Arial][SIZE=3][COLOR=Black]
[/COLOR][/SIZE][/FONT] [FONT=Arial][SIZE=3][COLOR=Black]It’s really a weird behavior and I checked and rechecked the code but can’t seem to find anything wrong with it. Hope you can help out[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=3][COLOR=Black]
[/COLOR][/SIZE][/FONT] [FONT=Arial][SIZE=3][COLOR=Black]
Cheers[/COLOR][/SIZE][/FONT]