This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// SOTControlBar.swift | |
// ControlBar | |
// | |
// Created by Andrea Altea on 27/06/17. | |
// Copyright © 2017 StudiOUT. All rights reserved. | |
// | |
import UIKit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// TabViewContainer.swift | |
// BusMap | |
// | |
// Created by Andrea Altea on 24/05/17. | |
// Copyright © 2017 StudiOUT. All rights reserved. | |
// | |
import UIKit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// TouchLayerView.swift | |
// | |
// | |
// Created by Oni_01 on 04/01/15. | |
// Copyright (c) 2015 Andrea Altea. All rights reserved. | |
// | |
import UIKit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// SOTBubbleLabel.swift | |
// | |
// | |
// Created by Andrea Altea on 18/08/17. | |
// Copyright 2017 Andrea Altea. All rights reserved. | |
// | |
import UIKit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// RequestManager.swift | |
// | |
// | |
// Created by Andrea Altea on 05/11/17. | |
// Copyright © 2017 Studiout. All rights reserved. | |
// | |
import Foundation | |
struct RequestManagerConfiguration { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// ZoomCardFlowLayout.swift | |
// | |
// | |
// Created by Oni_01 on 12/05/15. | |
// Copyright (c) 2015 Andrea Altea. All rights reserved. | |
// | |
import UIKit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class StandardCell: UICollectionViewCell { | |
var titleLabel: UILabel! | |
} | |
class StandardDataSource: NSObject, UICollectionViewDataSource { | |
var firstSectionItems: [String] = ["first", "second", "third"] | |
var secondSectionItems: [String] = ["FIRST", "SECOND", "THIRD"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protocol ItemViewModel { | |
var reuseIdentifier: String { get } | |
func setup(_ cell: UICollectionReusableView, in collectionView: UICollectionView, at indexPath: IndexPath) | |
} | |
protocol SectionViewModel { | |
var headerItem: ItemViewModel? { get } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MVVMCollectionViewDataSource: NSObject, UICollectionViewDataSource { | |
var model: [SectionViewModel] = [] | |
func numberOfSections(in collectionView: UICollectionView) -> Int { | |
return self.model.count | |
} | |
func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { | |
return self.model[section].items.count |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct StandardCellViewModel: ItemViewModel { | |
let title: String | |
var reuseIdentifier: String { | |
return "cell" | |
} | |
func setup(_ cell: UICollectionReusableView, in collectionView: UICollectionView, at indexPath: IndexPath) { | |
guard let cell = cell as? StandardCell else { |
OlderNewer