title: Detect scanner input using jquery
body: <p>Suppose I have two textboxes:</p>
  
  <pre><code>&lt;input type="text"id="resourceName" placeholder="Resource name"/&gt;
  &lt;input type="text" id="barCode"  placeholder="barCode(EAN-13)"/&gt;
  </code></pre>
  
  <p>To populate this textboxes I use <strong>barcode</strong> scanner and keyboard.
  What I want is a little bit difficult and I don't know how to do this .
  I can't differentiate when user is populating text boxes with keyboard and when with barcode.
  I need this becouse i want to implement something like : when user is usign barcode scanner and if we don't have focused textbox ,I want to focus barcode textbox and insert this value in this textbox , and when focused is resourceName textbox , first I want to focus barCode textbox and then to insert this value to this textbox.
  I don't want to let user insert barcode in resourceName textbox using barcode scanner .
  The problem is that i can't differentiate events , how user is populating textboxex ?, using barcode scanner or using keyboard.
  Any help will be appreciated.Thanks a lot </p>