Pull the discussion back from https://gist.github.com/nschonni/6466525#comment-901893 since I don't seem to get notifications on Gist comments :frowning: 
```js
if (opts.refreshOnClick) {
	_pe.document.on('click', function (e) {
		// If there is a click on the page, but ignore middle/right mouse buttons
		if (typeof e.button === 'undefined' || e.button === _pe.leftMouseButton) {
			// Only start the session time out after the initial idle period has passed
			// and the action has occurred outside the the ajax limiter's duration
			if (lastActivity >= 1 && (getCurrentTimeMs() - lastActivity) > opts.ajaxLimiter) {
				lastActivity = getCurrentTimeMs();
				start_liveTimeout();
			} else {
				lastActivity = getCurrentTimeMs();
			}
		}
	});
}
```