问题
Is there an Android preprocessor macros that Mono for Android defines?
I mean very useful things for cross-platform development like:
#if WINDOWS...#endif
and
#if WINDOWS_PHONE...#endif
回答1:
__ANDROID__
and additionally for each Android API Level:
__ANDROID_4__;__ANDROID_7__;__ANDROID_8__;etc
来源:https://stackoverflow.com/questions/7917859/mono-for-android-preprocessor-macros