Skip to content

Tumblr iOS app like menu view completely created using core animation.

License

Notifications You must be signed in to change notification settings

darcy1992/XHTumblrMenu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

image

XHTumblrMenu

Tumblr iOS app like menu view.

Completely created using core animation.

Easy to drop into your project.

You can add as many items as you want, the XHTumblrMenu will layout them automatically.

Requirements

XHTumblrMenu requires Xcode 5, targeting either iOS 5.0 and above, ARC-enabled.

Installation

CocoaPods is the recommended method of installing XHTumblrMenu, just add the following line to your Podfile:

Podfile

pod 'XHTumblrMenu'

How to use

Drag XHTumblrMenu.h amd XHTumblrMenu.m files to your project.

No other frameworks required.

#import "XHTumblrMenu.h"

XHTumblrMenu *tumblrMenu = [[XHTumblrMenu alloc] init];
for (int i = 0; i < 6; i ++) {
   XHTumblrMenuItem *tumblrMenuItem = [[XHTumblrMenuItem alloc] init];
   tumblrMenuItem.title = [NSString stringWithFormat:@"Title%d", i];
   tumblrMenuItem.iconImage = [UIImage imageNamed:[NSString stringWithFormat:@"Title%d.png", i]];
   tumblrMenuItem.tumblrMenuViewSelectedBlock = ^(XHTumblrMenu *tumblrMenu, XHTumblrMenuItem *tumblrMenuItem) {
            NSLog(@"title : %@   index : %d", tumblrMenuItem.title, tumblrMenuItem.index);
   };
   [tumblrMenu addMenuItemWithTumblrMenuItem:tumblrMenuItem];
}

[tumblrMenu show];

public Api

// background
@property (nonatomic, strong) UIImageView *backgroundImgView;

// show property
@property (nonatomic, assign) NSTimeInterval tumblrMenuViewShowItemAnimationTime; // default is 0.37

// dissMiss
@property (nonatomic, assign) XHTumblrMenuDissmissAnimationType dissmissAnimationType; // default is kXHFade
@property (nonatomic, assign) NSTimeInterval dissMissDuration; // default is 0.1;

Lincense

XHTumblrMenu is available under the MIT license. See the LICENSE file for more info.

About

Tumblr iOS app like menu view completely created using core animation.

Resources

License

Stars

Watchers

Forks

Packages

No packages published