Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
miketsprague committed Dec 16, 2015
1 parent c04260c commit 6208440
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ Inspired by Apple’s download progress buttons in the app store
Just add the two files `GBKUIButtonProgressView.h/m` to your project

# Usage
* Create the button as a custom view in your xib, or create it programatically
* Make sure that you don't have a constraint for it's width (it shrinks)--you might need to set the Intrinsic Content Size to "Placeholder" in your xib to avoid errors

```objc
// Add a target (like a regular button)
[self.downloadButton addTarget:self action:@selector(downloadButtonPressed:) forControlEvents:UIControlEventTouchUpInside];
Expand All @@ -35,3 +38,8 @@ Just add the two files `GBKUIButtonProgressView.h/m` to your project
[self.downloadButton setProgress:progress animated:YES];
}
```
See the example for more info.
# Todos
* Polish the API a bit
* Allow it to be IBDesignable

0 comments on commit 6208440

Please sign in to comment.