private void OnDockingAutoHiddenGroupHoverStart(object sender, KryptonPageEventArgs e)
        {
            // Request the sliding panel slide itself into view with the provided page
            KryptonDockingAutoHiddenGroup dockingGroup = (KryptonDockingAutoHiddenGroup)sender;

            _slidePanel.SlideOut(e.Item, dockingGroup.AutoHiddenGroupControl, false);
        }
        private void OnDockingAutoHiddenGroupDisposed(object sender, EventArgs e)
        {
            // Cast to correct type and unhook event handlers so garbage collection can occur
            KryptonDockingAutoHiddenGroup groupElement = (KryptonDockingAutoHiddenGroup)sender;

            groupElement.PageClicked    -= OnDockingAutoHiddenGroupClicked;
            groupElement.PageHoverStart -= OnDockingAutoHiddenGroupHoverStart;
            groupElement.PageHoverEnd   -= OnDockingAutoHiddenGroupHoverEnd;
            groupElement.Disposed       -= OnDockingAutoHiddenGroupDisposed;

            // Remove the element from our child collection as it is no longer valid
            InternalRemove(groupElement);
        }
 /// <summary>
 /// Perform docking element specific actions for loading a child xml.
 /// </summary>
 /// <param name="xmlReader">Xml reader object.</param>
 /// <param name="pages">Collection of available pages.</param>
 /// <param name="child">Optional reference to existing child docking element.</param>
 protected override void LoadChildDockingElement(XmlReader xmlReader,
                                                 KryptonPageCollection pages,
                                                 IDockingElement child)
 {
     if (child != null)
     {
         child.LoadElementFromXml(xmlReader, pages);
     }
     else
     {
         // Create a new auto hidden group and then reload it
         KryptonDockingAutoHiddenGroup autoHiddenGroup = AppendAutoHiddenGroup(xmlReader.GetAttribute(@"N"));
         autoHiddenGroup.LoadElementFromXml(xmlReader, pages);
     }
 }
Пример #4
0
 /// <summary>
 /// Initialize a new instance of the AutoHiddenGroupEventArgs class.
 /// </summary>
 /// <param name="control">Reference to auto hidden group control instance.</param>
 /// <param name="element">Reference to docking auto hidden group element that is managing the control.</param>
 public AutoHiddenGroupEventArgs(KryptonAutoHiddenGroup control,
                                 KryptonDockingAutoHiddenGroup element)
 {
     AutoHiddenGroupControl = control;
     AutoHiddenGroupElement = element;
 }