Created
May 2, 2016 19:20
-
-
Save decoyfox/e3342a2fd234508f8ef5ac57cd110cec to your computer and use it in GitHub Desktop.
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
//the user is searching for an ITEM | |
let title = returnedItemArray[indexPath.row]["title"] as! String | |
let description = returnedItemArray[indexPath.row]["description"] as! String | |
myCell.topLabel.text = title | |
myCell.bottomLabel.text = description | |
let downloadedItemThumbnailImage = returnedItemArray[indexPath.row]["thumbnailImage"] as! PFFile | |
downloadedItemThumbnailImage.getDataInBackgroundWithBlock({ (data, error) in | |
if let theImage = UIImage(data: data!) { | |
dispatch_async(dispatch_get_main_queue(),{ | |
myCell.imageView?.image = theImage | |
myCell.imageView!.layer.cornerRadius = 30 | |
//myCell.imageView!.clipsToBounds = true | |
myCell.imageView!.layer.masksToBounds = true | |
myCell.setNeedsLayout() | |
}) | |
} | |
}) | |
} | |
return myCell |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment