ios - How to update background for minus sign while UITableView in editing mode? -


this question has answer here:

when use edit mode uitableview, adds minus sign buttons in front of each row.

also indents rows automatically right side.

as can see in below image, there white space background grey cell.

enter image description here

how add greyed background default minus sign button?

start gray view @ negative x-origin. around x = -40 points or so.

i use 2 autolayoutconstraints in 1 of cells.

nslayoutconstraint *c = [nslayoutconstraint constraintwithitem:colorview attribute:nslayoutattributeleft relatedby:nslayoutrelationequal toitem:self.contentview attribute:nslayoutattributeleft multiplier:1 constant:-40];  [colorview addconstraint:[nslayoutconstraint constraintwithitem:colorview attribute:nslayoutattributewidth relatedby:nslayoutrelationequal toitem:nil attribute:nslayoutattributenotanattribute multiplier:1 constant:49]]; 

which looks this:

enter image description here

if make green view wider , grey it'll want ^^


Comments