marinehero / UpvoteControl

UIControl for up vote widgets found in Product Hunt and Reddit

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

UpvoteControl

UIControl that mimics the behavior of the up vote widget in sites like Product Hunt. Written in Swift

Installation

Carthage is the recommended way to install UpvoteControl. Add the following to your Cartfile:

github "raulriera/UpvoteControl"

Usage:

Subclass a UIView with UpvoteControl class. Dig into the source code to find all the available options, everything is laid out nicely.

If you are using storyboards you can attach an IBAction to the .ValueChanged event

@IBAction func valueDidChange(sender: UpvoteControl) {
    println(sender.count)
}

About:

Created by Raul Riera, @raulriera

About

UIControl for up vote widgets found in Product Hunt and Reddit

License:MIT License


Languages

Language:Swift 88.2%Language:C++ 11.8%