diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/asm/AsmSourceViewerConfiguration.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/asm/AsmSourceViewerConfiguration.java index 82c4f209b1e..74f8c00c5df 100644 --- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/asm/AsmSourceViewerConfiguration.java +++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/asm/AsmSourceViewerConfiguration.java @@ -12,6 +12,7 @@ package org.eclipse.cdt.internal.ui.editor.asm; +import org.eclipse.jface.preference.IPreferenceStore; import org.eclipse.jface.text.IDocument; import org.eclipse.jface.text.presentation.IPresentationReconciler; import org.eclipse.jface.text.presentation.PresentationReconciler; @@ -32,8 +33,8 @@ public class AsmSourceViewerConfiguration extends TextSourceViewerConfiguration /** * Constructor for AsmSourceViewerConfiguration */ - public AsmSourceViewerConfiguration(AsmTextTools tools) { - super(); + public AsmSourceViewerConfiguration(AsmTextTools tools, IPreferenceStore store) { + super(store); fAsmTextTools = tools; } diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/asm/AsmTextEditor.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/asm/AsmTextEditor.java index 7a52834d4e2..101292ec703 100644 --- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/asm/AsmTextEditor.java +++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/editor/asm/AsmTextEditor.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2005 IBM Corporation and others. + * Copyright (c) 2005, 2007 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -12,10 +12,12 @@ package org.eclipse.cdt.internal.ui.editor.asm; -import org.eclipse.cdt.ui.CUIPlugin; +import org.eclipse.jface.preference.IPreferenceStore; import org.eclipse.jface.util.PropertyChangeEvent; import org.eclipse.ui.editors.text.TextEditor; +import org.eclipse.cdt.ui.CUIPlugin; + /** * Assembly text editor @@ -32,12 +34,13 @@ public class AsmTextEditor extends TextEditor { */ protected void initializeEditor() { AsmTextTools textTools= CUIPlugin.getDefault().getAsmTextTools(); - setSourceViewerConfiguration(new AsmSourceViewerConfiguration(textTools)); + IPreferenceStore store= CUIPlugin.getDefault().getCombinedPreferenceStore(); + setSourceViewerConfiguration(new AsmSourceViewerConfiguration(textTools, store)); setDocumentProvider(CUIPlugin.getDefault().getDocumentProvider()); // FIXME: Should this editor have a different preference store ? // For now we are sharing with the CEditor and any changes will in the // setting of the CEditor will be reflected in this editor. - setPreferenceStore(CUIPlugin.getDefault().getCombinedPreferenceStore()); + setPreferenceStore(store); setEditorContextMenuId("#ASMEditorContext"); //$NON-NLS-1$ setRulerContextMenuId("#ASMEditorRulerContext"); //$NON-NLS-1$ //setOutlinerContextMenuId("#ASMEditorOutlinerContext"); //$NON-NLS-1$