Skip to content

A simple and fully customizable way to display a button menu.

License

Notifications You must be signed in to change notification settings

tungvoduc/DTButtonMenuController

Repository files navigation

DTButtonMenuController

Version License Platform

Example

Screenshot

DTButtonMenuController is extremely easy to use. For minimal intergration in your project, here is what you need to do:

let viewController = DTButtonMenuController(highlightedView: view)
itemSize = CGSize(width: 50, height: 50)
itemsDistanceToTouchPoint = 100

// Add five item buttons into controller
for _ in 0...4 {
	let item = DTMenuButton(completionHandlerBlock: { (button: DTMenuButton) in
    		
         })
     })
            
    // Extra configuration for item button, e.g backgroundColor, image, rounded corner
            
    // Add item button to controller
    viewController.addItem(item)
}

present(viewController, animated: true, completion: nil)

In common cases, you will not use DTButtonMenuController but subclass it and make your own controller.

Requirements

Installation

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

pod "DTButtonMenuController"

Author

Tung Vo, tung98.dn@gmail.com

License

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

About

A simple and fully customizable way to display a button menu.

Resources

License

Stars

Watchers

Forks

Packages

No packages published