TintColor of UIButton gets resetted to UIWindow's tintColor [iPad only]
| Originator: | cmenschel54 | ||
| Number: | rdar://22323444 | Date Originated: | 08/18/2015 |
| Status: | Open | Resolved: | |
| Product: | iPad | Product Version: | |
| Classification: | Reproducible: | Always |
Summary:
The tintColor of the UIButton will be changed (gets resetted) to the UIWindow's tintColor when pushing a new UIViewController on the UINavigationController stack.
This bug occurs on iPad with a modal presented UINavigationController with modalPresentationStyle UIModalPresentationFormSheet
Steps to Reproduce:
1. Set the UIWindow tintColor to red
2. present a UINavigationController modally with UIModalPresentationFormSheet style
3. The rootViewController of the UINavigationController contains a button that pushes a new UIViewController
4. this button has a tintColor and an image.
5. Tap the button ("X") in order to push the new UIViewController
6. Go back in the navigationController stack
7. The button color will change to red (from white)
see attached example project
Expected Results:
The tintColor of the UIButton should remain as configured and should NOT change when pushing a viewController and popping on the UINavigationController.
The color of the button must remain white when going back.
Actual Results:
The button's color will change to red.
see attached example project
Version:
iOS 8 and iOS 9
Notes:
Tried with Xcode 6.4 and 7.0 beta 5 (7A176x)
See example:
https://github.com/tapwork/TintColorBug/
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!