improved iOS 7 compatibility