Exemplo n.º 1
0
        protected virtual void Detach(ITextView textView)
        {
            Contract.Requires <ArgumentNullException>(textView != null, "textView");

            DismissAll();

            if (_commandFilter != null)
            {
                _commandFilter.Dispose();
            }

            if (_textView != null)
            {
                _textView.Selection.SelectionChanged -= HandleViewSelectionChanged;
            }

            _textView      = null;
            _commandFilter = null;
        }
Exemplo n.º 2
0
        protected virtual void Detach([NotNull] ITextView textView)
        {
            Requires.NotNull(textView, nameof(textView));

            DismissAll();

            if (_commandFilter != null)
            {
                _commandFilter.Dispose();
            }

            if (_textView != null)
            {
                _textView.Selection.SelectionChanged -= HandleViewSelectionChanged;
            }

            _textView      = null;
            _commandFilter = null;
        }