Exemple #1
0
 /// <summary/>
 protected virtual void Dispose(bool fDisposing)
 {
     System.Diagnostics.Debug.WriteLineIf(!fDisposing, "****** Missing Dispose() call for " + GetType().Name + ". ****** ");
     if (fDisposing && !IsDisposed)
     {
         // dispose managed and unmanaged objects
         if (m_sizingLine != null)
         {
             m_sizingLine.Dispose();
         }
     }
     m_sizingLine = null;
     IsDisposed   = true;
 }
        /// ------------------------------------------------------------------------------------
        /// <summary>
        /// If terminating a resize process, then resize the container panel based on where
        /// the user left the sizing line.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="T:System.Windows.Forms.MouseEventArgs"/> instance
        /// containing the event data.</param>
        /// ------------------------------------------------------------------------------------
        protected void OnParentMouseUp(object sender, MouseEventArgs e)
        {
            m_parent.Cursor = Cursors.Default;

            if (m_resizeInProcess)
            {
                m_resizeInProcess = false;
                OnSplitterMoved(m_sizingLine.Top);
                m_parent.Controls.Remove(m_sizingLine);
                m_sizingLine.Dispose();
                m_sizingLine = null;
            }
        }