Latest 1.0
Homepage https://github.com/myinter/BHPopButton
License MIT
Platforms ios 5.0
Frameworks UIKit
Authors

Button With Pop OptionView
在CocoaTouch上实现了模仿各主流输入法弹出可弹出扩展选项菜单功能的Button控件

效果图

使用方法


    BHPopButton *popButton = [BHPopButton buttonWithType:UIButtonTypeCustom];

    popButton.frame = CGRectMake(33, 200, 100, 100);

    [popButton setTitle:@"popButton" forState:UIControlStateNormal];

    //设置次级选项的内容
    popButton.optionsArray = @[@"A",@"B",@"C",@"ABC",@"Congo"];

    //设置次级选项做出选择后的操作
    [popButton setOnSubItemSelected:^(BHPopButton *view, NSUInteger index, NSString *itemContent) {

        //TODO

    }];

    //设置单击后做出的操作
    [popButton setOnClickBlock:^(BHPopButton *view) {

        //TODO

    }];

Latest podspec

{
    "name": "BHPopButton",
    "version": "1.0",
    "summary": "A Button With Pop Option Mune",
    "description": "A UIComponent in form of Button that provide popView for suboptions",
    "homepage": "https://github.com/myinter/BHPopButton",
    "screenshots": "http://i.niupic.com/images/2017/02/20/VApNpv.gif",
    "license": "MIT",
    "authors": {
        "myinter": "[email protected]"
    },
    "platforms": {
        "ios": "5.0"
    },
    "source": {
        "git": "https://github.com/myinter/Cocoa-BHPopButton.git",
        "commit": "bcd405096a4aeed6b5fc06e31494b3192709ab94"
    },
    "source_files": [
        "BHPopButton",
        "*.{h,m}"
    ],
    "frameworks": "UIKit"
}

Pin It on Pinterest

Share This