You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Summary:
If you make an extension on UIButton that conforms it to a protocol, you’ll no longer be able to connect to that button’s Sent Events outlets, such as Touch Up Inside.
Steps to Reproduce:
You can follow along with the attached project.
Create a Single View iPhone application in Swift.
Add a button to the main view controller in the storyboard. Observe that, in the Connections Inspector for that button, all the items under Sent Events are available for connection (e.g. Did End On Exit, Editing Changed, etc.).
Go back to Interface Builder and click on the button. Observe that the button no longer has any Sent Events available for connection. If you had already assigned one of those events to an IBAction method, the Connections Inspector warns that “‘UIButton’ is no longer a valid event source.” as in the screenshot on this bug: BonMot disables IBActions dragging from storyboard Rightpoint/BonMot#252
Expected Results:
Adding an extension to UIButton that conforms it to a protocol has no bearing on whether you can add actions to it.
Actual Results:
Adding an extension to UIButton that conforms it to a protocol breaks the ability to connect actions to it in Interface Builder.
Regression:
Unknown. Reproduces back to Xcode 7.3.1 (7D1014), the earliest version I have installed on my machine.
Description
Summary:
If you make an extension on UIButton that conforms it to a protocol, you’ll no longer be able to connect to that button’s Sent Events outlets, such as Touch Up Inside.
Steps to Reproduce:
You can follow along with the attached project.
protocol MyProtocol { }
extension UIButton: MyProtocol { }
Expected Results:
Adding an extension to UIButton that conforms it to a protocol has no bearing on whether you can add actions to it.
Actual Results:
Adding an extension to UIButton that conforms it to a protocol breaks the ability to connect actions to it in Interface Builder.
Regression:
Unknown. Reproduces back to Xcode 7.3.1 (7D1014), the earliest version I have installed on my machine.
Notes:
Sample project also posted here: https://cl.ly/ik9k
Product Version: Xcode_8.2.1 (8C1002)
Created: 2017-01-12T22:57:38.557280
Originated: 2017-01-12T17:57:00
Open Radar Link: http://www.openradar.me/30001713
The text was updated successfully, but these errors were encountered: