button events be dispatched twice
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Anonymous
Posted On:   Tuesday, April 19, 2005 01:13 PM

Hi! Into my main class I Create JDialogs, and I use JDialog.DISPOSE_ON_CLOSE as defaultCloseOperation and setVisible(true) in order to show it. When I run my application for first time, and clicking on menu item I create a JDialog, so, I can use Toolbar buttons with no problems, actionPerformed is executed normally, just once, everything works OK. I close my Dialog and re-entering for second time begin problems. Toolbar buttons actionPerformed are executed twice, what happen?, this problem I noted, happens exactly when JDialog are loaded (created with new) for second time or more times. It is not supposed closing JDialog, will dispose every component content into it?, I tried using windowClosing event doing super.dispose(); and this.dispose(); but noth   More>>

Hi!

Into my main class I Create JDialogs, and I use JDialog.DISPOSE_ON_CLOSE as defaultCloseOperation and setVisible(true) in order to show it. When I run my application for first time, and clicking on menu item I create a JDialog, so, I can use Toolbar buttons with no problems, actionPerformed is executed normally, just once, everything works OK. I close my Dialog and re-entering for second time begin problems. Toolbar buttons actionPerformed are executed twice, what happen?, this problem I noted, happens exactly when JDialog are loaded (created with new) for second time or more times. It is not supposed closing JDialog, will dispose every component content into it?, I tried using windowClosing event doing super.dispose(); and this.dispose(); but nothing at all. Is like closing JDialog it leave it hidden but not destroyed even using DISPOSE_ON_CLOSE. It is just only thing I guess actionPerformed on button events be dispatched twice, I don't know!

I use jdk1.5.0_02 (update 2)

Thanks

   <<Less
About | Sitemap | Contact