I have a view controller linked to a XIB:
__weak IBOutlet UITextField *dateTextField;
After renaming this field, I’m still able to see the old variable in the XIB File Owner’s Outlet list. It looks like something is not automatically refreshed in the XIB file.
After restarting XCode, the old variable disappeared as expected. I just find it very unusual to have to do that. Need to understand what’s happening.
- Is this a normal behavior or a bug in the tool?
- Will I be able to manually trigger this refresh?
Thanks a lot.
Usually this happens because you haven’t yet saved the file in which you made the outlet modification. To resolve this without restarting Xcode each time you can just save the header when your done modifying it (as @Steven Fisher pointed out command+option+s saves all), if that doesn’t work a build usually does (command+shift+b) and if all else fails a good clean (command+shift+k) should set it straight.