Skip to content

ckpiggy/CT_PopOutMenu_Demo

Repository files navigation

<script src="https://google-code-prettify.googlecode.com/svn/loader/run_prettify.js"></script>

CT_PopOutMenu_Demo

This control is like an UIAlertView with button icon and four basic layout. I also added an UIActivityIndicatorView in this control, you can just "startAnimation" to get it work on the pop out menu. alt tag

#How to use Drag the CTPopOutMenu.h, CTPopOutMenu.m file into your project and import the .h file. Once you drag these file into your project and import .h file you have finished 50% progresses in useing the control. To get the menu pop out on the screen, you need three more steps like these code.

NSArray * items = ....
popMenu = [[CTPopoutMenu alloc]initWithTitle:@"Title" message:@"message" items:items];
popMenu.menuStyle = MenuStyleDefault , MenuStyleGrid , MenuStyleList or MenuStyleOval;//choose one from these
[popMenu showMenuInParentViewController:parentVC withCenter:center];

In the last, you can setup the delegate if you need. It can tell you which item has been selected.

popMenu.delegate = where_you_contol_the_menu;//"self" in most situation 
-(void)menu:(CTPopoutMenu*)menu willDismissWithSelectedItemAtIndex:(NSUInteger)index;
-(void)menuwillDismiss:(CTPopoutMenu *)menu ;

#Credit This control was inspired by RNGridMenu. I learned how to blur background by taking screenshot and blur the image.

#License see LICENSE

#Contact me I started to learn obj-C on Sept.2014. If you have any suggestion about improving my coding skill, please contact me. e-mail:mrgmp2004@hotmail.com

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published