1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Cosmetics.

This commit is contained in:
Sergey Prigogin 2014-05-28 20:50:43 -07:00
parent 580b3a892a
commit 48b9c2e5ad
3 changed files with 6 additions and 7 deletions

View file

@ -94,14 +94,14 @@ public class RenameCSourceFolderChange extends Change {
}
private ICSourceEntry[] renameEntry(ICSourceEntry[] entries){
Set<ICSourceEntry> set = new HashSet<ICSourceEntry>();
Set<ICSourceEntry> set = new HashSet<>();
for (ICSourceEntry se : entries){
String seLocation = se.getName();
if (seLocation.equals(oldName.toPortableString())) {
ICSourceEntry newSE = new CSourceEntry(newName, se.getExclusionPatterns(), se.getFlags());
set.add(newSE);
} else {
Set<IPath> exPatters = new HashSet<IPath>();
Set<IPath> exPatters = new HashSet<>();
for (IPath filter : se.getExclusionPatterns()) {
IPath oldSegments = oldName.removeFirstSegments(oldName.segmentCount() -1);
if (filter.equals(oldSegments)) {

View file

@ -514,7 +514,7 @@ public class RenameLinkedMode {
}
private AbstractCLikeLanguage getLanguage() {
ITranslationUnit tu = (ITranslationUnit) fEditor.getInputCElement();
ITranslationUnit tu = fEditor.getInputCElement();
ILanguage language = null;
try {
language = tu.getLanguage();

View file

@ -27,7 +27,6 @@ import org.eclipse.ltk.core.refactoring.participants.RenameParticipant;
* @author Emanuel Graf IFS
*/
public class RenameSourceFolder extends RenameParticipant {
private IFolder oldFolder;
private String newName;