Skip to content

Instantly share code, notes, and snippets.

@alexeystrakh
Created May 20, 2015 07:10
Show Gist options
  • Save alexeystrakh/fdc3da5746027272a179 to your computer and use it in GitHub Desktop.
Save alexeystrakh/fdc3da5746027272a179 to your computer and use it in GitHub Desktop.
#ios #xamarin Disable Button Tap Lag in UITableView controls
public static class TableViewHelper
{
public static void DisableButtonTapLag(this UITableView target)
{
if (target == null)
return;
//http://stackoverflow.com/questions/19256996/uibutton-not-showing-highlight-on-tap-in-ios7
target.DelaysContentTouches = false;
foreach (UIView currentView in target.Subviews)
{
var uIScrollView = currentView as UIScrollView;
if (uIScrollView != null)
uIScrollView.DelaysContentTouches = false;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment