Skip to content

Instantly share code, notes, and snippets.

@alekseypotapov-dev
Created February 27, 2014 08:45
Show Gist options
  • Save alekseypotapov-dev/9246558 to your computer and use it in GitHub Desktop.
Save alekseypotapov-dev/9246558 to your computer and use it in GitHub Desktop.
UISegmentedControl show popover from according segment
CGRect frame = [segmentControl frame];
frame =CGRectMake((frame.size.width/No. of segments * [segmentControl selectedSegmentIndex]), 0, frame.size.width/No. of segments, segmentControl.bounds.size.height);
[m_PopOver presentPopoverFromRect:frame inView:segmentControl permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment