2.x.x unity IAM orientation fix #1000
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Cherry pick of #999
Unity overrides orientation behavior and enables all orientations in supportedInterfaceOrientations, regardless of the values set in the info.plist. It then uses its own internal logic for restricting the Application's views to the selected orientations.
Our InAppMessageViewController inherits the behavior of all orientations being allowed, so we need to manually set the supported orientations based on the values in the plist.
To do this we can read the values from the supported orientations array in the mainBundle and then return the appropriate UIInterfaceOrientationMask.
If new orientations are released in future iOS versions we will need to update this method
This change is