別のコンポーネントがクリックされたときにポップアップメニューがまだ開いている場合、そのコンポーネントはイベントを取得しません。これは、ポップアップによって消費されている可能性があるためです。これは、一般的にすべてのJPopupmenuで発生します。これは、Windows LAF(Windows7)を搭載したJava7でのみ発生します。回避策はありますか?既知のバグですか?
import javax.swing.*;
import java.awt.event.*;
public class Test
{
    public static void main(String[] s)
    throws Exception
    {
           String lookAnfFeelClassName = UIManager.getSystemLookAndFeelClassName();
           UIManager.setLookAndFeel(lookAnfFeelClassName);
           JMenu menu = new JMenu("TEST Menu");
           JMenuItem menuItem = new JMenuItem("Menu Item 1");
           JMenuBar menuBar = new JMenuBar();
           menu.add(menuItem);
           menuBar.add(menu);
           final JButton b = new JButton("Test");
           b.setBounds(5, 50, 60, 20);
           b.addActionListener(new ActionListener()
           {
                  public void actionPerformed(ActionEvent e)
                  {
                        //If the Menu is open when I press the button, the putton is not pressed 
                        //so I have to press it again. 
                        JOptionPane.showMessageDialog(b, "Button Pressed");
                  }
           }
           );
           JFrame frame = new JFrame();
           frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
           frame.setSize(150, 150);
           frame.setJMenuBar(menuBar);
           frame.getContentPane().setLayout(null);
           frame.getContentPane().add(b);
           frame.setVisible(true);           
    }
}