diff --git a/Carthage/Build/iOS/YMSwipeTableViewCell.framework/Headers/UITableViewCell+Swipe.h b/Carthage/Build/iOS/YMSwipeTableViewCell.framework/Headers/UITableViewCell+Swipe.h new file mode 100644 index 0000000..f54097e --- /dev/null +++ b/Carthage/Build/iOS/YMSwipeTableViewCell.framework/Headers/UITableViewCell+Swipe.h @@ -0,0 +1,126 @@ +// +// UITableViewCell+Swipe.h +// YMSwipeTableViewCell +// +// Created by Sumit Kumar on 4/8/15. +// Copyright (c) 2015 Microsoft Inc. All rights reserved. +// + +#import +#define YMSwipeGoToDefaultMode @"YMSwipeGoToDefaultMode" + +/** Swipe state of the cell. */ +typedef NS_ENUM(NSInteger, YATableSwipeMode) { + /** The default cell state. The user has not begun swiping the cell. */ + YATableSwipeModeDefault, + /** The left swipe view is completely exposed. The user has completed swiping from right to left. */ + YATableSwipeModeLeftON, + /** The right swipe view is completely exposed. The user has completed swiping from left to right. */ + YATableSwipeModeRightON +}; + +/** Type of swipe effect */ +typedef NS_ENUM(NSInteger, YATableSwipeEffect) { + /** Swipe image is underneath the cell and is fixed during a swipe. */ + YATableSwipeEffectUnmask, + /** The swipe image is clamped to the cell and is moving with the cell during a swipe. */ + YATableSwipeEffectTrail +}; + +/** Swipe direction */ +typedef NS_ENUM(NSInteger, YATableSwipeDirection) { + /** Undefined state */ + YATableSwipeDirectionNone = 0, + /** Left to right swipe */ + YATableSwipeDirectionRight = 1, + /** Right to left swipe */ + YATableSwipeDirectionLeft = 2 +}; + +/** + * Block definition used during a swipe callback. + * + * @param cell The cell in which the swipe is occurring. + * @param translation The point translation of the swipe. + * + */ +typedef void (^YMTableCellDidSwipeBlock)(UITableViewCell *cell, CGPoint translation); + +/** + * Block definition used when a swipe will change the state of the cell. + * + * @param cell The cell in which the swipe is occurring. + * @param mode The swipe mode that the cell will transition to. + * + */ +typedef void (^YMTableCellWillChangeModeBlock)(UITableViewCell *cell, YATableSwipeMode mode); + +/** + * Block definition used when a swipe has changed the state of the cell. + * + * @param cell The cell in which the swipe is occurring. + * @param mode The swipe mode that the cell has transitioned to. + * + */ +typedef void (^YMTableCellDidChangeModeBlock)(UITableViewCell *cell, YATableSwipeMode mode); + +@interface UITableViewCell (Swipe) + +/** Sets the type of swipe effect. The default value is YATableSwipeEffectUnmask. */ +@property (nonatomic, readwrite) YATableSwipeEffect swipeEffect; + +/** This flags determines if multipe cells can be swiped at one time. The default value is NO. */ +@property (nonatomic, readwrite) BOOL allowMultiple; + +/** The background color for the container view of the swiped view. The default value is lightGray. */ +@property (nonatomic, strong) UIColor *swipeContainerViewBackgroundColor; + +/** A content offset delta that determines the snap threshold during a left to right swipe. The default value is 0. */ +@property (nonatomic, readwrite) CGFloat rightSwipeSnapThreshold; + +/** A content offset delta that determines the snap threshold during a right to left swipe. The default value is 0. */ +@property (nonatomic, readwrite) CGFloat leftSwipeSnapThreshold; + +/** The current swipe state of the cell. */ +@property (nonatomic, readwrite) YATableSwipeMode currentSwipeMode; + +/** This block is called during a swipe. */ +@property (nonatomic, strong) YMTableCellDidSwipeBlock swipeBlock; + +/** This block is called when a swipe will change the state of the cell. */ +@property (nonatomic, strong) YMTableCellWillChangeModeBlock modeWillChangeBlock; + +/** This block is called when a swipe has changed the state of the cell. */ +@property (nonatomic, strong) YMTableCellDidChangeModeBlock modeChangedBlock; + +/** Enable or disable swiping, defaults to YES **/ +@property (nonatomic, assign) BOOL swipingEnabled; + +/** + * Adds the view exposed during a right to left swipe. + * + * @param view The view beneath the cell which is exposed during a right to left swipe. + * + */ +- (void)addRightView:(UIView *)view; + +/** + * Adds the view exposed during a left to right swipe. + * + * @param view The view beneath the cell which is exposed during a left to right swipe. + * + */ +- (void)addLeftView:(UIView *)view; + +/** + * Resets the cell to its original state in which no swipe views are exposed. + * + * @param completion This callback is executed after the animation sequence completes. + * If the finished flag is true, then the animation has completed. + * If the finished flag is false, then the animation will complete in the next run loop cycle. + * + */ +- (void)resetSwipe:(void (^)(BOOL finished))completion; + + +@end diff --git a/Carthage/Build/iOS/YMSwipeTableViewCell.framework/Info.plist b/Carthage/Build/iOS/YMSwipeTableViewCell.framework/Info.plist new file mode 100644 index 0000000..b7551e5 Binary files /dev/null and b/Carthage/Build/iOS/YMSwipeTableViewCell.framework/Info.plist differ diff --git a/Carthage/Build/iOS/YMSwipeTableViewCell.framework/YMSwipeTableViewCell b/Carthage/Build/iOS/YMSwipeTableViewCell.framework/YMSwipeTableViewCell new file mode 100755 index 0000000..81d47d5 Binary files /dev/null and b/Carthage/Build/iOS/YMSwipeTableViewCell.framework/YMSwipeTableViewCell differ diff --git a/Carthage/Build/iOS/YMSwipeTableViewCell.framework/_CodeSignature/CodeResources b/Carthage/Build/iOS/YMSwipeTableViewCell.framework/_CodeSignature/CodeResources new file mode 100644 index 0000000..bc13ffa --- /dev/null +++ b/Carthage/Build/iOS/YMSwipeTableViewCell.framework/_CodeSignature/CodeResources @@ -0,0 +1,119 @@ + + + + + files + + Headers/UITableViewCell+Swipe.h + + s9IPoyucj7oGZ2xBYvFuGLs+NDI= + + Info.plist + + /aJWSCfclTMgqzlHDN9lEvXIj0E= + + + files2 + + Headers/UITableViewCell+Swipe.h + + s9IPoyucj7oGZ2xBYvFuGLs+NDI= + + + rules + + ^ + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^version.plist$ + + + rules2 + + .*\.dSYM($|/) + + weight + 11 + + ^ + + weight + 20 + + ^(.*/)?\.DS_Store$ + + omit + + weight + 2000 + + ^(Frameworks|SharedFrameworks|PlugIns|Plug-ins|XPCServices|Helpers|MacOS|Library/(Automator|Spotlight|LoginItems))/ + + nested + + weight + 10 + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Info\.plist$ + + omit + + weight + 20 + + ^PkgInfo$ + + omit + + weight + 20 + + ^[^/]+$ + + nested + + weight + 10 + + ^embedded\.provisionprofile$ + + weight + 20 + + ^version\.plist$ + + weight + 20 + + + + diff --git a/README.md b/README.md index bba38d0..39a8f3b 100644 --- a/README.md +++ b/README.md @@ -134,7 +134,7 @@ Carthage: ###Option 3 CocoaPods: -
pod 'YMSwipeTableViewCell', '~> 2.1.0'
+
pod 'YMSwipeTableViewCell', '~> 2.1.1'
##Contributing diff --git a/YMSwipeTableViewCell.podspec b/YMSwipeTableViewCell.podspec index eed4c26..370658f 100644 --- a/YMSwipeTableViewCell.podspec +++ b/YMSwipeTableViewCell.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'YMSwipeTableViewCell' - s.version = '2.1.0' + s.version = '2.1.1' s.summary = 'YMSwipeTableViewCell is a lightweight library that enables table view cell swiping.' s.description = 'YMSwipeTableViewCell is a lightweight library that enables table view cell swiping (seen in most mail applications). It is implemented as a UITableViewCell class category and can detect left or right horizontal swipes. Upon a left or right swipe, a swipe view is exposed. This library is meant to be flexible, so that any views can be exposed during a swipe and a myriad of actions can be taken during the swipe (e.g., swipe view animations, or cell snap back or destruction at the completion of a swipe).' s.homepage = 'https://github.com/aluong-yammer/YMSwipeTableViewCell.git'