/DKImagePickerController

This is a very simple Image Picker Controller by Swift.

Primary LanguageSwift

DKImagePickerController

Update for Xcode 6.3 with Swift 1.2

Description

This is a very simple Image Picker Controller by Swift.
AssetsLibrary.framework is required.

Use

Initialization and presentation

let pickerController = DKImagePickerController()
pickerController.pickerDelegate = self
self.presentViewController(pickerController, animated: true) {}

Delegate methods

func imagePickerControllerCancelled() {
    self.dismissViewControllerAnimated(true, completion: nil)
}

func imagePickerControllerDidSelectedAssets(assets: [DKAsset]!) {
    for (index, asset) in enumerate(assets) {
        
    }
    
    self.dismissViewControllerAnimated(true, completion: nil)
}

Configurable properties

/// The height of the bottom of the preview
var previewHeight: CGFloat = 80

var rightButtonTitle: String = "确定"

/// Displayed when denied access
var noAccessView: UIView

Screenshots

---

---

---