1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Removed uses of deprecated methods.

This commit is contained in:
Sergey Prigogin 2011-02-28 01:48:58 +00:00
parent 4b984c2b5f
commit 62c3a2bf32

View file

@ -1,5 +1,5 @@
/******************************************************************************* /*******************************************************************************
* Copyright (c) 2008, 2009 Symbian Software Systems and others. * Copyright (c) 2008, 2011 Symbian Software Systems and others.
* All rights reserved. This program and the accompanying materials * All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0 * are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at * which accompanies this distribution, and is available at
@ -42,8 +42,8 @@ import org.eclipse.cdt.ui.text.doctools.IDocCommentOwnershipListener;
import org.eclipse.cdt.ui.text.doctools.IDocCommentViewerConfiguration; import org.eclipse.cdt.ui.text.doctools.IDocCommentViewerConfiguration;
/** /**
* This class manages which IDocCommentOwner's are available in the run-time, and how they map to resources * This class manages which IDocCommentOwner's are available in the run-time, and how they map to
* in projects. * resources in projects.
* @since 5.0 * @since 5.0
*/ */
public class DocCommentOwnerManager { public class DocCommentOwnerManager {
@ -73,9 +73,8 @@ public class DocCommentOwnerManager {
fOwners= getCommentOwnerExtensions(); fOwners= getCommentOwnerExtensions();
fListeners= new ArrayList<IDocCommentOwnershipListener>(); fListeners= new ArrayList<IDocCommentOwnershipListener>();
Preferences defaultPrefs = new Preferences defaultPrefs = DefaultScope.INSTANCE.getNode(QUALIFIER).node(WORKSPACE_DOC_TOOL_NODE);
DefaultScope().getNode(QUALIFIER).node(WORKSPACE_DOC_TOOL_NODE); Preferences prefs= InstanceScope.INSTANCE.getNode(QUALIFIER).node(WORKSPACE_DOC_TOOL_NODE);
Preferences prefs= new InstanceScope().getNode(QUALIFIER).node(WORKSPACE_DOC_TOOL_NODE);
String id= prefs.get(PREFKEY_WORKSPACE_DEFAULT, defaultPrefs.get(PREFKEY_WORKSPACE_DEFAULT, String id= prefs.get(PREFKEY_WORKSPACE_DEFAULT, defaultPrefs.get(PREFKEY_WORKSPACE_DEFAULT,
NullDocCommentOwner.INSTANCE.getID())); NullDocCommentOwner.INSTANCE.getID()));
@ -105,7 +104,7 @@ public class DocCommentOwnerManager {
IDocCommentOwner oldOwner= fWorkspaceOwner; IDocCommentOwner oldOwner= fWorkspaceOwner;
fWorkspaceOwner= newOwner; fWorkspaceOwner= newOwner;
Preferences prefs= new InstanceScope().getNode(QUALIFIER).node(WORKSPACE_DOC_TOOL_NODE); Preferences prefs= InstanceScope.INSTANCE.getNode(QUALIFIER).node(WORKSPACE_DOC_TOOL_NODE);
prefs.put(PREFKEY_WORKSPACE_DEFAULT, newOwner.getID()); prefs.put(PREFKEY_WORKSPACE_DEFAULT, newOwner.getID());
fireWorkspaceOwnershipChanged(oldOwner, fWorkspaceOwner); fireWorkspaceOwnershipChanged(oldOwner, fWorkspaceOwner);