The Appointment Ledger Smells Funny

I recently posted about how my brain leaks out all the Objective-C I know if I go too long without using it, which is barely an exaggeration,  so I made some time in my day this past Friday to clear out a last-minute bug. In that same post, I mentioned how I fell in love with NSNotificationCenter, which I used to try to handle a bug where the UI gets all wonky if the the user taps the VIN Search button while the user had focus on the SearchBar. (I'm simply disabling the VIN Search button until the SearchBar resigns first responder.)

Tapping the VIN Search button while the SearchBar had first responder would cause the SearchBar to scroll up behind the UINavigationController.

Tapping the VIN Search button while the SearchBar had first responder would cause the SearchBar to scroll up behind the UINavigationController.

Well, QA got really creative and decided to see what would happen if they tapped and held the VIN Scan button and then tapped the SearchBar. The solution wasn't really that complicated, but it took me a bit to figure out what I needed to do and  NSNotificationCenter helped me out again:

This approach really doesn't feel right because I've now got 3 observers on the child view for the touch events and 2 on the parent for disabling the VIN Scan button -- it really does have a weird smell to it -- but everything I've read seems to point to NSNotificationCenter as the way go. I really don't know of a better way but I'm sure I'll kick myself in the ass about this solution on some far-off date.