Sha256: f76c209bef2f5be2be08bc67197dcc0c0e5471c6ac3f8037d6818df8021de6b7
Contents?: true
Size: 663 Bytes
Versions: 7
Compression:
Stored size: 663 Bytes
Contents
class TagsViewController < UITableViewController attr_accessor :color def initWithColor(color) self.color = color self.title = "Tags for color #{color.hex}" init end def tableView(tableView, numberOfRowsInSection:section) self.color.tags.size end def tableView(tableView, cellForRowAtIndexPath:indexPath) cell = tableView.dequeueReusableCellWithIdentifier('Cell') cell ||= UITableViewCell.alloc.initWithStyle(UITableViewCellStyleSubtitle, reuseIdentifier:'Cell') tag = color.tags[indexPath.row] cell.textLabel.text = tag.name cell.selectionStyle = UITableViewCellSelectionStyleNone cell end end
Version data entries
7 entries across 7 versions & 1 rubygems