Orientation bug fixes

Solved issue of handling image orientation while Orientation Lock = ON
in device.