1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-14 11:45:38 +02:00

Changed updateViews() calls

This commit is contained in:
Oleg Krasilnikov 2007-03-07 14:23:54 +00:00
parent 080f6d053f
commit 20706240c3
5 changed files with 13 additions and 12 deletions

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2006 Intel Corporation and others.
* Copyright (c) 2006, 2007 Intel 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
@ -58,7 +58,7 @@ public class BuildConfigAction extends Action {
configs[i].setActive();
try {
CoreModel.getDefault().setProjectDescription(prj, prjd);
AbstractPage.updateViews();
AbstractPage.updateViews(prj);
} catch (CoreException e) { }
break;
}

View file

@ -116,8 +116,8 @@ implements IWorkbenchWindowPulldownDelegate2, IObjectActionDelegate {
if (selected != null && selected.length > 0) {
for (int i = 0; i < selected.length; i++) {
((ResCfgData)selected[i]).delete();
AbstractPage.updateViews(((ResCfgData)selected[i]).res);
}
AbstractPage.updateViews();
}
}
}

View file

@ -184,9 +184,8 @@ outer:
try {
CoreModel.getDefault().setProjectDescription(p, prjd);
} catch (CoreException e) {}
AbstractPage.updateViews(res);
}
AbstractPage.updateViews();
}
}
}

View file

@ -69,6 +69,8 @@ import org.eclipse.cdt.core.settings.model.ICResourceDescription;
import org.eclipse.cdt.ui.CUIPlugin;
import org.eclipse.cdt.utils.ui.controls.ControlFactory;
import org.eclipse.cdt.internal.ui.util.ProblemMarkerManager;
/**
* It is a parent for all standard CDT property pages
* in new CDT model.
@ -95,7 +97,7 @@ public abstract class AbstractPage extends PropertyPage
implements
IWorkbenchPropertyPage, // ext point
IPreferencePageContainer, // dynamic pages
ICPropertyProvider // utility methods for tabs
ICPropertyProvider // utility methods for tabs
{
// Toggle this constant to <false>
// to hide "Manage configurations" button.
@ -131,7 +133,7 @@ implements
private static final Object NOT_NULL = new Object();
public static final String EMPTY_STR = ""; //$NON-NLS-1$
/*
* Dialog widgets
*/
@ -408,7 +410,7 @@ implements
try {
CoreModel.getDefault().setProjectDescription(getProject(), prjd);
} catch (CoreException e) { }
updateViews();
updateViews(internalElement);
return true;
}
@ -431,7 +433,7 @@ implements
} catch (CoreException e) {
System.out.println("setProjectDescription: " + e.getLocalizedMessage()); //$NON-NLS-1$
}
updateViews();
updateViews(internalElement);
}
};
IRunnableWithProgress op = new WorkspaceModifyDelegatingOperation(runnable);
@ -853,7 +855,7 @@ implements
}
// update views (in particular, display resource configurations)
public static void updateViews() {
public static void updateViews(IResource res) {
WorkbenchPlugin.getDefault().getDecoratorManager().updateForEnablementChange();
}
}
}

View file

@ -76,7 +76,7 @@ public class ManageConfigDialog extends Dialog {
if (d.open() == OK) {
try {
CoreModel.getDefault().setProjectDescription(prj, prjd);
AbstractPage.updateViews();
AbstractPage.updateViews(prj);
} catch (CoreException e) { return false; }
return true;
}