• Stars
    star
    117
  • Rank 301,828 (Top 6 %)
  • Language
    Objective-C
  • Created almost 13 years ago
  • Updated over 9 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Pull-to-Refresh behavior at the bottom of a UITableView

MNMBottomPullToRefresh is a solution to add pull-to-refresh feature to the bottom of an UITableView instead of the top, as usual. This view can be used to retrieve more values, or pages, of a large list.

This solution has its basis on the Mediator design pattern (http://en.wikipedia.org/wiki/Mediator_pattern). MNMBottomPullToRefreshManager acts as a Mediator between the pull-to-refresh view and its container table view, decoupling the view and the scroll management.

In order to maintain this decoupling, there is no UITableView subclass, allowing developers to add this behavior as an aggregate of its own subclasses of UITableView without creating an intermediate class or adding directly in the UIViewController that manages table delegate and data source.

Installation instructions:

  1. Copy the whole MNMBottomPullToRefresh folder into your project

  2. In your UIViewController class, create a MNMBottomPullToRefreshManager to link an UITableView and the MNMPullToRefreshView. Use a sentence like this:

    pullToRefreshManager_ = [[MNMBottomPullToRefreshManager alloc] initWithPullToRefreshViewHeight:60.0f
                                                                                         tableView:table_
                                                                                        withClient:self];
    
  3. Implement MNMBottomPullToRefreshManagerClient selectors on your UIViewController in order to inform to delegate about the correct offset of the table

  4. You can see a this usage in MNMBPTRViewController

Documentation

  1. Execute appledoc appledoc.plist in the root of the project path to generate documentation.

License

Copyright (c) 2012 Mario Negro.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

More Repositories

1

xib-localization

Example project for easy XIB and Storyboard localization (check out blog post)
Swift
43
star
2

pull-to-refresh

Solution to add pull-to-refresh feature at the top of an UITableView.
Objective-C
42
star
3

alert-blocks

Category of UIAlertView that offers a completion handler to listen to interaction. This avoids the need of the implementation of the delegate pattern.
Objective-C
37
star
4

simple-vc-state

A simple state machine to show different view controllers (check out blog post)
Swift
27
star
5

action-sheet-blocks

Category of UIActionSheet that offers a completion handler to listen to interaction. This avoids the need of the implementation of the delegate pattern.
Objective-C
25
star
6

remote-imageview

Replacement for UIImageView that asynchronously shows an image downloaded from an URL. While the download is running an activity indicator is shown over the view. A block is invoked when the image has finishing download.
Objective-C
21
star
7

progress-bar

Custom progress bar with determinate and indeterminate progress
Objective-C
18
star
8

space-cells-ios

Exercising collection view loading, configuration and interaction on iOS VIPER architecture.
Swift
13
star
9

enum2switch

OS X action to generate a switch case from a given C/Objective-C enumeration.
Objective-C
3
star
10

rx-bookshelf

Simple bookshelf project to learn RxSwift
Swift
2
star
11

bitrise-step-product-bundle-identifier

Bitrise step to replace Xcode project PRODUCT_BUNDLE_IDENTIFIER setting.
Shell
1
star
12

retinator

Retinator resizes the source image and generates three images in 1x, 2x and 3x iOS resolutions.
Ruby
1
star
13

bookshelf-server

Example app to learn Node.js and MongoDB. A very simple REST API to manage a bookshelf.
JavaScript
1
star
14

tictactoe

A simple Tic-Tac-Toe CLI game as an exercise to learn Ruby language
Ruby
1
star