| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
An UIButton subclass that allows you to represent a fill percentage stylishly.
You only have to copy the ABFillButton folder to your project.
- (void)buttonIsEmpty:(ABFillButton *)button
{
NSLog(@"buttonIsEmpty");
[self.playButton setFillPercent:1.0];
}There are two main ways of use ABFillButton:
- (IBAction)playButtonPressed:(id)sender
{
//If we want to empty the button with every press
_numberOfPulses++;
[self.playButton setFillPercent:1-(_numberOfPulses*0.1)];
if(_numberOfPulses>10){
_numberOfPulses=0;
[self.playButton setFillPercent:1.0];
}
}//If we want to empty the button with user pressing
[self.playButton setEmptyButtonPressing:YES];Also we can add a grow up effect and shadow when user press the button using:
//If we want to add shadows and a grow up effect when user press the button
[self.playButton configureButtonWithHightlightedShadowAndZoom:YES];ABFillButton is available under the MIT license. See the LICENSE file for more info.
| Back | FazBrowse Home | New Git URL |