protected override object OnGetCustomItem(ICustomItem item, iLayer layer, IListView view, object recycledCell) { var cell = GetNativeObject <FrameworkElement>(Converter.ConvertToCell(item, layer.LayerStyle, view, null), "item", true); if (CustomItemRequested != null) { return(CustomItemRequested(item, layer)); } return(cell); }
protected override object OnGetCustomItem(ICustomItem item, iLayer layer, IListView view, object recycledCell) { if (CustomItemRequested == null) { return(base.OnGetCustomItem(item, layer, view, recycledCell)); } var custom = recycledCell as CustomItemContainer; return(CustomItemRequested(item, custom?.CustomItem as View, layer)); }
protected override object OnGetCustomItem(ICustomItem item, iLayer layer, IListView view, object recycledCell) { var controller = GetNativeObject <UIViewController>(view, "view") as UITableViewController; var cell = GetNativeObject <UITableViewCell>(Converter.ConvertToCell(item, layer.LayerStyle, view, null), "item"); if (CustomItemRequested != null) { return(CustomItemRequested(item, cell, controller == null ? null : controller.TableView)); } return(cell); }
protected override object OnGetCustomItem(ICustomItem item, iLayer layer, IListView view, object recycledCell) { var ci = GetCustomItem; if (ci != null) { return(ci(item, layer, view, recycledCell as Control)); } #pragma warning disable 618 var cir = CustomItemRequested; return(cir == null ? null : cir(item, layer.LayerStyle)); #pragma warning restore 618 }
/// <summary> /// Removes the first occurrence of a specific <see cref="Condition"/> from the filter. /// </summary> /// <param name="item"></param> public void Remove(ICustomItem <Filter> item) { Items.Remove(item); }
/// <summary> /// Adds a <see cref="ICustomItem{T}"/> to the end of the filter. /// </summary> /// <param name="item"></param> public void Add(ICustomItem <Filter> item) { Items.Add(item); }
/// <summary> /// Removes the first occurrence of a specific object from the target. /// </summary> /// <param name="item"></param> public void Remove(ICustomItem <Target> item) { Items.Remove(item); }
/// <summary> /// Adds a object to the end of the target. /// </summary> /// <param name="item"></param> public void Add(ICustomItem <Target> item) { Items.Add(item); }
/// <summary> /// Adds a <see cref="ICustomItem{T}"/> to the end of the filter. /// </summary> /// <param name="item"></param> public Filter Add(ICustomItem <Filter> item) { Items.Add(item); return(this); }
/// <summary> /// Removes the first occurrence of a specific <see cref="Condition"/> from the filter. /// </summary> /// <param name="item"></param> public Filter Remove(ICustomItem <Filter> item) { Items.Remove(item); return(this); }
/// <summary> /// Called when an <see cref="ICustomItem"/> instance is ready to be rendered and a native object is needed for insertion into the view. /// </summary> /// <param name="item">The item that is ready to be rendered.</param> /// <param name="layer">The layer instance associated with the item, or <c>null</c> if the item is not associated with a layer.</param> /// <param name="view">The view that will contain the item.</param> /// <param name="recycledCell">An already instantiated cell that is ready for reuse, or <c>null</c> if no cell has been recycled.</param> /// <returns>The object that will be inserted into the view.</returns> protected internal virtual object OnGetCustomItem(ICustomItem item, iLayer layer, IListView view, object recycledCell) { return(Converter.ConvertToCell(item, layer.LayerStyle, view, recycledCell as ICell)); }
/// <summary> /// Removes the first occurrence of a specific object from the target. /// </summary> /// <param name="item"></param> public Target Remove(ICustomItem <Target> item) { Items.Remove(item); return(this); }
/// <summary> /// Adds a object to the end of the target. /// </summary> /// <param name="item"></param> public Target Add(ICustomItem <Target> item) { Items.Add(item); return(this); }