File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Swing / AWT / SWT and the fly likes A serious JPopupMenu Problem Help! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "A serious JPopupMenu Problem Help!" Watch "A serious JPopupMenu Problem Help!" New topic

A serious JPopupMenu Problem Help!

Khalid Shafquat

Joined: Aug 09, 2002
Posts: 6
Hope u all r fine . I had a solution from ur side few months ago i m really thankfull to u for that. Now i m facing a few problems with the JPopupMenu and JMenuItems. The problem is the we delveloped a large scale application using VisualAge for Java. The application was menu driven , having all the options in the title bar menu (Drop down menus as most applications have). Then our architects decided to change it to some new outlook i mean with a new WEB look style having icons on the button what we did we decided to move those menu and make them open at the actionPerfomed of the button. We replace the Root Menu with the JPopupMenu and remaining the links of other SUB-MENU and all the remaining hierarchy AS IS. This works fine but we had a requirement that. like 'Start' remain pressed in Windows whether u move in any hierarchy of sub menus, till u click out side it , we tried to do this with TOGGLE BUTTON and make it De-selected on focus lost , this works fine till we go in the very child menu i .e the in the 1st hierarchey. Problem starts when we move in the 2nd level. for example i presses START button go in the Programs menu (Still fine) but loses focus if we move in some sub menu. The reason i found is that the next sub-menu isnt the child of the First menu , (may be due to the diffrence of JMenu and JPopupMenu).
What i want to know is how can we overcome this problem with less changes (as application is so huge we cant afford at this stage.....time is short)
Please let me know about ,i will be thankfull to u
I agree. Here's the link:
subject: A serious JPopupMenu Problem Help!
jQuery in Action, 3rd edition