Example #1
0
        public void RemoveTo(BreadcrumbControl item)
        {
            var index = Breadcrumbs.IndexOf(item);

            while (Breadcrumbs.Count > index + 1)
            {
                Breadcrumbs.RemoveAt(index + 1);
            }
        }
Example #2
0
        private void RemoveParentOf(BreadcrumbControl breadcrumb)
        {
            var index = Breadcrumbs.IndexOf(breadcrumb);

            if (index > 0)
            {
                Breadcrumbs.RemoveAt(index - 1);
            }
        }
Example #3
0
        private int GetInsertPosition(BreadcrumbControl breadcrumb)
        {
            var index = Breadcrumbs.IndexOf(breadcrumb);

            if (index < 0)
            {
                index = 0;
            }
            return(index);
        }