title: Keyboard Robot class issue
body: <p>I've created Keyboard class for working with Robot. But when I starting using methods from this class I have error in logs.</p>
  
  <p>Here's my <code>Keyboard.java</code> with method <code>pressEscape()</code>:</p>
  
  <pre><code>public class Keyboard {
  
      private static Robot robot;
      private static int time = 1000;
  
      public Keyboard(){
          try {
              robot = new Robot();
          } catch (AWTException e) {
              e.printStackTrace();
          }
      }
  
     public void pressEscape() throws TestException {
          if (!getSession().CanRun())
              throw new TestException(InvalidStateMessage);
          robot.delay(time);
          robot.keyPress(KeyEvent.VK_ESCAPE);
          robot.delay(time);
          robot.keyRelease(KeyEvent.VK_ESCAPE);
          robot.delay(time);
      }
  
  }
  </code></pre>
  
  <p>And here's error from log:</p>
  
  <blockquote>
    <p>[2015/08/13 15:43:29] [ID:7F4315A] [Selenium]: java.lang.NullPointerException<br>
    [2015/08/13 15:43:29] [ID:7F4315A] [Selenium]:    at Kodak.AutoTest.Framework.Keyboard.pressEscape(Keyboard.java:128)</p>
  </blockquote>
  
  <p>Change a little method:</p>
  
  <pre><code>public void pressEscape() throws TestException {
          if (!getSession().CanRun())
              throw new TestException(InvalidStateMessage);
          try {
              new Robot();
              robot.setAutoDelay(time);
              robot.keyPress(KeyEvent.VK_ESCAPE);     
              robot.setAutoDelay(time);
              robot.keyRelease(KeyEvent.VK_ESCAPE);
          } catch (AWTException e) {
              e.printStackTrace();
          }
  
      }
  </code></pre>
  
  <p>but still has the same error on line: </p>
  
  <pre><code>robot.keyPress(KeyEvent.VK_ESCAPE); 
  </code></pre>