title: Keep UIButton highlighted after touch & iOS 7
body: <p>I need like to keep a <code>UIButton</code> highlighted after a touch event. In iOS versions &lt; 7 I used the following action for the Touch Up Inside event:</p>
  
  <pre><code>- (IBAction)clickMe:(id)sender {
      UIButton *button = sender;
      [NSOperationQueue.mainQueue addOperationWithBlock:^{ button.highlighted = YES; }];
  }
  </code></pre>
  
  <p>Unfortunately something has changed in iOS 7 and this code doesn't work anymore: if I tap the button, the button reverts to normal state; interestingly, if I keep the button pressed for a little longer, the button remains highlighted. Please note that the app was developed for iOS 6 so it runs in iOS 7 in compatibility mode. I'm trying to figure out a way to make the app work properly on both iOS 6 &amp; 7 but so far I haven't found a nice solution (one workaround is to queue an event that highlights the button after a short delay but that produces an annoying flickering of the button). Any advice?</p>