Merge "Refactoring the scale and pan detection in the ScreenMagnifier." into jb-mr1-dev