fix bugs on ios7