mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-23 17:05:26 +02:00
Bug 534423 - Sort configurations in the Exclude from build dialog
Sort the configuration list in the same order as used by the project property pages (case-insensitive nonlocalized), almost the same order as used in the Project > Build Configurations > Set Active menu (case-sensitive nonlocalized), not in the internal order coming from the .cproject file. Change-Id: Ia05bd163043f762dd96da4c69d409ecee9accb8c Signed-off-by: Christian Walther <walther@indel.ch>
This commit is contained in:
parent
c9eee479b4
commit
ebc9420473
1 changed files with 5 additions and 1 deletions
|
@ -12,6 +12,7 @@
|
|||
package org.eclipse.cdt.internal.ui.actions;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Iterator;
|
||||
|
||||
|
@ -45,6 +46,7 @@ import org.eclipse.cdt.core.model.ICContainer;
|
|||
import org.eclipse.cdt.core.model.ICElement;
|
||||
import org.eclipse.cdt.core.model.ICProject;
|
||||
import org.eclipse.cdt.core.model.ITranslationUnit;
|
||||
import org.eclipse.cdt.core.model.util.CDTListComparator;
|
||||
import org.eclipse.cdt.core.settings.model.ICConfigurationDescription;
|
||||
import org.eclipse.cdt.core.settings.model.ICProjectDescription;
|
||||
import org.eclipse.cdt.core.settings.model.ICSourceEntry;
|
||||
|
@ -188,7 +190,9 @@ public class ExcludeFromBuildHandler extends AbstractHandler {
|
|||
if (!CoreModel.getDefault().isNewStyleProject(p)) return null;
|
||||
ICProjectDescription prjd = CoreModel.getDefault().getProjectDescription(p, false);
|
||||
if (prjd == null) return null;
|
||||
return prjd.getConfigurations();
|
||||
ICConfigurationDescription[] cfgs = prjd.getConfigurations();
|
||||
Arrays.sort(cfgs, CDTListComparator.getInstance());
|
||||
return cfgs;
|
||||
}
|
||||
|
||||
private void openDialog() {
|
||||
|
|
Loading…
Add table
Reference in a new issue