mirror of
https://github.com/ReactiveX/RxSwift.git
synced 2024-10-05 06:27:29 +03:00
25 lines
450 B
Swift
25 lines
450 B
Swift
//
|
|
// UIImageView+Rx.swift
|
|
// RxCocoa
|
|
//
|
|
// Created by Krunoslav Zaher on 4/1/15.
|
|
// Copyright © 2015 Krunoslav Zaher. All rights reserved.
|
|
//
|
|
|
|
#if os(iOS) || os(tvOS)
|
|
|
|
import RxSwift
|
|
import UIKit
|
|
|
|
extension Reactive where Base: UIImageView {
|
|
|
|
/// Bindable sink for `image` property.
|
|
public var image: Binder<UIImage?> {
|
|
return Binder(base) { imageView, image in
|
|
imageView.image = image
|
|
}
|
|
}
|
|
}
|
|
|
|
#endif
|