can run on ios7+ device and fix crash (apple bug about constraint)