I want to use MonoTouch.Dialog RadioElements for selecting data and it has to have a UIImageView for the TableView BackgroundViews.
I can set the BackgroundView on the initial DialogViewController's TableView so no problem there, but the TableView's generated for each RadioGroup has the default grey background image and I can't seem to find a way to change them to the same background style as the initial TableView.
Is it possible to change the generated TableView's BackgroundView (the TableView's generated for each RadioGroup) without having to go and modify the MonoTouch.Dialog source?
Thanks in advance.
AFAIK you'll need to create your own Element. But the good news is that's pretty easy to do, e.g.:
public class TransparentRootElement : RootElement {
// add required .ctors
public override UITableViewCell GetCell (UITableView tv)
{
var cell = base.GetCell (tv);
cell.BackgroundColor = UIColor.Clear;
return cell;
}
}
Then you only have to use this new TransparentRootElement type where you create the RadioGroup.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With