Fixed #19.

The didAccelerate function now takes into account the orientation of
the device.