Don't move images that is not visible at all. Look for images under document instead of under the element in focus.