skip empty pids
panorama: reuse position variable instead of accessing event late in the function

event may have been overriden during later steps of this callback.

fixes Error:
Uncaught TypeError: Cannot read property 'getXY' of undefined

Signed-off-by: Sven Nierlein <sven@nierlein.de>