title: How to tell if function being called originated from a click event in javascript
body: <p>How can I tell if a function being called originated from a click event?</p>
  
  <p>For instance, an anchor or button is clicked and the event is captured and a function is called.</p>
  
  <p>Inside of this function in firebug's stack trace I can see an Object like this</p>
  
  <pre><code>Object { originalEvent=Event click, type="click", timeStamp=97128874, more...}
  </code></pre>
  
  <p>It says the originalEvent came from a click.</p>
  
  <p>Depending on whether it came from or click or not, processing occurs differently.</p>
  
  <p>Is there a way to tell if the function being called originated from a click event?</p>