Ejemplo n.º 1
0
        protected void InsertChildProvider(bool raiseEvent, FragmentControlProvider childProvider, int index, bool recursive)
        {
            if (Navigation.ChildrenContains(childProvider))
            {
                return;
            }

            if (index == FAKE_INDEX_TREATED_AS_END || !Navigation.IsIndexValid(index))
            {
                Navigation.AppendChild(childProvider);
            }
            else
            {
                Navigation.InsertChild(index, childProvider);
            }

            NotifyOnChildStructureChanged(childProvider, StructureChangeType.ChildAdded, raiseEvent);

            if (recursive)
            {
                childProvider.InitializeChildControlStructure();
            }
        }