This is a migrated thread and some comments may be shown as answers.

Menu re-opens after alert (MessageBox) is closed outside of browser window

0 Answers 11 Views
Menu
This is a migrated thread and some comments may be shown as answers.
Polaris431
Top achievements
Rank 1
Polaris431 asked on 21 Jan 2009, 10:31 AM
Using client-side code, I bring up a MessageBox (alert) when a menu item is clicked. I close the menu item using the close() method prior to using the alert method. The browser window where the menu is located is small and not centered on the screen. When the MessageBox appears, it appears in the middle of the screen and outside of the browser window. After I close the MessageBox, the menu item that I previously closed re-opens again. Only after I move the mouse over the browser window will it close. However, if the browser window is large enough or centered on the screen, the menu item will close after the MessageBox closes. I prefer not to relocate the browser window or resize it, if possible. I don't believe it's possible to have the MessageBox appear centered over the browser window (unless someone knows how to do that). Therefore, the only solution I can think of is that something has to be done in Javascript. Is there a way to refresh the menu or do something to guarantee that it closes even if the mouse is outside of the browser window?

No answers yet. Maybe you can help?

Tags
Menu
Asked by
Polaris431
Top achievements
Rank 1
Share this question
or