diff --git a/llvm/org.eclipse.cdt.managedbuilder.llvm.ui/src/org/eclipse/cdt/managedbuilder/llvm/util/LlvmResourceListener.java b/llvm/org.eclipse.cdt.managedbuilder.llvm.ui/src/org/eclipse/cdt/managedbuilder/llvm/util/LlvmResourceListener.java index 348fdca4ca3..a563ae704d8 100644 --- a/llvm/org.eclipse.cdt.managedbuilder.llvm.ui/src/org/eclipse/cdt/managedbuilder/llvm/util/LlvmResourceListener.java +++ b/llvm/org.eclipse.cdt.managedbuilder.llvm.ui/src/org/eclipse/cdt/managedbuilder/llvm/util/LlvmResourceListener.java @@ -1,22 +1,20 @@ /******************************************************************************* - * Copyright (c) 2010-2013 Nokia Siemens Networks Oyj, Finland. + * Copyright (c) 2010, 2013 Nokia Siemens Networks Oyj, Finland. * 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 * http://www.eclipse.org/legal/epl-v10.html * * Contributors: - * Nokia Siemens Networks - initial implementation - * Petri Tuononen - Initial implementation + * Nokia Siemens Networks - initial implementation + * Petri Tuononen - Initial implementation + * Marc-Andre Laperle (Ericsson) *******************************************************************************/ package org.eclipse.cdt.managedbuilder.llvm.util; import org.eclipse.cdt.managedbuilder.llvm.ui.preferences.LlvmPreferenceStore; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.resources.IResource; import org.eclipse.core.resources.IResourceChangeEvent; import org.eclipse.core.resources.IResourceChangeListener; -import org.eclipse.core.runtime.CoreException; /** * Implements Resource listener. @@ -31,17 +29,26 @@ public class LlvmResourceListener implements IResourceChangeListener { public void resourceChanged(IResourceChangeEvent event) { if (event.getType() == IResourceChangeEvent.POST_BUILD) { //refresh every project after build - //get all projects - IProject[] projects = LlvmToolOptionPathUtil.getProjectsInWorkspace(); - //refresh the projects - for (IProject proj : projects) { - try { - proj.refreshLocal(IResource.DEPTH_INFINITE, null); - } catch (CoreException e) { - e.printStackTrace(); - } - } + /* + * FIXME: M-A.L: (Bug 405909) I commented out the refresh code because it was a + * major performance issue even without LLVM projects in the + * workspace. Unfortunately, I could not track down the reason as to + * why there was a refresh in the first the place by looking at the + * history (git and svn) and by manual testing + */ + +// //get all projects +// IProject[] projects = LlvmToolOptionPathUtil.getProjectsInWorkspace(); +// +// //refresh the projects +// for (IProject proj : projects) { +// try { +// proj.refreshLocal(IResource.DEPTH_INFINITE, null); +// } catch (CoreException e) { +// e.printStackTrace(); +// } +// } } else if (event.getType() == IResourceChangeEvent.PRE_BUILD) { String os = System.getProperty("os.name").toLowerCase(); //$NON-NLS-1$ if (os.indexOf("win") >= 0) { //$NON-NLS-1$