Skip to content
项目

matej/MBPullDownController

在 GitHub 查看

关于

MBPullDownController 是一个 iOS 容器视图控制器,用于实现可下拉滚动视图界面。

网站与应用开发

这些数字如何统计

实测星标增长

24小时
0
7天
0
15天
0
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

MBPullDownController Build Status

MBPullDownController accepts two view controllers, which it presents one above the other. The front view controller is configured to accept a pull interaction which it utilizes to show or hide back view controller.

Requirements

MBPullDownController requires iOS 5 or newer and uses ARC. It depends on the following Apple frameworks:

  • Foundation.framework
  • UIKit.framework
  • QuartzCore.framework

You will need LLVM 3.0 or later in order to build MBPullDownController.

Adding MBPullDownController to your project

CocoaPods

CocoaPods is the recommended way to add MBPullDownController to your project.

  1. Add a pod entry for MBPullDownController to your Podfile pod 'MBPullDownController', '~> 1.0'
  2. Install the pod(s) by running pod install.
  3. Include MBPullDownController wherever you need it with #import "MBPullDownController.h".

Source files

Alternatively you can directly add the MBPullDownController.h and MBPullDownController.m source files to your project.

  1. Download the latest code version or add the repository as a git submodule to your git-tracked project.
  2. Open your project in Xcode, than drag and drop MBPullDownController.h and MBPullDownController.m from the MBPullDownController directory onto your project (use the "Product Navigator view"). Make sure to select Copy items when asked if you extracted the code archive outside of your project.
  3. Include MBPullDownController wherever you need it with #import "MBPullDownController.h".

Static library

You can also add MBPullDownController as a static library to your project or workspace.

  1. Download the latest code version or add the repository as a git submodule to your git-tracked project.
  2. Open your project in Xcode, than drag and drop MBPullDownController.xcodeproj onto your project or workspace (use the "Product Navigator view").
  3. Select your target and go to the Build phases tab. In the Link Binary With Libraries section select the add button. On the sheet find and add libMBPullDownController.a. You might also need to add MBPullDownController to the Target Dependencies list.
  4. Include MBPullDownController wherever you need it with #import <MBPullDownController/MBPullDownController.h>.

Usage

Initialize a MBPullDownController with a front and back view controller, than add the controller to your controller hierarchy.

UITableViewController *front = [[UITableViewController new];
UIViewController *back = [[UIViewController new];
MBPullDownController *pullDownController = [[MBPullDownController alloc] initWithFrontController:front backController:back];
[self.navigationController pushViewController:pullDownController animated:NO];

The front controller's view must be a UIScrollView subclass. See the demo application for further details and check out MBPullDownController.h for API options.

License

This code is distributed under the terms and conditions of the MIT license.

探索相关项目

加载中…