Domanda

I don't receive deprecations warning regarding stretchableImageWithLeftCapWidth:topCapHeight: method in XCode. I have the deployment target iOS 6.0. I receive other deprecations warning, for other functions, but none for this one.

In the build settings the warnings are enabled Build Settings -> Warning -> Deprecated Functions is YES In the Build Phases settings Compile Sources i don't have any compiler flags enabled for any files.

È stato utile?

Soluzione

Here's how it's declared in UIImage.h:

- (UIImage *)stretchableImageWithLeftCapWidth:(NSInteger)leftCapWidth topCapHeight:(NSInteger)topCapHeight;

Here's what a deprecated method name typically looks like:

- (CGSize)sizeWithFont:(UIFont *)font NS_DEPRECATED_IOS(2_0, 7_0, "Use -sizeWithAttributes:");

For a warning to appear, one of the NS_DEPRECATED macros from NSObjCRuntime.h (or one of the availability macros from AvailabilityMacros.h) must be present.

This is probably considered a bug, and should be reported on http://bugreport.apple.com.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top