1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-04 07:35:24 +02:00

Bug 480287 Uncategorized libs were losing their parent.

This badly affected the check behavior since it couldn't find it in
the tree.

Change-Id: Ic77c9d45568f31f9563d2c1a93040291e28b20df
This commit is contained in:
Doug Schaefer 2015-10-24 11:38:21 -04:00
parent 15a087a3f4
commit 0c59d09514
2 changed files with 3 additions and 2 deletions

View file

@ -13,6 +13,7 @@ import java.util.Set;
public class LibraryIndex {
private List<ArduinoLibrary> libraries;
public static final String UNCATEGORIZED = "Uncategorized"; //$NON-NLS-1$
// category name to library name
private Map<String, Set<String>> categories = new HashMap<>();
@ -25,7 +26,7 @@ public class LibraryIndex {
String category = library.getCategory();
if (category == null) {
category = "Uncategorized"; //$NON-NLS-1$
category = UNCATEGORIZED;
}
Set<String> categoryLibs = categories.get(category);

View file

@ -84,7 +84,7 @@ public class LibrariesPropertyPage extends PropertyPage {
} catch (CoreException e) {
Activator.log(e);
}
return null;
return LibraryIndex.UNCATEGORIZED;
} else if (element instanceof String || element instanceof ArduinoPlatform) {
return index;
} else {