mtabini / AFKPageFlipper

A simple 3-D page flip transition for iOS devices
Other
408 stars 86 forks source link

Vertical Flipping #17

Open MattNewberry opened 12 years ago

MattNewberry commented 12 years ago

Would be great to see this adjusted to allow for vertical page flipping!

cyupa commented 12 years ago

Indeed :D

shakir1311 commented 12 years ago

I just did that. How do i share that over here????

cyupa commented 12 years ago

I also did that too. You could create a branch from this project and edit it, then upload it with instructions.

yang2012 commented 12 years ago

Would you shared the codes that implement vertical flipping?

Neogene commented 11 years ago

Yes please share it.

shakir1311 commented 11 years ago

// // AFKPageFlipper.h // AFKPageFlipper // // Created by Marco Tabini on 10-10-11. // Copyright 2010 AFK Studio Partnership. All rights reserved. //

import <UIKit/UIKit.h>

import <QuartzCore/QuartzCore.h>

@class AFKPageFlipper;

@protocol AFKPageFlipperDataSource

@end

typedef enum { AFKPageFlipperDirectionTop, AFKPageFlipperDirectionBottom, } AFKPageFlipperDirection;

@interface AFKPageFlipper : UIView { NSObject *dataSource; NSInteger currentPage; NSInteger numberOfPages;

//UIView *currentView;
//UIView *nextView;

CALayer *backgroundAnimationLayer;
CALayer *flipAnimationLayer;

AFKPageFlipperDirection flipDirection;
float startFlipAngle;
float endFlipAngle;
float currentAngle;

BOOL setNextViewOnCompletion;
BOOL animating;

BOOL disabled;

CALayer *shadowLayer;

}

@property (nonatomic,retain) NSObject *dataSource; @property (nonatomic,assign) NSInteger currentPage;

@property (nonatomic, retain) UITapGestureRecognizer tapRecognizer; @property (nonatomic, retain) UIPanGestureRecognizer panRecognizer;

@property (nonatomic,assign) BOOL disabled;

@end

// // AFKPageFlipper.m // AFKPageFlipper // // Created by Marco Tabini on 10-10-12. // Copyright 2010 AFK Studio Partnership. All rights reserved. //

import "AFKPageFlipper.h"

pragma mark -

pragma mark UIView helpers

@interface UIView(Extended)

@end

@implementation UIView(Extended)

@end

pragma mark -

pragma mark Private interface

@interface AFKPageFlipper()

@property (nonatomic,assign) UIView currentView; @property (nonatomic,assign) UIView nextView;

@end

@implementation AFKPageFlipper

@synthesize tapRecognizer = _tapRecognizer; @synthesize panRecognizer = _panRecognizer;

pragma mark -

pragma mark Flip functionality

}

}

pragma mark -

pragma mark Animation management

pragma mark -

pragma mark Properties

@synthesize currentView;

@synthesize nextView;

@synthesize currentPage;

}

@synthesize dataSource;

}

@synthesize disabled;

pragma mark -

pragma mark Touch management

pragma mark -

pragma mark Frame management

}

pragma mark -

pragma mark Initialization and memory management

}

@end

Neogene commented 11 years ago

Doesn't seem to work the vertical page flipper, i've overwritten the two original files but it doesn't work, any suggestion?

ps. thanks for the kindly quick post.

shakir1311 commented 11 years ago

How do i attach the project here?

shakir1311 commented 11 years ago

https://github.com/shakir1311/verticalflipper

adinh3290 commented 11 years ago

thank you. Your program is excellent

KarthickR commented 11 years ago

Thanks a lot for the Vertical flipping code

ravifullestop commented 10 years ago

Vertical flipping code is not smooth. Can you please tell me how i can just reduce the speed of flipping.