Fix for issue #3.

Added the appropriate check to the code. Couldn't see any obvious way to test this since there doesn't appear to be a way to hardcode a devicePixelRatio.