Improved state of issue #122 (re-submission)

Applied changes in regard to previous pull request comments.

Addresses issue #122
Blocks external popup windows from being opened, including ones opened without a click event.