Skip to content
SAHistoryNavigationViewController realizes iOS task manager like UI in UINavigationContoller. Support 3D Touch!
Swift Shell Ruby Objective-C
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
SAHistoryNavigationViewControllerSample Added support for landscape orientation Mar 31, 2017
SampleImage fix warning did pop end Nov 13, 2015
.swift-version support swift3 Sep 20, 2016
LICENSE Initial commit Mar 26, 2015


Platform Language Version License

Support 3D Touch for iOS9!!

SAHistoryNavigationViewController realizes iOS task manager like UI in UINavigationContoller. referred.


  • iOS task manager like UI
  • Launch Navigation History with Long tap action of Back Bar Button
  • Support Swift2.0
  • Support 3D Touch (If device is not supported 3D Touch, automatically replacing to long tap gesture.)
  • Support Swift2.3
  • Sipport Swift3



SAHistoryNavigationViewController is available through CocoaPods. If you have cocoapods 0.38.0 or greater, you can install it, simply add the following line to your Podfile:

pod "SAHistoryNavigationViewController"


Add the SAHistoryNavigationViewController directory to your project.


If you install from cocoapods, You have to write import SAHistoryNavigationViewController.

Storyboard or Xib

Set custom class of UINavigationController to SAHistoryNavigationViewController. In addition, set module to SAHistoryNavigationViewController.


You can use SAHistoryNavigationViewController as self.sah.navigationController in any ViewController, bacause implemented extension SAHistoryExtension as below codes.

public protocol SAHistoryCompatible {
    associatedtype CompatibleType
    var sah: CompatibleType { get }

public extension SAHistoryCompatible {
    public var sah: SAHistoryExtension<Self> {
        return SAHistoryExtension(self)

public final class SAHistoryExtension<Base> {
    public let base: Base
    public init(_ base: Base) {
        self.base = base

extension UIViewController: SAHistoryCompatible {}

extension SAHistoryExtension where Base: UIViewController {
    public var navigationController: SAHistoryNavigationViewController? {
        return base.navigationController as? SAHistoryNavigationViewController

And you have to initialize like this.

let ViewController = UIViewController()
let navigationController = SAHistoryNavigationViewController()
navigationController.setViewControllers([ViewController], animated: true)
presentViewController(navigationController, animated: true, completion: nil)

If you want to launch Navigation History without long tap action, use this code.

//In any UIViewController


If you want to customize background of Navigation History, you can use those methods.

//In any UIViewController

This is delegate methods.

@objc public protocol SAHistoryNavigationViewControllerDelegate: NSObjectProtocol {
    optional func historyControllerDidShowHistory(controller: SAHistoryNavigationViewController, viewController: UIViewController)



Taiki Suzuki,


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

You can’t perform that action at this time.