macos: fix calculation of mouse position
This fixes the calculation of the position of the pointer over the surface which was incorrectly providing negative values.
This fixes the calculation of the position of the pointer over the surface which was incorrectly providing negative values.