bug fix - support for iOS 8 hardware orientation

Changes as described in issue #3158.

These changes allow projects running on iOS 8 to continue using hardware orientation while retaining functionality on older iOS versions.

Please note that this change introduces unwanted behavior in the orientation animation on iOS 8 devices that is yet unaddressed. iOS 7 and earlier remain unchanged.