Browse Source

Fixed null reference when insight window opens in IronPython and Boo projects.

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/trunk@6377 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
pull/1/head
Matt Ward 15 years ago
parent
commit
8fda917b08
  1. 4
      src/Main/Base/Project/Src/Editor/CodeCompletion/CodeCompletionBinding.cs

4
src/Main/Base/Project/Src/Editor/CodeCompletion/CodeCompletionBinding.cs

@ -175,7 +175,7 @@ namespace ICSharpCode.SharpDevelop.Editor.CodeCompletion @@ -175,7 +175,7 @@ namespace ICSharpCode.SharpDevelop.Editor.CodeCompletion
case '(':
if (enableMethodInsight && CodeCompletionOptions.InsightEnabled) {
IInsightWindow insightWindow = editor.ShowInsightWindow(new MethodInsightProvider().ProvideInsight(editor));
if (insightWindow != null) {
if (insightWindow != null && insightHandler != null) {
insightHandler.InitializeOpenedInsightWindow(editor, insightWindow);
insightHandler.HighlightParameter(insightWindow, -1); // disable highlighting
}
@ -185,7 +185,7 @@ namespace ICSharpCode.SharpDevelop.Editor.CodeCompletion @@ -185,7 +185,7 @@ namespace ICSharpCode.SharpDevelop.Editor.CodeCompletion
case '[':
if (enableIndexerInsight && CodeCompletionOptions.InsightEnabled) {
IInsightWindow insightWindow = editor.ShowInsightWindow(new IndexerInsightProvider().ProvideInsight(editor));
if (insightWindow != null)
if (insightWindow != null && insightHandler != null)
insightHandler.InitializeOpenedInsightWindow(editor, insightWindow);
return CodeCompletionKeyPressResult.Completed;
}

Loading…
Cancel
Save