一個簡單好用的彈出視圖 LSXPopMenu
效果圖
LSXPopMenu.gif
使用說明:
#import "LSXPopMenu.h"
@interface ViewController ()<LSXPopMenuDelegate>
//創(chuàng)建方式一
/****根據(jù)傳入的View 彈出視圖****/
[LSXPopMenu showRelyOnView:sender titles:@[@"可以點么",@"好的"] icons:@[@"yuezhifu",@"blood_weixin"] menuWidth:120 isShowTriangle:YES delegate:self];
//創(chuàng)建方式二
/****制定 Point 彈出視圖****/
[LSXPopMenu showAtPoint:CGPointMake(self.view.centerX, self.view.centerY) titles:@[@"可以點么",@"好的"] icons:@[@"yuezhifu",@"blood_weixin"] menuWidth:200 isShowTriangle:NO delegate:self];
//創(chuàng)建方式三
/****制定 Point 彈出視圖****/
LSXPopMenu * menu=[[LSXPopMenu alloc]initWithTitles:@[@"可以點么",@"好的"] icons:@[@"yuezhifu",@"blood_weixin"] menuWidth:200 delegate:self];
menu.isShowTriangle=YES;//是否顯示三角
menu.cornerRadius=0;//圓角半徑
menu.isShowShadow=YES;//是否顯示陰影
//menu.type=LSXPopMenuTypeDark;//顯示
menu.textColor=[UIColor redColor];
menu.fontSize=25;
[menu showRelyOnView:sender];
gitHub地址 歡迎下載,給個star吧!