Make sure navigator has non-negative width/height

Fixes an execption in IE7 and 8, which would throw when trying to assign negative widths/heights.

See #24.