unregisterForTraitChanges:
Tells the system to stop observing previously registered traits.
Declaration
- (void) unregisterForTraitChanges:(id<UITraitChangeRegistration>) registration;Parameters
- registration:
A token that identifies the registration, obtained from one of the trait registration method calls.
Discussion
Use this method if you want the system to stop observing trait changes for a previous registration. UIKit doesn’t require you to unregister for trait changes at the end of the view lifecycle. Unregister only if you need to dynamically change which traits you observe.