From afbeaa455aba79925ef6316c83176c46a78a38da Mon Sep 17 00:00:00 2001 From: nitind Date: Mon, 29 Nov 2004 19:53:33 +0000 Subject: fix default preferences "race" condition --- .../src/org/eclipse/jst/jsp/ui/JSPEditorPlugin.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'bundles/org.eclipse.jst.jsp.ui') diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/JSPEditorPlugin.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/JSPEditorPlugin.java index 04820f8297..44a74bf4fc 100644 --- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/JSPEditorPlugin.java +++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/JSPEditorPlugin.java @@ -57,10 +57,11 @@ public class JSPEditorPlugin extends AbstractUIPlugin { public JSPEditorPlugin(IPluginDescriptor descriptor) { super(descriptor); instance = this; - - // reference the preference store so - // initializeDefaultPreferences(IPreferenceStore preferenceStore) is called - getPreferenceStore(); + + // Force a call to initializeDefaultJSPPreferences since + // initializeDefaultPreferences is only called if *this* plugin's + // preference store is accessed + initializeDefaultJSPPreferences(((AbstractUIPlugin)Platform.getPlugin(EditorPlugin.ID)).getPreferenceStore()); } public static JSPEditorPlugin getDefault() { @@ -89,7 +90,6 @@ public class JSPEditorPlugin extends AbstractUIPlugin { // ignore this preference store // use EditorPlugin preference store IPreferenceStore editorStore = ((AbstractUIPlugin)Platform.getPlugin(EditorPlugin.ID)).getPreferenceStore(); - EditorPlugin.initializeDefaultEditorPreferences(editorStore); initializeDefaultJSPPreferences(editorStore); } -- cgit v1.2.3