Skip to content
This repository has been archived by the owner on Mar 31, 2020. It is now read-only.

Commit

Permalink
Update for Xcode 6.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
soffes committed Dec 5, 2014
1 parent 54b777e commit ca01201
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Coins/Classes/CurrencyPickerTableViewController.swift
Expand Up @@ -73,7 +73,7 @@ class CurrencyPickerTableViewController: UITableViewController {

let key = order[indexPath.row]

cell.textLabel.text = currencies[key]
cell.textLabel?.text = currencies[key]
cell.detailTextLabel?.text = key

return cell
Expand Down
16 changes: 9 additions & 7 deletions Coins/Classes/TableViewCell.swift
Expand Up @@ -16,10 +16,10 @@ class TableViewCell: UITableViewCell {
override init(style: UITableViewCellStyle, reuseIdentifier: String?) {
super.init(style: .Value1, reuseIdentifier: reuseIdentifier)

textLabel.font = UIFont(name: "Avenir-Heavy", size: 18)
textLabel.textColor = UIColor(white: 0.4, alpha: 1)
textLabel.highlightedTextColor = UIColor.whiteColor()
textLabel.adjustsFontSizeToFitWidth = true
textLabel?.font = UIFont(name: "Avenir-Heavy", size: 18)
textLabel?.textColor = UIColor(white: 0.4, alpha: 1)
textLabel?.highlightedTextColor = UIColor.whiteColor()
textLabel?.adjustsFontSizeToFitWidth = true

if let detailTextLabel = detailTextLabel {
detailTextLabel.font = UIFont(name: "Avenir-Book", size: 18)
Expand Down Expand Up @@ -48,9 +48,11 @@ class TableViewCell: UITableViewCell {
override func layoutSubviews() {
super.layoutSubviews()

var rect = textLabel.frame
rect.size.width = min(rect.size.width, 240)
textLabel.frame = rect
if let textLabel = textLabel {
var rect = textLabel.frame
rect.size.width = min(rect.size.width, 240)
textLabel.frame = rect
}

if let detailTextLabel = detailTextLabel {
let size = contentView.bounds.size
Expand Down

0 comments on commit ca01201

Please sign in to comment.