I have a video that I play. To use full screen mode in iOS 3.2, I use MPMoviePlayerViewController (it seems to work only with this class). But if I want to build for iOS 3.0, I obviously get a few errors, because this class is unknown in iOS 3.0. I also know how to get what I want with MPMoviePlayerController in iOS 3.0, but I can only have iOS 3.0 code or iOS 3.2 code.
How to handle this? - solution found (see bottom of nested editing)
I assume that I need to use several goals, do you have any suggestions on how to do this (always, when I tried several goals, I got errors and gave up :))?
Edit bundled (several editable changes)
At first I thought it would work.#ifdef __IPHONE_3_0
#endif
But this is not because in the iOS Availability.h files you have all the OS defined from 2.0 to your current. Therefore, if you compile iOS 3.2, #ifdef __IPHONE_3_0 will also return true.
Then I thought it would work
#if __IPHONE_OS_VERSION_MIN_REQUIRED < __IPHONE_3_2
#else
#end
But this is not so. Because in iOS 3, for example, __IPHONE_3_2 is undefined.
So, I thought that I would have to create an even more intelligent if / elseif / else block, but then I (finally: D) read the comment above __IPHONE_X_X in the boxes. AvailabilityInternal.h file definitions:
, __IPHONE_OS_VERSION_MIN_REQUIRED , __IPHONE_X_X - , ... , , 0. . , ...
,
( 100%)
#if __IPHONE_OS_VERSION_MIN_REQUIRED < 30200
#else
#endif