Skip to content

Commit

Permalink
update demo project and readme
Browse files Browse the repository at this point in the history
  • Loading branch information
zhxnlai committed Nov 12, 2014
1 parent 78d6f1f commit 5065e26
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 3 deletions.
10 changes: 10 additions & 0 deletions README.md
Expand Up @@ -51,9 +51,15 @@ self.swipeableView.delegate = self;
- (void)swipeableView: (ZLSwipeableView *)swipeableView didSwipeRight:(UIView *)view {
NSLog(@"did swipe right");
}
- (void)swipeableView:(ZLSwipeableView *)swipeableView didStartSwipingView:(UIView *)view atLocation:(CGPoint)location {
NSLog(@"did start swiping at location: x %f, y%f", location.x, location.y);
}
- (void)swipeableView: (ZLSwipeableView *)swipeableView swipingView:(UIView *)view atLocation:(CGPoint)location {
NSLog(@"swiping at location: x %f, y%f", location.x, location.y);
}
- (void)swipeableView:(ZLSwipeableView *)swipeableView didEndSwipingView:(UIView *)view atLocation:(CGPoint)location {
NSLog(@"did start swiping at location: x %f, y%f", location.x, location.y);
}
~~~

To swipe the top view programmatically:
Expand All @@ -73,6 +79,10 @@ Requirements
- iOS 7 or higher.
- Automatic Reference Counting (ARC).

Contributions
---
- Thanks [iamphill](https://github.com/iamphill) for adding new delegates

License
---
ZLSwipeableView is available under MIT license. See the LICENSE file for more info.
4 changes: 2 additions & 2 deletions ZLSwipeableView.podspec
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "ZLSwipeableView"
s.version = "0.0.3"
s.version = "0.0.5"
s.summary = "A simple view for building card like interface like Tinder and Potluck."
s.description = <<-DESC
ZLSwipeableView is a simple view for building card like interface like Tinder and Potluck. It uses dataSource pattern and is highly customizable.
Expand All @@ -10,7 +10,7 @@ Pod::Spec.new do |s|
s.license = { :type => "MIT", :file => "LICENSE" }
s.author = { "Zhixuan Lai" => "zhxnlai@gmail.com" }
s.platform = :ios, "7.0"
s.source = { :git => "https://github.com/zhxnlai/ZLSwipeableView.git", :tag => "0.0.3" }
s.source = { :git => "https://github.com/zhxnlai/ZLSwipeableView.git", :tag => "0.0.5" }
s.source_files = "ZLSwipeableView", "ZLSwipeableView/**/*.{h,m}"
# s.exclude_files = "Classes/Exclude"
s.framework = "UIKit"
Expand Down
1 change: 0 additions & 1 deletion ZLSwipeableView/ZLSwipeableView.h
Expand Up @@ -20,7 +20,6 @@
- (void)swipeableView: (ZLSwipeableView *)swipeableView didEndSwipingView:(UIView *)view atLocation:(CGPoint)location;
@end


// DataSource
@protocol ZLSwipeableViewDataSource <NSObject>
@required
Expand Down
6 changes: 6 additions & 0 deletions ZLSwipeableViewDemo/ZLSwipeableViewDemo/ViewController.m
Expand Up @@ -78,9 +78,15 @@ - (void)swipeableView: (ZLSwipeableView *)swipeableView didSwipeLeft:(UIView *)v
- (void)swipeableView: (ZLSwipeableView *)swipeableView didSwipeRight:(UIView *)view {
NSLog(@"did swipe right");
}
- (void)swipeableView:(ZLSwipeableView *)swipeableView didStartSwipingView:(UIView *)view atLocation:(CGPoint)location {
NSLog(@"did start swiping at location: x %f, y%f", location.x, location.y);
}
- (void)swipeableView: (ZLSwipeableView *)swipeableView swipingView:(UIView *)view atLocation:(CGPoint)location {
NSLog(@"swiping at location: x %f, y%f", location.x, location.y);
}
- (void)swipeableView:(ZLSwipeableView *)swipeableView didEndSwipingView:(UIView *)view atLocation:(CGPoint)location {
NSLog(@"did start swiping at location: x %f, y%f", location.x, location.y);
}

#pragma mark - ZLSwipeableViewDataSource
- (UIView *)nextViewForSwipeableView:(ZLSwipeableView *)swipeableView {
Expand Down

0 comments on commit 5065e26

Please sign in to comment.