mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-08 09:35:23 +02:00
minor miner fix - dataelement naming conventions for folders should be consistent: name should be name, while value should be parent path
This commit is contained in:
parent
bf910f21f8
commit
bca932fbea
1 changed files with 7 additions and 2 deletions
|
@ -1556,8 +1556,13 @@ private DataElement createDataElementFromLSString(DataElement subject,
|
||||||
}
|
}
|
||||||
else { // directory
|
else { // directory
|
||||||
subject.setAttribute(DE.A_TYPE, IUniversalDataStoreConstants.UNIVERSAL_FOLDER_DESCRIPTOR);
|
subject.setAttribute(DE.A_TYPE, IUniversalDataStoreConstants.UNIVERSAL_FOLDER_DESCRIPTOR);
|
||||||
subject.setAttribute(DE.A_NAME, ""); //$NON-NLS-1$
|
String name = fullName
|
||||||
subject.setAttribute(DE.A_VALUE, fullName);
|
.substring(
|
||||||
|
fullName.lastIndexOf(File.separatorChar) + 1,
|
||||||
|
fullName.length());
|
||||||
|
String path = fullName.substring(0, fullName.lastIndexOf(File.separatorChar));
|
||||||
|
subject.setAttribute(DE.A_NAME, name);
|
||||||
|
subject.setAttribute(DE.A_VALUE, path);
|
||||||
}
|
}
|
||||||
|
|
||||||
// DKM - do basic property stuff here
|
// DKM - do basic property stuff here
|
||||||
|
|
Loading…
Add table
Reference in a new issue