Latest 0.3
Homepage https://github.com/karryoberes/PopUpMenu
License MIT
Platforms ios 8.0, requires ARC
Authors

Version
License
Platform

Usage

For Objective C
Go to Build Settings of your project and search for Packaging. Under it you would find Defines Module, then change it to Yes. Then build your project after.

For Swift

import PopUpMenu

var menu = PopUpButton(position: CGPointMake(0,0), frame: CGRectMake(7, 30, 35, 35), menuImage: menuIcon!, menuListTitle: ["Menu1", "Menu2", "Menu3", "Menu4"], menuIconNormal: ["Menu1", "Menu2", "Menu3", "Menu4"], menuIconHighlighted: ["Menu1H", "Menu2H", "Menu3H", "Menu4H"],  menuBackgroundImage: "", menuBackgroundHighlightedImage: "")

menu.getProperties(UIColor.blackColor().colorWithAlphaComponent(0.7), buttonTitleHighlightedColor: UIColor.whiteColor(), buttonBackgroundColor: UIColor(red: 17/255.0, green: 193/255.0, blue: 210/255.0, alpha: 1.0), buttonSeparatorColor: UIColor.darkGrayColor(), buttonFont: UIFont(name: "HelveticaNeue-Light", size: 20)!)

self.view.addSubview(menu)

For Objective C

@import PopUpMenu;

PopUpButton *menu = [[PopUpButton alloc]initWithPosition:CGPointMake(0, 0) frame:CGRectMake(7, 30, 35, 35) menuImage:image menuListTitle:@[@"Menu1", @"Menu2", @"Menu3", @"Menu4"] menuIconNormal:@[@"Menu1", @"Menu2", @"Menu3", @"Menu4"] menuIconHighlighted:@[@"Menu1H", @"Menu2H", @"Menu3H", @"Menu4H"] menuBackgroundImage:@"" menuBackgroundHighlightedImage:@""];

[menu getProperties:[[UIColor blackColor] colorWithAlphaComponent:0.7] buttonTitleHighlightedColor:[UIColor whiteColor] buttonBackgroundColor:[UIColor colorWithRed:17/255.0 green:193/255.0 blue:210/255.0 alpha:1] buttonSeparatorColor:[UIColor darkGrayColor] buttonFont:[UIFont fontWithName:@"HelveticaNeue-Light" size:20]];

[self.view addSubview:menu];

Example Project

Run the Example Project to see the whole sample code on how to use the PopUpMenu pod in a project.

Installation

PopUpMenu is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "PopUpMenu"

License

PopUpMenu is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "PopUpMenu",
    "version": "0.3",
    "summary": "A subclass on UIButton and UIViewController that provides a button that shows a PopUp Menu once it is long pressed.",
    "description": "This CocoaPod provides the ability to add a floating button in a view. Once long pressed, a customizable PopUp Menu is shown.",
    "homepage": "https://github.com/karryoberes/PopUpMenu",
    "license": "MIT",
    "authors": {
        "Oberes, Karry Raia C.": "[email protected]"
    },
    "source": {
        "git": "https://github.com/karryoberes/PopUpMenu.git",
        "tag": "0.3"
    },
    "platforms": {
        "ios": "8.0"
    },
    "requires_arc": true,
    "source_files": "Pod/Classes/**/*",
    "resource_bundles": {
        "PopUpMenu": [
            "Pod/Assets/*.png"
        ]
    }
}

Pin It on Pinterest

Share This