/// <summary>
      /// Releases unmanaged and - optionally - managed resources
      /// </summary>
      /// <param name="disposing"><c>true</c> to release both managed and unmanaged resources; <c>false</c> to release only unmanaged resources.</param>
      protected override void Dispose(bool disposing)
      {
          base.Dispose(disposing);

          // Dispose of any event listeners.
          if (BuildEventListener != null)
          {
              BuildEventListener.Dispose();
          }

          if (SolutionEventListener != null)
          {
              SolutionEventListener.Dispose();
          }
      }
      ///-------------------------------------------------------------------------------------------------
      /// <summary>
      ///  Registers the package solution events.
      /// </summary>
      ///-------------------------------------------------------------------------------------------------
      private void registerSolutionEvents()
      {
          SolutionEventListener = new SolutionEventListener(this);

          SolutionEventListener.AfterClosing += solutionEventListener_AfterClosing;
      }