title: add LIstener on OS in JAVA
body: <pre><code>JFrame frame = new JFrame();
  Robot bot = new Robot();
  frame.addMouseListener(new MouseAdapter(){
    public void mouseClicked(MouseEvent e){
    bot.keyPress(KeyEvent.VK_SHIFT);
    bot.keyRelease(KeyEvent.VK_SHIFT);
  }
  });
  </code></pre>
  
  <p>I wrote program in Java when I click on JFrame, it will press SHIFT key automatically. But I don't want exactly this program.
  I want that when I click on Desktop or anywhere of O.S. (not only JFrame), it execute that command. 
  Is there any way to do this? Please help me. Appreciate in advance</p>