本文整理汇总了C#中UITableViewCell.StyleAsSettingsTableCell方法的典型用法代码示例。如果您正苦于以下问题:C# UITableViewCell.StyleAsSettingsTableCell方法的具体用法?C# UITableViewCell.StyleAsSettingsTableCell怎么用?C# UITableViewCell.StyleAsSettingsTableCell使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UITableViewCell
的用法示例。
在下文中一共展示了UITableViewCell.StyleAsSettingsTableCell方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GetCell
public override UITableViewCell GetCell (UITableView tableView, NSIndexPath indexPath)
{
if (indexPath.Section == 0)
return base.GetCell(tableView, indexPath);
var cell = new UITableViewCell(UITableViewCellStyle.Default, string.Format("RadioButtonTableCell{0}{1}", indexPath.Section, indexPath.Row)) {
AccessoryView = null
};
if (IsNumberOfCommitters(indexPath.Section))
{
if (indexPath.Row == countSelected)
cell.AccessoryView = RadioGroupTableViewSource.BlackAccessoryCheckmark();
cell.TextLabel.Text = string.Format("Top {0} committers", countValues[indexPath.Row]);
countCells.Insert(indexPath.Row, cell);
}
if (IsTimePeriod(indexPath.Section))
{
if (indexPath.Row == timeSelected)
cell.AccessoryView = RadioGroupTableViewSource.BlackAccessoryCheckmark();
cell.TextLabel.Text = string.Format("Past {0}", timeValues[indexPath.Row].ToSuffix());
timeCells.Insert(indexPath.Row, cell);
}
cell.StyleAsSettingsTableCell();
return cell;
}
示例2: GetCell
public override UITableViewCell GetCell (UITableView tableView, NSIndexPath indexPath)
{
int section = indexPath.Section;
int row = indexPath.Row;
if (section == 0)
return base.GetCell(tableView, indexPath);
if (row == 0)
{
topSwitch = new DarkSwitch(model.BrokenBuildsAtTop);
topSwitch.ValueChanged += delegate {
model.BrokenBuildsAtTop = topSwitch.On;
};
var cell = new UITableViewCell(UITableViewCellStyle.Default, "SimpleCheckboxCell") {
AccessoryView = topSwitch,
};
cell.TextLabel.Text = "Broken builds first";
cell.StyleAsSettingsTableCell();
cell.SelectionStyle = UITableViewCellSelectionStyle.None;
return cell;
}
else
{
var cell = new UITableViewCell(UITableViewCellStyle.Default, "SubtitleDisclosureCell");
cell.AccessoryView = new DisclosureIndicatorView();
cell.TextLabel.Text = "Build order";
// TODO: Gray text to the right of what is currently selected
cell.StyleAsSettingsTableCell();
return cell;
}
}
示例3: GetCell
public override UITableViewCell GetCell(UITableView tableView, NSIndexPath indexPath)
{
darkSwitch = new DarkSwitch(widgetModel.Enabled);
darkSwitch.ValueChanged += delegate {
widgetModel.Enabled = darkSwitch.On;
};
var cell = new UITableViewCell(UITableViewCellStyle.Default, "EnableWidgetUISwitch") {
AccessoryView = darkSwitch,
};
cell.TextLabel.Text = "Enabled";
cell.StyleAsSettingsTableCell();
cell.SelectionStyle = UITableViewCellSelectionStyle.None;
return cell;
}
示例4: GetCell
public override UITableViewCell GetCell(UITableView tableView, NSIndexPath indexPath)
{
if (indexPath.Section == 0)
return base.GetCell(tableView, indexPath);
emptySwitch = new DarkSwitch(model.HighlightEmpty);
emptySwitch.ValueChanged += delegate {
model.HighlightEmpty = emptySwitch.On;
};
var cell = new UITableViewCell(UITableViewCellStyle.Default, "SimpleCheckboxCell") {
AccessoryView = emptySwitch,
SelectionStyle = UITableViewCellSelectionStyle.None
};
cell.TextLabel.Text = "Highlight empty commits";
cell.StyleAsSettingsTableCell();
cell.SelectionStyle = UITableViewCellSelectionStyle.None;
return cell;
}