framework: fix screenshot and rotation animation for devices with abnormal hw rotation

Change-Id: I42694931cb1a754aa6c7652c0a96304ef1f88492