gme_2
6 years ago
4 changed files with 123 additions and 15 deletions
-
12GMERemittance.xcodeproj/project.pbxproj
-
40GMERemittance/Module/SendMoneyPaymentMode/User Interface/View/Cells/SendMoenyPaymentModeCollectionViewCell.swift
-
21GMERemittance/Module/SendMoneyPaymentMode/User Interface/View/SendMoneyPaymentMode.storyboard
-
65GMERemittance/Module/SendMoneyPaymentMode/User Interface/View/SendMoneyPaymentModeViewController.swift
@ -0,0 +1,40 @@ |
|||
// |
|||
// SendMoenyPaymentModeCollectionViewCell.swift |
|||
// GMERemittance |
|||
// |
|||
// Created by gme_2 on 28/08/2018. |
|||
// Copyright © 2018 Gobal Money Express Co. Ltd. All rights reserved. |
|||
// |
|||
|
|||
import UIKit |
|||
|
|||
class SendMoenyPaymentModeCollectionViewCell: UICollectionViewCell { |
|||
@IBOutlet weak var cellBackgroundview: UIView! |
|||
@IBOutlet weak var imageview: UIImageView! |
|||
@IBOutlet weak var paymentLabel: UILabel! |
|||
|
|||
var cellSelected = false |
|||
var image: UIImage? |
|||
|
|||
var paymentServiceMethod: SendMoneyPayoutMode? |
|||
|
|||
func setup() { |
|||
self.imageview.image = image |
|||
self.paymentLabel.text = paymentServiceMethod?.mode |
|||
|
|||
self.cellBackgroundview.layer.cornerRadius = 5 |
|||
self.paymentLabel.text = self.paymentServiceMethod?.mode |
|||
cellSelected ? showBorderColor() : hideBorderColor() |
|||
|
|||
} |
|||
|
|||
private func showBorderColor() { |
|||
self.cellBackgroundview.layer.borderWidth = 1 |
|||
self.cellBackgroundview.layer.borderColor = UIColor.red.cgColor |
|||
} |
|||
|
|||
private func hideBorderColor() { |
|||
cellBackgroundview.layer.borderWidth = 0 |
|||
cellBackgroundview.layer.borderColor = UIColor.clear.cgColor |
|||
} |
|||
} |
Write
Preview
Loading…
Cancel
Save
Reference in new issue