MTCoordinatorView

The view coordinate arranged to the scrolling is adjusted.


License
MIT
Install
pod try MTCoordinatorView

Documentation

MTCoordinatorView

Code Version License Platform

img_gif

Introduction

The view coordinate arranged to the scrolling is adjusted.

Usage

// ViewController

import MTCoordinatorView

class ViewController: UIViewController {

    fileprivate var coordinateManager: MTCoordinateManager?

    override func viewDidLoad() {
        super.viewDidLoad()

        ・・・ 'TableView' and 'Custom Header' are made beforehand. ・・・

        // set header view
        coordinateManager = MTCoordinateManager.init(vc: self, scrollView: tableView, header: headerView)

        // create view
        let childView = UIView.init(frame: CGRectMake(100, 100, 0, 0))
        let coordinateContainer = MTCoordinateContainer.init(view: childView, endForm: CGRect(100, 100, 50, 50), mode: .FIXITY, completion: {
            // tap event callback.
        })

        // set views...
        coordinateManager?.setContainer(tableView, views: coordinateContainer)

        self.view.addSubview(tableView)
    }

    func scrollViewDidScroll(scrollView: UIScrollView) {
        guard let manager = coordinateManager else {
            return
        }
        manager.scrolledDetection(scrollView)
    }

Installation

pod 'MTCoordinatorView'

Requirements

  • 0.8.0

    • iOS 8.0+
    • Xcode 8.0+
    • Swift 2.3
  • 0.8.1

    • iOS 8.0+
    • Xcode 8.1+
    • Swift 3.0

See Also

License

MTCoordinatorView-objc is available under the MIT license. See the LICENSE file for more info.