Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

house keeping

  • Loading branch information...
commit 9f31bc78474fda9f9d7ce82852a4a7c699eab5ed 1 parent 239f0d6
Kevin McMahon authored
View
21 MonoDroid.Dialog/CheckboxElement.cs
@@ -1,13 +1,14 @@
using Android.Content;
using Android.Views;
+using Android.Widget;
namespace MonoDroid.Dialog
{
public class CheckboxElement : Element
{
private readonly Context _context;
-
- public new bool Value;
+ private CheckBox _cb;
+ public bool Value;
public string Group;
public CheckboxElement(Context context, string caption)
@@ -28,24 +29,16 @@ public CheckboxElement(Context context, string caption, bool value, string group
Group = group;
}
- View ConfigCell(View cell)
- {
- //cell.Accessory = Value ? UITableViewCellAccessory.Checkmark : UITableViewCellAccessory.None;
- return cell;
- }
-
public override View GetView()
{
- return ConfigCell(base.GetView());
+ _cb = new CheckBox(_context) {Checked = Value, Text = Caption};
+ return _cb;
}
public override void Selected()
{
- //Value = !Value;
- //var cell = tableView.CellAt(path);
- //ConfigCell(cell);
- //base.Selected(dvc, tableView, path);
- base.Selected();
+ Value = !Value;
+ _cb.Checked = Value;
}
}
}
View
3  MonoDroid.Dialog/RootElement.cs
@@ -205,9 +205,6 @@ public void Add(IEnumerable<Section> sections)
/// <param name="idx">
/// The index where the section is added <see cref="System.Int32"/>
/// </param>
- /// <param name="anim">
- /// The <see cref="UITableViewRowAnimation"/> type.
- /// </param>
/// <param name="newSections">
/// A <see cref="Section[]"/> list of sections to insert
/// </param>
Please sign in to comment.
Something went wrong with that request. Please try again.