I am seeing an issue in our app where setTitle:forState: is not working when a UIButton is in the selected state (the same happens with setImage:forState:). Specifically I am calling:
[self.button setTitle:@"New name" forState:UIControlStateNormal]; The call has no effect until the user taps the button. So, it seems that it is not being redrawn. This only happens in iOS7.1; iOS 7.0 and earlier is fine. It also only seems to happen when the app is built with Xcode 5.1, I don't have 5.0 any more so can't test this directly. But our live app works fine and it was built with 5.0, also others have reported the same thing... (https://devforums.apple.com/message/950802#950802 https://devforums.apple.com/message/951921#951921) The documentation states "At a minimum, you should set the value for the normal state. If a title is not specified for a state, the default behavior is to use the title associated with the UIControlStateNormal state" Therefore, I would not expect to have to set state for UIControlStateSelected. So, a few questions: - am I correct that I should not have to call [self.button setTitle:@"New name" forState:UIControlStateSelected]; - any suggestions for workarounds? - any ideas how this could happen when building with xcode 5.1 but not xcode 5.0? Thanks Dave _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com