Path: csiph.com!x330-a1.tempe.blueboxinc.net!feeder1.hal-mli.net!news.alt.net!news-in-01.newsfeed.easynews.com!easynews.com!easynews!news-out.news.tds.net!newsreading01.news.tds.net!86597e80!not-for-mail From: "Jason Cavett" Subject: Listeners Firing Too Ofte Message-ID: <1172178471.140471.20160@s48g2000cws.googlegroups.com> X-Comment-To: comp.lang.java.gui Newsgroups: comp.lang.java.gui Content-Type: text/plain; charset=IBM437 Content-Transfer-Encoding: 8bit X-Gateway: time.synchro.net [Synchronet 3.15a-Win32 NewsLink 1.92] Lines: 30 Date: Wed, 27 Apr 2011 15:30:51 GMT NNTP-Posting-Host: 96.60.20.240 X-Complaints-To: news@tds.net X-Trace: newsreading01.news.tds.net 1303918251 96.60.20.240 (Wed, 27 Apr 2011 10:30:51 CDT) NNTP-Posting-Date: Wed, 27 Apr 2011 10:30:51 CDT Organization: TDS.net Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.gui:1008 To: comp.lang.java.gui I am developing a GUI (in Java, of course) that has a JTree on the left hand side of the window (similar to Windows Explorer or something like that) and on the right hand side the user can open various property windows to edit the items in the JTree. The issue I'm having is this... I have added a key listener to one of the property windows so that, when the user hits the delete key, they can delete parts of the equation they constructed (mathematical equations). The JTree also has a separate key listener that will delete the selected nodes in the tree if I hit the delete key. Both these keylisteners work fine on their own. However, when I open up the property window and highlight part of the equation and hit the delete key, not only does that part of the equation delete, but then the JTree also captures the KeyAction and deletes the currently selected node in the JTree. I have no clue why this is happening. The JTree doesn't have direct focus. I haven't been able to find any real connection between the two components. Any ideas/suggestions/? --- * Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet! --- Synchronet 3.15a-Win32 NewsLink 1.92 Time Warp of the Future BBS - telnet://time.synchro.net:24