{"action":"created","issue":{"url":"https://api.github.com/repos/victorBaro/VBFPopFlatButton/issues/21","labels_url":"https://api.github.com/repos/victorBaro/VBFPopFlatButton/issues/21/labels{/name}","comments_url":"https://api.github.com/repos/victorBaro/VBFPopFlatButton/issues/21/comments","events_url":"https://api.github.com/repos/victorBaro/VBFPopFlatButton/issues/21/events","html_url":"https://github.com/victorBaro/VBFPopFlatButton/issues/21","id":50354642,"number":21,"title":"VBFPopFlatButton as UIBarButtonItem","user":{"login":"sashakid","id":5786373,"avatar_url":"https://avatars.githubusercontent.com/u/5786373?v=3","gravatar_id":"","url":"https://api.github.com/users/sashakid","html_url":"https://github.com/sashakid","followers_url":"https://api.github.com/users/sashakid/followers","following_url":"https://api.github.com/users/sashakid/following{/other_user}","gists_url":"https://api.github.com/users/sashakid/gists{/gist_id}","starred_url":"https://api.github.com/users/sashakid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sashakid/subscriptions","organizations_url":"https://api.github.com/users/sashakid/orgs","repos_url":"https://api.github.com/users/sashakid/repos","events_url":"https://api.github.com/users/sashakid/events{/privacy}","received_events_url":"https://api.github.com/users/sashakid/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2014-11-28T09:15:27Z","updated_at":"2015-01-13T15:51:59Z","closed_at":null,"body":"Hi, when I added VBFPopFlatButton as UIBarButtonItem, the all touches are not recognized from first time – it's very bad triggered. \r\nMy try was in that way:\r\n```objc\r\n        self.addTaskButton = [[VBFPopFlatButton alloc] initWithFrame:CGRectMake(0, 0, 25, 25) buttonType:buttonAddType buttonStyle:buttonPlainStyle animateToInitialState:YES];\r\n        self.addTaskButton.lineThickness = 2;\r\n        self.addTaskButton.tintColor = [UIColor whiteColor];\r\n        [self.addTaskButton addTarget:self\r\n                               action:@selector(addTask)\r\n                     forControlEvents:UIControlEventTouchUpInside];\r\n        \r\n        UIView *containingView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 25, 25)];\r\n//        UITapGestureRecognizer *singleFingerTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(addTask)];\r\n//        [containingView addGestureRecognizer:singleFingerTap];\r\n        [containingView addSubview:self.addTaskButton];\r\n        UIBarButtonItem *containingBarButton = [[UIBarButtonItem alloc] initWithCustomView:containingView];\r\n        self.navigationItem.rightBarButtonItem = containingBarButton;\r\n```\r\nThen I tried to make containing view tappable and increase its area but this didn't help.\r\nI know that UIButton and UIBarButtonItem are the different things but maybe someone could help me to make VBFPopFlatButton work as normal default UIBarButtonItem and make it excellent triggering? Thanks."},"comment":{"url":"https://api.github.com/repos/victorBaro/VBFPopFlatButton/issues/comments/69765764","html_url":"https://github.com/victorBaro/VBFPopFlatButton/issues/21#issuecomment-69765764","issue_url":"https://api.github.com/repos/victorBaro/VBFPopFlatButton/issues/21","id":69765764,"user":{"login":"victorBaro","id":994334,"avatar_url":"https://avatars.githubusercontent.com/u/994334?v=3","gravatar_id":"","url":"https://api.github.com/users/victorBaro","html_url":"https://github.com/victorBaro","followers_url":"https://api.github.com/users/victorBaro/followers","following_url":"https://api.github.com/users/victorBaro/following{/other_user}","gists_url":"https://api.github.com/users/victorBaro/gists{/gist_id}","starred_url":"https://api.github.com/users/victorBaro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/victorBaro/subscriptions","organizations_url":"https://api.github.com/users/victorBaro/orgs","repos_url":"https://api.github.com/users/victorBaro/repos","events_url":"https://api.github.com/users/victorBaro/events{/privacy}","received_events_url":"https://api.github.com/users/victorBaro/received_events","type":"User","site_admin":false},"created_at":"2015-01-13T15:51:59Z","updated_at":"2015-01-13T15:51:59Z","body":"Thanks for your answer @MattKiazyk \r\nI haven't had time to try it as a UIBarButtonItem"}}