UITableViewCellの背景を透過する、あるいは消す方法。
UITableViewCellのbackgroundViewに新しい空のUIViewを設定し、選択された時の色をなくせばいい。
static NSString *CellIdentifier = @"Cell";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
[cell setBackgroundView:[[[UIView alloc] init] autorelease]];
[cell setSelectionStyle:UITableViewCellSelectionStyleNone];
}
return cell;
よく使うのにどうやってやるのか不安げになりがちなのでメモ。
