Fixed some deprecated iOS methods