Skip to content

Instantly share code, notes, and snippets.

View devshok's full-sized avatar
🏠
Working from home

Ivan devshok

🏠
Working from home
View GitHub Profile
import UIKit.UIScrollView
// MARK: - CONTENT CENTRALIZATION
extension UIScrollView {
/// Call this method on your `UIScrollView` instance
/// when you need to center its content
/// relative to the width and height of the `UIScrollView`.
///
/// The function first attempts to centralize along the Y-axis
// Created by Ivan Shokurov on 8/12/20.
// This a custom slider (by UISlider)
// with two thumbs instead of default one.
import UIKit
//swiftlint:disable:next type_body_length
public final class DoubledSlider: UIControl, ViewProgrammatically {
// MARK: - UI