private static IsFirstLastItemInGroup ( System.Windows.Forms.ListViewGroup g, System.Windows.Forms.ListViewItem lvi, bool bFirst ) : bool | ||
g | System.Windows.Forms.ListViewGroup | |
lvi | System.Windows.Forms.ListViewItem | |
bFirst | bool | |
return | bool |
private static bool IsFirstLastItemInGroup(ListViewGroup g,
ListViewItem lvi, bool bFirst)
{
if(g == null) { Debug.Assert(false); return false; }
ListViewItemCollection c = g.Items;
if(c.Count == 0) { Debug.Assert(false); return false; }
return (bFirst ? (c[0] == lvi) : (c[c.Count - 1] == lvi));
}