Skip to content

HWSwipeAnimatedView implements the Mailbox gestural table view cell style but with a simple view

License

Notifications You must be signed in to change notification settings

hugweb-zz/HWSwipeAnimatedView

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HWSwipeAnimatedView

HWSwipeAnimatedView implements the Mailbox gestural table view cell style but with a simple view

##Usage

    HWSwipeAnimatedView *swipeView = [[HWSwipeAnimatedView alloc] initWithFrame:CGRectMake(0, (self.view.frame.size.height / 2) - 40, self.view.frame.size.width, 80)
                                                                      leftImage:@"check.png"
                                                                      leftColor:[UIColor colorWithRed:37.0 / 255.0 green:174.0 / 255.0 blue:96.0 / 255.0 alpha:1.0]
                                                                     rightImage:@"cross.png"
                                                                     rightColor:[UIColor colorWithRed:236.0 / 255.0 green:104.0 / 255.0 blue:89.0 / 255.0 alpha:1.0]];
    [swipeView setBackgroundColor:[UIColor grayColor]];
    [swipeView setSlideViewBackgroundColor:[UIColor darkGrayColor]];
    [swipeView setDelegate:self];
    [swipeView setStateLabelTextColor:[UIColor whiteColor]];
    [swipeView setStateLeftText:@"Supprimer"];
    [swipeView setLeftIconImage:@"trash.png"];
    [swipeView setStateRightText:@"Annuler"];
    [swipeView setRightIconImage:@"undo.png"];
    [swipeView setTextStateIndicator:YES];
    [swipeView setMode:HWSwipeAnimatedViewModeExit];
    [self.view addSubview:swipeView];
    

###Delegate

@interface UIViewController () <HWSwipeAnimatedViewDelegate>
#pragma mark - UIViewController

-(void)swipeAnimatedView:(HWSwipeAnimatedView *)view didTriggerState:(HWSwipeAnimatedViewState)state withMode:(HWSwipeAnimatedViewMode)mode withExitModeLeft:(HWSwipeAnimatedViewExitMode)exitModeLeft withExitModeRight:(HWSwipeAnimatedViewExitMode)exitModeRight {
  //TODO
}

##Requirements

  • iOS >= 5.0
  • ARC

Contact

Hugues Blocher

License

HWSwipeAnimatedView is available under the MIT license.

About

HWSwipeAnimatedView implements the Mailbox gestural table view cell style but with a simple view

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published