cannyboy cannyboy - 1 year ago 102
Objective-C Question

Can a standard accessory view be in a different position within a uitableviewcell?

I want my accessory to be in a slightly different place than normal. Is it possible?
This code has no effect:

cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
cell.accessoryView.frame = CGRectMake(5.0, 5.0, 5.0, 5.0);

Answer Source

No, you cannot move where the accessory view is. As an alternative you can add a subview like the following;

[cell.contentView addSubview:aView];

Also, by setting the accessoryView property equal to something, the accessoryType value is ignored.