Latest 1.5.1
Homepage https://github.com/wxxsw/GSImageViewerController
License MIT
Platforms ios 8.0, requires ARC
Authors

Demo

GSImageViewerController

Example

To show normal image viewer controller:

let imageInfo   = GSImageInfo(image: someImage, imageMode: .aspectFit)
let imageViewer = GSImageViewerController(imageInfo: imageInfo)
navigationController?.pushViewController(imageViewer, animated: true)

To show zoom transition image viewer controller:

let imageInfo      = GSImageInfo(image: someImage, imageMode: .aspectFill, imageHD: someHDImageURLOrNil)
let transitionInfo = GSTransitionInfo(fromView: someView)
let imageViewer    = GSImageViewerController(imageInfo: imageInfo, transitionInfo: transitionInfo)
present(imageViewer, animated: true, completion: nil)

Requirements

Master

  • iOS 8.0+
  • Xcode 10 (Swift 4.2)

1.4.2

  • iOS 8.0+
  • Xcode 9 (Swift 4)

1.2.1

  • iOS 8.0+
  • Xcode 8 (Swift 3)

1.1.1

  • iOS 7.0+
  • Xcode 7 (Swift 2)

Installation

CocoaPods:

In your Podfile:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
use_frameworks!

pod "GSImageViewerController"

And in your *.swift:

import GSImageViewerController

License

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

Latest podspec

{
    "name": "GSImageViewerController",
    "version": "1.5.1",
    "summary": "A image viewer controller with zoom transition, in Swift.",
    "homepage": "https://github.com/wxxsw/GSImageViewerController",
    "license": "MIT",
    "authors": {
        "GeSen": "[email protected]"
    },
    "source": {
        "git": "https://github.com/wxxsw/GSImageViewerController.git",
        "tag": "1.5.1"
    },
    "platforms": {
        "ios": "8.0"
    },
    "requires_arc": true,
    "source_files": "GSImageViewerController",
    "swift_version": "4.2"
}

Pin It on Pinterest

Share This