Пример #1
0
        /// <summary>
        /// Unsubscribe from events and dispose of <see cref="_htmlContainer"/>.
        /// </summary>
        protected virtual void OnToolTipDisposed(EventArgs e)
        {
            Popup    -= OnToolTipPopup;
            Draw     -= OnToolTipDraw;
            Disposed -= OnToolTipDisposed;

            if (_htmlContainer != null)
            {
                _htmlContainer.RenderError -= OnRenderError;
                _htmlContainer.Dispose();
                _htmlContainer = null;
            }

#if !MONO
            if (_linkHandlingTimer != null)
            {
                _linkHandlingTimer.Dispose();
                _linkHandlingTimer = null;

                if (_htmlContainer != null)
                {
                    _htmlContainer.LinkClicked -= OnLinkClicked;
                }
            }
#endif
        }
Пример #2
0
 /// <summary>
 /// Release the html container resources.
 /// </summary>
 protected override void Dispose(bool disposing)
 {
     if (_htmlContainer != null)
     {
         _htmlContainer.LoadComplete -= OnLoadComplete;
         _htmlContainer.LinkClicked  -= OnLinkClicked;
         _htmlContainer.RenderError  -= OnRenderError;
         _htmlContainer.Refresh      -= OnRefresh;
         _htmlContainer.Dispose();
         _htmlContainer = null;
     }
     base.Dispose(disposing);
 }
Пример #3
0
 /// <summary>
 /// Release the html container resources.
 /// </summary>
 protected override void Dispose(bool disposing)
 {
     if (_htmlContainer != null)
     {
         _htmlContainer.LinkClicked    -= OnLinkClicked;
         _htmlContainer.RenderError    -= OnRenderError;
         _htmlContainer.Refresh        -= OnRefresh;
         _htmlContainer.StylesheetLoad -= OnStylesheetLoad;
         _htmlContainer.ImageLoad      -= OnImageLoad;
         _htmlContainer.Dispose();
         _htmlContainer = null;
     }
     base.Dispose(disposing);
 }