I am creating a table view with custom cells.
Each cell has three buttons. I've added a view that overlaps three buttons, from the cell to the width and height. I'm using it to create a swipeable cell.
Works as an overlay This view is white background and opaque, but to test the app on the simulator, I have found that when the cell is tapped, the buttons are shown lightly, So please picture.
What should I look up to Why to avoid the buttons for now why this happens now if the overlay scene is set as opaque, the second issue is that if the tap on the cell, the left red bar, a view also disappears ...
Thank you.
I believe this is the one of the default selection styles of UITableViewCell
The result is let's try to delete the default style and customize it.
Try the setting (depending on your implementation):
-
cell.selectionStyle = UITableViewCellSelectionStyleNone;
cellForRowAtIndexPath
or -
in the Custom subclass of Cells inside
SelectionStyle = UITableViewCellSelectionStyleNone; Inside a custom selection style can apply. Within your initialization method, add something like:
Self. Selected background view = [[UIView alloc] initWithFrame: self.bounds]; Self.selectedBackgroundView.backgroundColor = [UIColor lightGrayColor];
No comments:
Post a Comment