Fix ugly offset in ios8

Added method to fix ugly offset for ios8