예제 #1
0
 void CompletionSession_Dismissed(object sender, EventArgs e)
 {
     UnregisterCompletionSetEvents();
     DisposeFilters();
     toolTipTimer.Stop();
     toolTipTimer.Tick -= ToolTipTimer_Tick;
     HideToolTip();
     session.SelectedCompletionSetChanged -= CompletionSession_SelectedCompletionSetChanged;
     session.Dismissed -= CompletionSession_Dismissed;
     session.TextView.LostAggregateFocus            -= TextView_LostAggregateFocus;
     session.TextView.TextBuffer.ChangedLowPriority -= TextBuffer_ChangedLowPriority;
     control.completionsListBox.SelectionChanged    -= CompletionsListBox_SelectionChanged;
     control.completionsListBox.Loaded           -= CompletionsListBox_Loaded;
     control.completionsListBox.PreviewMouseDown -= CompletionsListBox_PreviewMouseDown;
     control.completionsListBox.PreviewMouseUp   -= CompletionsListBox_PreviewMouseUp;
     control.completionsListBox.MouseLeave       -= CompletionsListBox_MouseLeave;
     control.completionsListBox.MouseDoubleClick -= CompletionsListBox_MouseDoubleClick;
     control.completionsListBox.ItemContainerGenerator.StatusChanged -= ItemContainerGenerator_StatusChanged;
     control.SizeChanged      -= Control_SizeChanged;
     control.GotKeyboardFocus -= Control_GotKeyboardFocus;
     if (wpfTextView != null)
     {
         wpfTextView.VisualElement.PreviewKeyDown -= VisualElement_PreviewKeyDown;
     }
     session.TextView.LayoutChanged -= TextView_LayoutChanged;
     completionTextElementProvider.Dispose();
     control.completionsListBox.ItemsSource = null;
     completionCollectionVM?.Dispose();
     completionCollectionVM = null;
 }
예제 #2
0
 void CompletionSession_Dismissed(object sender, EventArgs e)
 {
     UnregisterCompletionCollectionEvents();
     DisposeFilters();
     session.SelectedCompletionCollectionChanged -= CompletionSession_SelectedCompletionCollectionChanged;
     session.Dismissed -= CompletionSession_Dismissed;
     session.TextView.LostAggregateFocus            -= TextView_LostAggregateFocus;
     session.TextView.TextBuffer.ChangedLowPriority -= TextBuffer_ChangedLowPriority;
     control.completionsListBox.SelectionChanged    -= CompletionsListBox_SelectionChanged;
     if (wpfTextView != null)
     {
         wpfTextView.VisualElement.PreviewKeyDown -= VisualElement_PreviewKeyDown;
     }
     completionTextElementProvider.Dispose();
 }