Update object.class.js

This should account both for scale factor and canvas zooming